AtClientManager class
Factory class for creating AtClient, SyncService and NotificationService instances
Usage
final atClientManager = AtClientManager.getInstance().setCurrentAtSign(<current_atsign>, <app_namespace>, <preferences>)
Apps have to call the above method again while switching atsign.
atClientManager.atClient - for at client method calls atClientManager.syncService - for invoking sync. Refer SyncService for detailed usage atClientManager.notificationService - for notification methods. Refer NotificationService for detailed usage
Constructors
- AtClientManager(dynamic _atSign)
- AtClientManager.getInstance()
-
factory
Properties
- atClient → AtClient
-
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- notificationService → NotificationService
-
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- secondaryAddressFinder ↔ SecondaryAddressFinder?
-
getter/setter pair
- syncService → SyncService
-
no setter
Methods
-
getChangeListenersSize(
) → int - NOT A PART of API. Added for unit tests
-
getItemsInChangeListeners(
) → Iterator - NOT A PART of API. Added for unit tests
-
listenToAtSignChange(
AtSignChangeListener listener) → void -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
removeAllChangeListeners(
) → dynamic - NOT A PART of API. Added for unit tests
-
removeChangeListeners(
AtSignChangeListener atSignChangeListener) → void - Removes the given listener from the list of listeners, that are notified whenever the @sign is switched
-
setCurrentAtSign(
String atSign, String? namespace, AtClientPreference preference, {AtServiceFactory? serviceFactory, AtChops? atChops, String? enrollmentId}) → Future< AtClientManager> -
- Can provide an AtServiceFactory to control what types of AtClients, NotificationServices and SyncServices get created by this method.
- Can provide an
AtChops
instance if available; setCurrentAtSign will ensure that it is injected into objects that can use it -
setSecondaryAddressFinder(
{SecondaryAddressFinder? secondaryAddressFinder}) → void -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited