Fix: Android native connection errors are not displayed (#5)

* fix(android, lib): add error logging, handle running jobs exception

* doc(app_service): add comment

* fix(exampl_full, utils): move getCurrentDevice info and fix logs

* doc: add comments, update changelog

* doc: update changelog

* version: 0.0.7

* doc: update readme

* doc: update readme
This commit is contained in:
Kseniia Nikitina
2024-04-21 16:38:45 +02:00
committed by GitHub
parent 6abb8024dd
commit e4a8c2243f
19 changed files with 398 additions and 87 deletions
+29
View File
@@ -168,6 +168,13 @@ abstract class NearbyService {
/// Note that the [NearbyIOSService] implementation starts **browsing** or
/// **advertising** depending on the [NearbyIOSService.isBrowser].
///
/// On Android can throw mapped from native platform exceptions:
/// 1. [NearbyServiceBusyException]
/// 2. [NearbyServiceP2PUnsupportedException]
/// 3. [NearbyServiceNoServiceRequestsException]
/// 4. [NearbyServiceGenericErrorException]
/// 5. [NearbyServiceUnknownException]
///
Future<bool> discover();
///
@@ -176,6 +183,13 @@ abstract class NearbyService {
/// Note that the [NearbyIOSService] implementation stops **browsing** or
/// **advertising** depending on the [NearbyIOSService.isBrowser].
///
/// On Android can throw mapped from native platform exceptions:
/// 1. [NearbyServiceBusyException]
/// 2. [NearbyServiceP2PUnsupportedException]
/// 3. [NearbyServiceNoServiceRequestsException]
/// 4. [NearbyServiceGenericErrorException]
/// 5. [NearbyServiceUnknownException]
///
Future<bool> stopDiscovery();
///
@@ -187,6 +201,13 @@ abstract class NearbyService {
/// Note that if [Platform.isIOS] == true, [NearbyIOSDevice] should be passed.
/// If [Platform.isAndroid] == true, [NearbyAndroidDevice] should be passed.
///
/// On Android can throw mapped from native platform exceptions:
/// 1. [NearbyServiceBusyException]
/// 2. [NearbyServiceP2PUnsupportedException]
/// 3. [NearbyServiceNoServiceRequestsException]
/// 4. [NearbyServiceGenericErrorException]
/// 5. [NearbyServiceUnknownException]
///
Future<bool> connect(NearbyDevice device);
///
@@ -196,6 +217,14 @@ abstract class NearbyService {
/// If [Platform.isAndroid] == true, [NearbyAndroidDevice] should be passed.
///
/// **For IOS [device] is required!!!**
///
/// On Android can throw mapped from native platform exceptions:
/// 1. [NearbyServiceBusyException]
/// 2. [NearbyServiceP2PUnsupportedException]
/// 3. [NearbyServiceNoServiceRequestsException]
/// 4. [NearbyServiceGenericErrorException]
/// 5. [NearbyServiceUnknownException]
///
Future<bool> disconnect([NearbyDevice? device]);
///