|
Jadex 0.96 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IBoard
The interface for the playing board.
Field Summary | |
---|---|
static String |
MOVE
Property event for move made. |
static String |
TAKEBACK
Property event for move taken back. |
Method Summary | |
---|---|
void |
addPropertyChangeListener(PropertyChangeListener listener)
Add a PropertyChangeListener to the listener list. |
List |
getCurrentPosition()
Get the current board position. |
Move |
getLastMove()
Get all moves made so far. |
List |
getMoves()
Get all moves made so far. |
Piece |
getPiece(Position pos)
Get a piece for a location. |
List |
getPossibleMoves()
Get possible moves. |
int |
getSize()
Get the board size. |
boolean |
isFreePosition(Position pos)
Test if aposition is free. |
boolean |
isSolution()
Test if it is a solution. |
boolean |
move(Move move)
Do a move. |
void |
removePropertyChangeListener(PropertyChangeListener listener)
Remove a PropertyChangeListener from the listener list. |
boolean |
takeback()
Takeback a move. |
boolean |
wasLastMoveWhite()
Test if the last move was with a white piece. |
Field Detail |
---|
static final String MOVE
static final String TAKEBACK
Method Detail |
---|
Piece getPiece(Position pos)
List getPossibleMoves()
boolean move(Move move)
move
- The move.boolean takeback()
boolean isSolution()
List getMoves()
Move getLastMove()
int getSize()
List getCurrentPosition()
boolean isFreePosition(Position pos)
boolean wasLastMoveWhite()
void addPropertyChangeListener(PropertyChangeListener listener)
listener
- The PropertyChangeListener to be added.void removePropertyChangeListener(PropertyChangeListener listener)
listener
- The PropertyChangeListener to be removed.
|
Jadex 0.96 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright (C) 2002-2007 Lars Braubach, Alexander Pokahr - University of Hamburg. Use is subject to license terms.