anyMatch method

  1. @override
bool anyMatch(
  1. bool predicate(
    1. T
    )
)
override

Returns whether any elements of this stream match the provided predicate.

Example

final hasEven = GenericStream.of([1, 2, 3, 4, 5])
    .anyMatch((n) => n % 2 == 0); // true

Implementation

@override
bool anyMatch(bool Function(T) predicate) {
  return _source.any(predicate);
}