onOutput<TOutput extends Object> method

  1. @override
void onOutput<TOutput extends Object>(
  1. OutputCallback<TOutput> handler
)
inherited

Registers a handler to be invoked whenever an output of type TOutput is produced.

Implementation

@override
void onOutput<TOutput extends Object>(OutputCallback<TOutput> handler) {
  _outputCheckers.add((output) => output is TOutput);
  _outputRunners.add((output) => handler(output as TOutput));
}