RemoteAdapter<T extends SyncableEntity> class abstract

Remote adapter abstraction for communicating with server-side data sources.

Constructors

RemoteAdapter()

Properties

changeStream → Stream<ChangeDetail<T>>?
Stream of changes that occur in the remote storage. Implementations should emit events when data changes externally (e.g., from another device or user). Return null if the adapter doesn't support change notifications.
no setter
hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

deleteRemote(String id, String userId) → Future<void>
Delete the item from the remote source.
fetchAll(String userId) → Future<List<T>>
Fetch all items belonging to the user from the remote source.
fetchById(String id, String userId) → Future<T?>
Fetch a single item by identifier.
getSyncMetadata(String userId) → Future<SyncMetadata?>
Retrieve remote-side metadata to compare sync states.
isConnected() → Future<bool>
Determine whether remote connectivity is currently available.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
push(T item, String userId) → Future<T>
Push (create/update) an item to the remote source, returning the stored representation.
toString() → String
A string representation of this object.
inherited
updateSyncMetadata(SyncMetadata metadata, String userId) → Future<void>
Persist the latest sync metadata on the remote side.

Operators

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