|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Object | +--reversi.Coordinates
Die Klasse Coordinates beschreibt eine Position auf dem Spielfeld. Sie wird von den Methoden nextMove() (interface ReversiPlayer) und getPosition() (interface GameBoard) genutzt.
| Constructor Summary | |
Coordinates(int row,
int col)
Erzeugt eine neues Coordinates-Objekt, das die Position row (Zeile), col (Spalte) auf dem Spielfeld beschreibt. |
|
| Method Summary | |
int |
getCol()
Liefert die Spalte der durch das Objekt beschriebenen Position zurück. |
int |
getRow()
Liefert die Zeile der durch das Objekt beschriebenen Position zurück. |
java.lang.String |
toString()
Liefert eine String-Darstellung der duch das Objekt beschriebenen Position zurück, z.B.: Coordinates( 4, 7
). |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public Coordinates(int row,
int col)
| Method Detail |
public int getRow()
public int getCol()
public java.lang.String toString()
Coordinates( 4, 7
).toString in class java.lang.Object
|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||