Skip to main content

Class: PlayerIterator

This type is usable for iterating over a set of players. This means it can be used in statements like for...of statements, Array.from(iterator), and more.

Implements

Constructors

new PlayerIterator()

private new PlayerIterator(): PlayerIterator

Returns

PlayerIterator

Methods

[iterator]()

[iterator](): Iterator ↗️ <Player, any, undefined>

Returns

Iterator ↗️ <Player, any, undefined>

Implementation of

Iterable.[iterator]

Remarks

This function can't be called in read-only mode.


next()

next(): IteratorResult ↗️ <Player, any>

Returns

IteratorResult ↗️ <Player, any>

Remarks

Retrieves the next item in this iteration. The resulting IteratorResult contains .done and .value properties which can be used to see the next Player in the iteration.

This function can't be called in read-only mode.