Attributes
Members list
Type members
Classlikes
Attributes
- Companion
- trait
- Supertypes
- Self type
-
TicTacToeState$.type
Trait that extends the type class State with a concrete underlying type of TicTacToe.
Trait that extends the type class State with a concrete underlying type of TicTacToe.
Attributes
- Companion
- object
- Supertypes
- Known subtypes
-
object TicTacToeState$
Attributes
- Supertypes
- Self type
-
loggableTicTacToe.type
Inherited and Abstract types
The names of the product elements
The names of the product elements
Attributes
- Inherited from:
- Mirror
The name of the type
The name of the type
Attributes
- Inherited from:
- Mirror
Value members
Concrete methods
Method to construct a starting position TicTacToe.
Method to construct a starting position TicTacToe.
Value parameters
- board
-
the Board that defines a
TicTacToe.
Attributes
- Returns
-
a
TicTacToewith the given board, no predecessor, and an empty board.
Method to construct a starting position TicTacToe.
Method to construct a starting position TicTacToe.
Value parameters
- proto
-
(
Board,TicTacToe).
Attributes
- Returns
-
a
TicTacToewith the given board and no predecessor.
Method to construct a starting position TicTacToe.
Method to construct a starting position TicTacToe.
Attributes
- Returns
-
a
TicTacToewith all empty cells, no predecessor and an emptyBoard.
Apply method mostly for testing.
Apply method mostly for testing.
Value parameters
- board
-
the current
Board. - mask
-
a mask that defines the bits to be eliminated from
boardto yield the previousBoard.
Attributes
- Returns
-
a TicTacToe.
Method to construct a TicTacToe with prior from a particular bit pattern and a mask.
Method to construct a TicTacToe with prior from a particular bit pattern and a mask.
Value parameters
- maybePriorBoard
-
an optional bit pattern to yield the prior state.
- x
-
the bit pattern.
Attributes
- Returns
-
a TicTacToe with all empty cells.
Method to parse a String of Xs and 0s into a TicTacToe, wrapped in Try.
Method to parse a String of Xs and 0s into a TicTacToe, wrapped in Try.
CONSIDER making this private.
Value parameters
- s
-
the String to parse (which may include \n characters for better visualization).
Attributes
- Returns
-
a Try of TicTacToe.
Method to parse a pattern for a starting position. NOTE: do not use for later positions.
Method to parse a pattern for a starting position. NOTE: do not use for later positions.
Value parameters
- s
-
a String made up of 9 case-independent characters, each of which must be an X, 0, O, ., or space. CONSIDER allowing newlines.
Attributes
- Returns
-
a TicTacToe.