HostAtomDispatcher typedef
HostAtomDispatcher =
Future<Object?> Function(String atomKey, String verb, List<Object?> args, List<NonJsonArgument> nonJson)
Dispatcher signature — given an atom key + verb + args list, the host
computes the atom's return value (JSON-serializable). Errors thrown from
the dispatcher are forwarded to the JS side as __hostReject with the
exception's string form.
nonJson lists the arguments JSON could not carry. They arrive in args
as null; a non-empty list means the call is refused, never dispatched
with the substituted value.
Implementation
typedef HostAtomDispatcher = Future<Object?> Function(
String atomKey,
String verb,
List<Object?> args,
List<NonJsonArgument> nonJson,
);