emit method

void emit(
  1. S state
)

Emit the state if the controller is not closed

Implementation

void emit(S state) {
  if (!_controller.isClosed) {
    _controller.add(state);
  }
}