EventReader<T> class
final
A cursor-based reader over an EventChannel.
Each call to drain returns the events sent since the previous call and advances this reader's cursor to the channel's current end.
Properties
Methods
-
consume(
) → bool - Consumes unread events and reports whether any existed.
-
drain(
) → List< T> - Returns and consumes all events this reader has not yet seen.
-
forEach(
void callback(T event)) → void -
Invokes
callbackfor every unread event without allocating a result list, then advances this reader's cursor. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited