|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--com.editev.chess.Chess
|
+--com.editev.chess.piece.Piece
|
+--com.editev.chess.piece.Knight
A Knight is a Piece can jump any other Piece but otherwise has no special rules.
the source here.| Inner classes inherited from class com.editev.chess.Chess |
Chess.Black,
Chess.White |
| Field Summary | |
static byte[][] |
MOVES
An array of all the possible Knight moves as byte offsets. |
static Knight |
PIECE
The unique/singleton instantiation of Knight. |
| Fields inherited from class com.editev.chess.piece.Piece |
moves |
| Fields inherited from class com.editev.chess.Chess |
BLACK,
NO_MOVE,
NO_PIECE,
WHITE |
| Constructor Summary | |
private |
Knight()
This class is a singleton, so the constructor is private. |
| Method Summary | |
boolean |
pieceBetween(Move move,
Board board)
The knight jumps all pieces so piecesBetween always returns false. |
| Methods inherited from class com.editev.chess.piece.Piece |
applyMoveToBoard,
applyMoveToState,
firstMoveIndex,
getColumnOffset,
getRowOffset,
incrementMoveIndex,
isCapture,
isIllegal,
isIrreversible,
moreMoves,
setMoveIndex,
undoMoveToBoard |
| Methods inherited from class com.editev.chess.Chess |
notColor,
toColor,
toColor,
toColorName |
| Methods inherited from class java.lang.Object |
|
| Field Detail |
public static final byte[][] MOVES
public static final Knight PIECE
| Constructor Detail |
private Knight()
| Method Detail |
public boolean pieceBetween(Move move,
Board board)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||