Binding<T> class

Listens for messages and dispatches them to an implementation of T.


Binding ()

Creates a binding object in an unbound state.


hashCode → int

The hash code for this object.
read-only, inherited

impl → T

The implementation of T bound using this object.

isBound → bool

Whether this object is bound to a channel.

onBind ↔ _VoidCallback

Event for binding.
read / write

onClose ↔ _VoidCallback

Event for when the binding is closed.
read / write

onConnectionError ↔ _VoidCallback

Called when the channel underneath closes.
read / write

onUnbind ↔ _VoidCallback

Event for unbinding.
read / write

runtimeType → Type

A representation of the runtime type of the object.
read-only, inherited


bind(T impl, InterfaceRequest<T> interfaceRequest) void

Binds the given implementation to the given interface request.

close() void

Close the bound channel.

handleMessage(IncomingMessage message, OutgoingMessageSink respond) void

Decodes the given message and dispatches the decoded message to impl.

noSuchMethod(Invocation invocation) dynamic

Invoked when a non-existent method or property is accessed.

sendMessage(OutgoingMessage response) void

Sends the given message over the bound channel.

toString() String

A string representation of this object.

unbind() InterfaceRequest<T>

Unbinds impl and returns the unbound channel as an interface request.

wrap(T impl) InterfaceHandle<T>

Returns an interface handle whose peer is bound to the given object.


operator ==(Object other) bool

The equality operator.