get

fun get(index: Int): Piece

Returns the Piece enum constant corresponding to the given zero-based index. The index order is typically 0 to 12, starting with EMPTY.

Return

The corresponding Piece enum constant.

Since

1.0.0-beta.1

Parameters

index

The zero-based index of the piece.

Throws

if the index is outside the valid range.