SubscriptionManager class

Constructors

SubscriptionManager(SpacetimeDbConnection _connection, {OfflineStorage? offlineStorage})

Properties

activeSubscriptionQueries Set<String>
All currently-subscribed query strings across every active QuerySetId.
no setter
address String?
no setter
cache ClientCache
final
hashCode int
The hash code for this object.
no setterinherited
hasOfflineStorage bool
no setter
identity Identity?
no setter
onInitialConnection Stream<InitialConnectionMessage>
no setter
onMutationSyncResult Stream<MutationSyncResult>
no setter
onOneOffQueryResult Stream<OneOffQueryResult>
no setter
onProcedureResult Stream<ProcedureResultMessage>
no setter
onReducerResult Stream<ReducerResultMessage>
no setter
onSubscribeApplied Stream<SubscribeApplied>
no setter
onSubscriptionError Stream<SubscriptionErrorMessage>
no setter
onSyncStateChanged Stream<SyncState>
no setter
onTransactionUpdate Stream<TransactionUpdateMessage>
no setter
onUnsubscribeApplied Stream<UnsubscribeApplied>
no setter
reducerEmitter ReducerEmitter
final
reducerRegistry ReducerRegistry
final
reducers ReducerCaller
latefinal
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
subscriptionsByQuerySetId Map<int, List<String>>
no setter
syncState SyncState
no setter

Methods

callProcedure(String procedureName, Uint8List args, {int requestId = 0}) → void
checkHealth({Duration timeout = const Duration(seconds: 3)}) Future<bool>
Probe whether the server is actually answering on this socket.
clearAllPendingMutations() Future<void>
clearPendingMutation(String requestId) Future<void>
dispose() Future<void>
getPendingMutations() Future<List<PendingMutation>>
loadFromOfflineCache() Future<void>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
oneOffQuery(String query, {int requestId = 0}) → void
subscribe(List<String> queries) Future<int>
Subscribe a new query set. Returns the assigned querySetId. Awaits the matching SubscribeApplied so initial rows are in the cache.
syncPendingMutations() Future<void>
toString() String
A string representation of this object.
inherited
unsubscribe(int querySetId, {int requestId = 0, bool sendDroppedRows = false}) → void
Remove a subscription. Set sendDroppedRows: true to receive the dropped-row payload on the resulting UnsubscribeApplied (slice 5 / v2.rs:86-93). The default is false — server sends no dropped rows.

Operators

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