Disconnector<T> class
Allows the caller to force a channel to disconnect.
When disconnect is called, the channel (or channels) transformed by this transformer will act as though the remote end had disconnected—the stream will emit a done event, and the sink will ignore future inputs. The inner sink will also be closed to notify the remote end of the disconnection.
If a channel is transformed after the disconnect has been called, it will be disconnected immediately.
- Implemented types
-
- StreamChannelTransformer<
T, T>
- StreamChannelTransformer<
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- isDisconnected → bool
-
Whether disconnect has been called.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
bind(
StreamChannel< T> channel) → StreamChannel<T> -
Transforms the events sent to and emitted by
channel
.override -
disconnect(
) → Future< void> - Disconnects all channels that have been transformed.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited