Honoring Asian Pacific American Heritage Month. See how.

Agent class

*[<Null safety>](https://dart.dev/null-safety)*

Agent is a globally available object which simplifies common tasks that agent developers will face. At a high level, it is a wrapper around the agent_context.fidl and agent.fidl interface.


Agent ()

Initializes the shared Agent instance. factory


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


exposeService<T extends Service>(FutureOr<T> serviceImpl) void

Associate serviceImpl to this Agent and exposes it to the rest of the system so that it can be discovered and connected to. Notice that serviceImpl is of type FutureOr<T>, where T represents the service type, to enable the ability to wait for any asynchronous operations to finish before initializing and exposing the service. ...

exposeServiceProvider<T extends Service>(ServiceProvider<T> serviceProvider, ServiceData<T> serviceData) void

Similar to #exposeService but instead of passing the service implementation directly, pass a provider function that can be invoked asynchronously, when a request is received, to provide the service implementation at run time. ...

noSuchMethod(Invocation invocation) dynamic

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

serve(Outgoing outgoing) void

Exposes the Agent's fidl.Agent instance to the Outgoing directory. In other words, advertises this as an fidl.Agent to the rest of the system via Outgoing. ...

toString() String

A string representation of this object. ...


operator ==(Object other) bool

The equality operator. ...