InterfaceRequest<T> class

A channel over which messages from interface T can be received.

An interface request holds a channel whose peer expects to be able to send messages from the FIDL interface T. A channel held by an interface request is not currently bound, which means messages cannot yet be exchanged with the channel's peer.

To receive messages sent over the channel, bind the interface handle using Binding<T>.bind on a TBinding object, which you typically hold as a private member variable in a class that implements T.


class FooImpl extends Foo {
  final FooBinding _binding = new FooBinding();

  void bind(InterfaceRequest<T> request) {

  void bar() {
    print('Received bar message.');

To obtain an interface request to send over a channel, used the ProxyController<T>.request method on the Proxy<T>.ctrl property of an object of type TProxy.


FooProxy foo = new FooProxy();
InterfaceRequest<T> request = foo.ctrl.request();


InterfaceRequest (Channel _channel)

Creates an interface request that wraps the given channel.



The underlying channel messages will be received over when the interface handle is bound to Binding.

hashCode → int

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

runtimeType → Type

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


close() void

Closes the underlying channel.

noSuchMethod(Invocation invocation) dynamic

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

passChannel() Channel

Returns channel and sets channel to null.

toString() String

A string representation of this object.


operator ==(Object other) bool

The equality operator.