class UnsynchronizedDispatcher
Defined at line 287 of file ../../sdk/lib/driver/runtime/include/lib/fdf/cpp/dispatcher.h
Dispatcher that allows parallel calls into callbacks.
Public Methods
zx::result<UnsynchronizedDispatcher> Create (Options options, std::string_view name, ShutdownHandler shutdown_handler, std::string_view scheduler_role)
Creates a dispatcher for performing asynchronous operations.
|options| provides the dispatcher configuration. This will panic if options does not
set FDF_DISPATCHER_OPTION_UNSYNCHRONIZED.
|name| is reported via diagnostics. It is similar to setting the name of a thread. Names longer
than `ZX_MAX_NAME_LEN` may be truncated.
|scheduler_role| is a hint. It may or not impact the priority the work scheduler against the
dispatcher is handled at. It may or may not impact the ability for other drivers to share
zircon threads with the dispatcher.
|shutdown_handler| will be called after |ShutdownAsync| has been called, and the dispatcher
has completed its asynchronous shutdown. The client must keep any pointers that are
referenced in |shutdown_handler| alive until the handler runs.
# Thread requirements
This must be called from a thread managed by the driver runtime.
# Errors
ZX_ERR_NOT_SUPPORTED: |options| is not a supported configuration, which is any of:
* `FDF_DISPATCHER_OPTION_ALLOW_SYNC_CALLS`.
ZX_ERR_INVALID_ARGS: This was not called from a thread managed by the driver runtime.
ZX_ERR_BAD_STATE: Dispatchers are currently not allowed to be created, such as when a driver
is being shutdown by its driver host.
Defined at line 326 of file ../../sdk/lib/driver/runtime/include/lib/fdf/cpp/dispatcher.h
void UnsynchronizedDispatcher (fdf_dispatcher_t * dispatcher)
Defined at line 352 of file ../../sdk/lib/driver/runtime/include/lib/fdf/cpp/dispatcher.h
Unowned<UnsynchronizedDispatcher> borrow ()
Defined at line 361 of file ../../sdk/lib/driver/runtime/include/lib/fdf/cpp/dispatcher.h