|
|||||||||
Home >> All >> [ simplegame overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: ![]() ![]() ![]() |
DETAIL: FIELD | CONSTR | METHOD |
simplegame
Class SimpleGameDataModel

java.lang.Objectsimplegame.SimpleGameDataModel
- All Implemented Interfaces:
- SimpleGameDataModelIF
- public class SimpleGameDataModel
- extends java.lang.Object
- implements SimpleGameDataModelIF
- extends java.lang.Object
Nested Class Summary |
Nested classes inherited from class simplegame.SimpleGameDataModelIF |
SimpleGameDataModelIF.GameUpdateListener |
Field Summary | |
private int[][] |
gameBoard
|
private int |
size
|
private java.util.Vector |
vUpdateListener
|
Constructor Summary | |
SimpleGameDataModel(int size)
|
Method Summary | |
void |
addGameUpdateListener(SimpleGameDataModelIF.GameUpdateListener ul)
|
private void |
fireUpdate(int row,
int column,
int id)
|
int |
getRPCharacterAt(int row,
int column)
|
int |
getSize()
|
int |
getWinnerID()
|
void |
setRPCharacterAt(int row,
int column,
int id)
|
java.lang.String |
toString()
Convert this Object to a human-readable String. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
gameBoard
private int[][] gameBoard
vUpdateListener
private java.util.Vector vUpdateListener
size
private int size
Constructor Detail |
SimpleGameDataModel
public SimpleGameDataModel(int size)
Method Detail |
fireUpdate
private void fireUpdate(int row, int column, int id)
addGameUpdateListener
public void addGameUpdateListener(SimpleGameDataModelIF.GameUpdateListener ul)
- Specified by:
addGameUpdateListener
in interfaceSimpleGameDataModelIF
setRPCharacterAt
public void setRPCharacterAt(int row, int column, int id)
- Specified by:
setRPCharacterAt
in interfaceSimpleGameDataModelIF
getSize
public int getSize()
- Specified by:
getSize
in interfaceSimpleGameDataModelIF
getRPCharacterAt
public int getRPCharacterAt(int row, int column)
- Specified by:
getRPCharacterAt
in interfaceSimpleGameDataModelIF
toString
public java.lang.String toString()
- Description copied from class:
java.lang.Object
- Convert this Object to a human-readable String.
There are no limits placed on how long this String
should be or what it should contain. We suggest you
make it as intuitive as possible to be able to place
it into System.out.println() 55
and such.
It is typical, but not required, to ensure that this method never completes abruptly with a java.lang.RuntimeException.
This method will be called when performing string concatenation with this object. If the result is
null
, string concatenation will instead use"null"
.The default implementation returns
getClass().getName() + "@" + Integer.toHexString(hashCode())
.
getWinnerID
public int getWinnerID()
- Specified by:
getWinnerID
in interfaceSimpleGameDataModelIF
|
|||||||||
Home >> All >> [ simplegame overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: ![]() ![]() ![]() |
DETAIL: FIELD | CONSTR | METHOD |