addListener method

void addListener(
  1. void listener(
    1. PintoError
    )
)

Adds a listener to the handler.

A listener will be called whenever an error is emitted. The emmited error is passed to the listener.

Implementation

void addListener(void Function(PintoError) listener) => _listeners.add(listener);