SqCenArrOpt

final class SqCenArrOpt[A <: AnyRef](val unsafeArr: Array[A]) extends AnyVal

An immutable Arr of Opt Tile data for a specific square tile grid SqGrid. This is specialised for OptRef[A]. The tileGrid can map the SqCen coordinate of the tile to the index of the Arr. Hence most methods take an implicit SqGrid square grid parameter.

class AnyVal
trait Matchable
class Any

Value members

Concrete methods

def cMapNones[B, ArrT <: ArrImut[B]](f: SqCen => B)(implicit grid: SqGrid, build: ArrTBuilder[B, ArrT]): ArrT

Coordinate map Nones. Map the None values respective SqCen coordinates of this SqCenArrOpt to type B, the first type parameter. Returns an immutable Array based collection of type ArrT, the second type parameter.

Coordinate map Nones. Map the None values respective SqCen coordinates of this SqCenArrOpt to type B, the first type parameter. Returns an immutable Array based collection of type ArrT, the second type parameter.

def cMapSomes[B, ArrT <: ArrImut[B]](f: (A, SqCen) => B)(implicit grid: SqGrid, build: ArrTBuilder[B, ArrT]): ArrT

Coordinate map Somes. map the some values of this HcenArrOpt, with the respective Hcen coordinate to type B, the first type parameter B. Returns an immutable Array based collection of type ArrT, the second type parameter.

Coordinate map Somes. map the some values of this HcenArrOpt, with the respective Hcen coordinate to type B, the first type parameter B. Returns an immutable Array based collection of type ArrT, the second type parameter.

def length: Int
def mapSomes[B, ArrT <: ArrImut[B]](f: A => B)(implicit build: ArrTBuilder[B, ArrT]): ArrT

Maps the Some values to type B by the parameter function. It ignores the None values. This method treats the SqCenArr class like a standard Arr or Array. It does not utilise the grid SqGrid from which this SqCenArrOpt was created.

Maps the Some values to type B by the parameter function. It ignores the None values. This method treats the SqCenArr class like a standard Arr or Array. It does not utilise the grid SqGrid from which this SqCenArrOpt was created.

def mutMove(s1: SqCen, s2: SqCen)(implicit grid: SqGrid): Unit

Moves the object in the array location given by HCen1 to HCen2, by setting H2 to the value of h1 and setting H1 to null.

Moves the object in the array location given by HCen1 to HCen2, by setting H2 to the value of h1 and setting H1 to null.

def setSome(y: Int, c: Int, value: A)(implicit grid: SqGrid): Unit

Sets the Some value of the square tile data at the specified row and column coordinate values. This is an imperative mutating operation.

Sets the Some value of the square tile data at the specified row and column coordinate values. This is an imperative mutating operation.

def setSome(sc: SqCen, value: A)(implicit grid: SqGrid): Unit

Sets the Some value of the hex tile data at the specified SqCen coordinate. This is an imperative mutating operation.

Sets the Some value of the hex tile data at the specified SqCen coordinate. This is an imperative mutating operation.

def setSomes(triples: (Int, Int, A)*)(implicit grid: SqGrid): Unit

Sets the Some values of the hex tile data at the specified row and column coordinate values. This is an imperative mutating operation.

Sets the Some values of the hex tile data at the specified row and column coordinate values. This is an imperative mutating operation.

Concrete fields

val unsafeArr: Array[A]