Provides methods to iterate over a collection or list of elements of the same type.
Inheritance Hierarchy
- IIEnumerator<T>
Type Parameters
T
Examples
const e = someList.getEnumerator()
// always move before you access
while (e.moveNext()) {
// get the current element
const current = e.current
}Members
No filters for this type
Properties
This value is undefined if the enumerator is in initial state (after creation or reset<T>) or has been moved past the end of the represented collection.
readonlyabstract
Methods
A newly created enumerator's current position is before the first element. Thus, this method must be called before first access to the current<T> property. The same applies to the state after calling reset<T>.
abstract
Return Value
- boolean
trueif the enumerator was moved to a valid position