*<Null safety>*
Helper class to connect to incoming services.
Incoming is used to connect to the services exposed by a launched component. The general pattern for launching and connecting to a service is:
final incoming = Incoming();
final launchInfo = LaunchInfo(
url: serverUrl,
directoryRequest: incoming.request().passChannel(),
);
final launcherProxy = LauncherProxy();
context.incoming.connectToService(launcherProxy);
launcherProxy.createComponent(launchInfo, ctrl);
final myProxy = MyProxy();
incoming.connectToService(myProxy);
incoming.close();
These services have been offered to this component by its parent or are ambiently offered by the Component Framework.
Constructors
Incoming ()
Initializes Incoming with an unbound DirectoryProxy
which can be used
to bind to a launched component's services.
Initializes Incoming with a Directory
that is bound to /svc
of this
component. ...
factory
Incoming.withDirectory (dynamic _dirProxy)
Initializes Incoming with a Directory
that should be bound to /svc
of this component. ...
Properties
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
Methods
close() Future<int>
Terminates connection and return Zircon status.
connectToService<T>(AsyncProxy<T>? serviceProxy) void
Connects to the incoming service specified by serviceProxy
. ...
connectToServiceByNameWithChannel(String? serviceName, Channel? channel) void
Connects to the incoming service specified by serviceName
through the
channel
endpoint supplied by the caller. ...
connectToServiceWithChannel<T>(AsyncProxy<T>? serviceProxy, Channel? channel) void
Connects to the incoming service specified by serviceProxy
through the
channel
endpoint supplied by the caller. ...
noSuchMethod(Invocation invocation) dynamic
Invoked when a non-existent method or property is accessed. ...
inherited
request() InterfaceRequest
Takes ownership of the Directory's request object for binding to another processes outgoing services. ...
toString() String
Returns a string representation of this object.
inherited
Operators
operator ==(Object other) bool
The equality operator. ...
inherited