onEvent method

void onEvent(
  1. void onEvent(
    1. Event event
    )
)

Implementation

void onEvent(void Function(Event event) onEvent) {
  _onEvent = onEvent;
  _attachStreamEventHandlerIfNeeded();
}