first property
- @override
- @Deprecated("Use next() instead. This consumes the first element of the iterator. Which is likely not the users intent.")
override
The first element.
Throws a StateError if this
is empty.
Otherwise returns the first element in the iteration order,
equivalent to this.elementAt(0)
.
Implementation
@override
@Deprecated(
"Use next() instead. This consumes the first element of the iterator. Which is likely not the users intent.")
T get first {
assert(false,
"Use next() instead. This consumes the first element of the iterator. Which is likely not the users intent.");
return super.first;
}