StateSubscription<T extends GeneratedMessage> class
A subscription for entity state changes.
The itemAdded, itemChanged and itemRemoved streams reflect the changes of a corresponding entity type.
To stop receiving updates from the server, invoke unsubscribe. This will cancel the subscription both on the client and on the server, stopping the changes from being reflected to Firebase.
Please note that only broadcast streams are supported. It is a responsibility of end-users to convert any streams to broadcast streams prior to using this class.
- Inheritance
-
- Object
- Subscription<
T> - StateSubscription
Constructors
- StateSubscription.of(FirebaseSubscription firebaseSubscription, BuilderInfo builderInfoForType, FirebaseClient database)
-
Creates a new instance which broadcasts updates from under the given Firebase node.
factory
Properties
- closed → bool
-
Shows if this subscription is still active or already closed.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
-
itemAdded
→ Stream<
T> -
no setter
-
itemChanged
→ Stream<
T> -
final
-
itemRemoved
→ Stream<
T> -
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- subscription → Subscription
-
A future for the subscription message.
finalinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
unsubscribe(
) → void -
Closes this subscription.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited