blob: 0a0a04a16bce0595f4ff97022f5a3388f874203b [file] [log] [blame] [view]
# AsyncBinding<T> class
<p>Listens for messages and dispatches them to an implementation of <code>T</code>.</p>
## Constructors
[AsyncBinding](../package-fidl_fidl/AsyncBinding/AsyncBinding.md) (String $interfaceName)
Creates a binding object in an unbound state.
## Properties
##### [$interfaceName](../package-fidl_fidl/AsyncBinding/$interfaceName.md) &#8594; String
The name of the interface <code>T</code> as a string.
_final_
##### [hashCode](../package-fidl_fidl/AsyncBinding/hashCode.md) &#8594; int
The hash code for this object.
_read-only, inherited_
##### [impl](../package-fidl_fidl/AsyncBinding/impl.md) &#8594; T
The implementation of <code>T</code> bound using this object.
_read-only_
##### [isBound](../package-fidl_fidl/AsyncBinding/isBound.md) &#8594; bool
Is this interface bound?
_read-only, inherited_
##### [isClosed](../package-fidl_fidl/AsyncBinding/isClosed.md) &#8594; bool
Is this interface closed?
_read-only, inherited_
##### [isUnbound](../package-fidl_fidl/AsyncBinding/isUnbound.md) &#8594; bool
Is this interface unbound?
_read-only, inherited_
##### [runtimeType](../package-fidl_fidl/AsyncBinding/runtimeType.md) &#8594; Type
A representation of the runtime type of the object.
_read-only, inherited_
##### [state](../package-fidl_fidl/AsyncBinding/state.md) &#8596; [InterfaceState](../package-fidl_fidl/InterfaceState.md)
Gets the current state.
_read / write, inherited_
##### [stateChanges](../package-fidl_fidl/AsyncBinding/stateChanges.md) &#8594; Stream&lt;[InterfaceState](../package-fidl_fidl/InterfaceState.md)>
A stream of state changes.
_read-only, inherited_
##### [whenBound](../package-fidl_fidl/AsyncBinding/whenBound.md) &#8594; Future&lt;void>
A future that completes when the interface becomes bound.
_read-only, inherited_
##### [whenClosed](../package-fidl_fidl/AsyncBinding/whenClosed.md) &#8594; Future&lt;void>
A future that completes when the interface is closed.
_read-only, inherited_
## Methods
##### [bind](../package-fidl_fidl/AsyncBinding/bind.md)(T impl, [InterfaceRequest](../package-fidl_fidl/InterfaceRequest-class.md) interfaceRequest) void
Binds the given implementation to the given interface request.
##### [close](../package-fidl_fidl/AsyncBinding/close.md)([int statusCode]) void
Close the bound channel.
##### [handleMessage](../package-fidl_fidl/AsyncBinding/handleMessage.md)([IncomingMessage](../package-fidl_fidl/IncomingMessage-class.md) message, [OutgoingMessageSink](../package-fidl_fidl/OutgoingMessageSink.md) respond) void
Decodes the given message and dispatches the decoded message to <a href="../package-fidl_fidl/AsyncBinding/impl.md">impl</a>.
##### [noSuchMethod](../package-fidl_fidl/AsyncBinding/noSuchMethod.md)(Invocation invocation) dynamic
Invoked when a non-existent method or property is accessed.
_inherited_
##### [sendMessage](../package-fidl_fidl/AsyncBinding/sendMessage.md)([OutgoingMessage](../package-fidl_fidl/OutgoingMessage-class.md) response) void
Sends the given message over the bound channel.
##### [toString](../package-fidl_fidl/AsyncBinding/toString.md)() String
A string representation of this object.
_inherited_
##### [unbind](../package-fidl_fidl/AsyncBinding/unbind.md)() [InterfaceRequest](../package-fidl_fidl/InterfaceRequest-class.md)&lt;T>
Unbinds <a href="../package-fidl_fidl/AsyncBinding/impl.md">impl</a> and returns the unbound channel as an interface request.
##### [wrap](../package-fidl_fidl/AsyncBinding/wrap.md)(T impl) [InterfaceHandle](../package-fidl_fidl/InterfaceHandle-class.md)&lt;T>
Returns an interface handle whose peer is bound to the given object.
## Operators
##### [operator ==](../package-fidl_fidl/AsyncBinding/operator_equals.md)(Object other) bool
The equality operator.
_inherited_