AtClientStorageBase class abstract

The claim rules every AtClientStorage shares; a backend supplies location, openBackend, closeBackend and clearData.

Implemented types
Implementers

Constructors

AtClientStorageBase({bool closedByClient = false})

Properties

closedByClient → bool
Whether the client that attaches to this storage closes it on AtClient.stop.
final
hashCode → int
The hash code for this object.
no setterinherited
isAttached → bool
no setter
keyStore → AtKeyValueStore<String, AtData, AtMetaData?>
no setterinherited
location → String
The store this points at, in a form two storages over the same records report identically — everything that decides which records they resolve to, not only where the files sit: a backend keyed by atSign within a directory includes the atSign, since two atSigns there share nothing. An instance whose data is private to itself reports a token unique to it.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
syncQueue → AtSyncQueue
no setterinherited

Methods

attach(AtClient owner) → Future<void>
Claims this storage for owner.
override
clear() → Future<void>
Empties keystore and queue and forgets the last principal. Idempotent.
override
clearData() → Future<void>
Empties keystore and queue.
close() → Future<void>
Closes the backend. Idempotent.
override
closeBackend() → Future<void>
Closes the backend. Called at most once, by close.
detach(AtClient owner) → Future<void>
Drops owner's claim, keeping the backend open.
override
forgetPrincipal() → Future<void>
Forgets which principal last held this storage, keeping the data.
override
isHeldBy(AtClient client) → bool
Whether client is the one currently holding this storage.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
openBackend() → Future<void>
Opens the backend. Idempotent.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

principalOf(AtClient client) → String
The (atSign, enrollmentId) a client acts as.