|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Object | +--Rules
The Rules class is used to verify that players are playing by the rules for the game Tic Tac Toe. Bugs: none known
| Constructor Summary | |
Rules()
|
|
| Method Summary | |
static void |
checkMove(Move move,
Board board)
Checks if a specified move is valid for the specified board. |
static void |
checkWin(Board board,
Move move,
Mark mark)
Checks if a specified move results in a win for the specified mark on the board. |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| Constructor Detail |
public Rules()
| Method Detail |
public static void checkMove(Move move,
Board board)
move - the specified move to be checkedboard - the specified board on which the move would be made
public static void checkWin(Board board,
Move move,
Mark mark)
move - the specified move where the checking is to be basedboard - the board to be checked for a winmark - the mark of the player that is to be checked for a win
|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||