|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.freecol.common.model.Turn
public class Turn
Represents a given turn in the game.
| Field Summary | |
|---|---|
static int |
SEASON_YEAR
|
static int |
STARTING_YEAR
|
private int |
turn
|
| Constructor Summary | |
|---|---|
Turn(int turn)
|
|
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object o)
Checks if this turn is equal to another turn. |
int |
getAge()
Gets the age. |
int |
getNumber()
Gets the turn number. |
int |
getYear()
Gets the year this turn is in. |
static int |
getYear(int turn)
Gets the year the given turn is in. |
void |
increase()
Increases the turn number by one. |
void |
setNumber(int turn)
Sets the turn number. |
java.lang.String |
toSaveGameString()
Returns a string representation of this turn suitable for savegame files. |
java.lang.String |
toString()
Returns a string representation of this turn. |
static java.lang.String |
toString(int turn)
Returns a string representation of the given turn. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final int STARTING_YEAR
public static final int SEASON_YEAR
private int turn
| Constructor Detail |
|---|
public Turn(int turn)
| Method Detail |
|---|
public void increase()
public int getNumber()
public void setNumber(int turn)
turn - The number of turns.public int getAge()
SEASON_YEAR
public boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic static int getYear(int turn)
public int getYear()
public java.lang.String toString()
toString in class java.lang.Objectpublic static java.lang.String toString(int turn)
public java.lang.String toSaveGameString()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||