firstWhere method
String firstWhere(Returns the first element that satisfies the given predicate test
.
Iterates through elements and returns the first to satisfy test
.
If no element satisfies test
, the result of invoking the orElse
function is returned. If orElse
is omitted, it defaults to throwing a StateError
.
Source
String firstWhere(bool test(String value), {String orElse()}) => readClasses().firstWhere(test, orElse: orElse);
© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dartlang.org/stable/1.24.3/dart-svg/AttributeClassSet/firstWhere.html