listen<T> abstract method

StreamSubscription<T> listen<T>(
  1. Stream<T> stream,
  2. void listener(
    1. T it
    ), {
  3. void onDone()?,
  4. void onError(
    1. Object error,
    2. StackTrace
    )?,
})

Implementation

StreamSubscription<T> listen<T>(
  Stream<T> stream,
  void Function(T it) listener, {
  void Function()? onDone,
  void Function(Object error, StackTrace)? onError,
});