PrintHandler typedef Null safety
The type of a custom Zone.print implementation function.
Receives the Zone that the handler was registered on as
a delegate forwarding to the handlers of
self's parent zone as
and the current zone where the error was uncaught as
which will have
self as a parent zone.
line is the one which was passed to Zone.print of
(possibly through the global print function).
The custom handler can intercept print operations and redirect them to other targets than the console.
The function must only access zone-related functionality through
It should not depend on the current zone (Zone.current).
typedef PrintHandler = void Function( Zone self, ZoneDelegate parent, Zone zone, String line);