MirrorDispatcher class Null safety
MirrorDispatcher implements Dispatcher by introspecting a class instance
dart:mirrors. dart:mirrors allows you to invoke an instance's methods
by their string names.
Construct a MirrorDispatcher with a class instance. MirrorDispatcher.dispatch("someMethod") will return a Future of whatever value it returns. It's mainly a wrapper around reflect. For any method dispatched, Dispatcher returns either the return value of the method or instances of one of three "Exception" classes. Most errors will be corralled into these objects, so that runtime exceptions don't get thrown, instead are returned in an orderly manner.
- Implemented types
- MirrorDispatcher(dynamic instance)
String methodName, [dynamic positionalParams, Map< String, dynamic>? namedParams]) → Future
Invoke named method with parameters on an instance.
Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
) → String
A string representation of this object.