EventBusSubscriptionOwner class final
A framework-independent owner for event subscriptions.
Call dispose from the host object's lifecycle method, such as dispose,
close, onClose, or a service shutdown hook.
- Implemented types
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- isDisposed → bool
-
Whether dispose has already been called.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
dispose(
) → void - Cancels all owned subscriptions. Calling this more than once is safe.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
registerEventSubscription(
EventSubscriptionHandle subscription) → void -
Registers
subscriptionfor lifecycle-managed cancellation.override -
toString(
) → String -
A string representation of this object.
inherited
-
unregisterEventSubscription(
EventSubscriptionHandle subscription) → void -
Removes an already cancelled
subscriptionfrom lifecycle management.override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited