A named channel for sending events to the framework-side using streams.
This is the platform-side equivalent of EventChannel. Whereas EventChannel receives a stream of events from platform plugins, this channel sends a stream of events to the handler listening on the framework-side.
Channels created using this class implement two methods for subscribing to the event stream. The methods use the encoding of the specified codec.
The first method is
listen. When called, it begins forwarding
messages to the framework side when they are added to the
controller. This triggers the StreamController.onListen callback
The other method is
cancel. When called, it stops forwarding
events to the framework. This triggers the StreamController.onCancel
callback on the
Events added to the
controller when the framework is not
subscribed are silently discarded.
- binaryMessenger → BinaryMessenger?
The messenger used by this channel to send platform messages.
- codec → MethodCodec
The message codec used by this channel.
Use setController instead.
- hashCode → int
The hash code for this object.
- name → String
The logical channel on which communication happens.
- runtimeType → Type
A representation of the runtime type of the object.