|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectMonopoly.Cell
public class Cell
This class represents one cell on the board of Monopoly.
Contains methods for seeing the name of the cell and it's location on the board
Implementation invariants: name is constant, location is constant greater than zero
| Constructor Summary | |
|---|---|
Cell()
Constructs an empty cell. |
|
Cell(java.lang.String name,
int location)
Constructs an new cell with a specific name and location. |
|
| Method Summary | |
|---|---|
void |
act(Monopoly game)
Empty method. |
int |
getLocation()
Returns the cardinal number of the cell (Accessor). |
java.lang.String |
getName()
Returns the name of the cell (Accessor). |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Cell()
public Cell(java.lang.String name,
int location)
| Method Detail |
|---|
public java.lang.String getName()
public int getLocation()
public void act(Monopoly game)
act in interface Interactivegame - the Monopoly instance that represents the game.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||