|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.planeth.gtroids.highscores.HighScoreManager
Handles the HighScoreList
(Singleton pattern)
HighScore| Field Summary | |
static int |
MAX_NAME_LENGTH
|
| Method Summary | |
void |
addHighScore(java.lang.String player,
int score)
Adds a HighScore to the list and stores the List on the predefined place |
java.util.List |
getHighScoreList()
Returns the highScoreList. |
java.lang.String |
getHighScoresAsString()
Returns the highScoreList as String |
static HighScoreManager |
getInstance()
Returns the singleton instance |
int |
getPositon(int score)
Returns the temporary position for the passed score in the highScoreList The definitive positon isn't available until the score is saved. |
boolean |
isValidHighScore(int score)
Returns true, if the passed score is a valid highScore |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int MAX_NAME_LENGTH
| Method Detail |
public static HighScoreManager getInstance()
public boolean isValidHighScore(int score)
score - the score to check
public int getPositon(int score)
score - the score to check
public void addHighScore(java.lang.String player,
int score)
player - player's namescore - player's scorepublic java.lang.String getHighScoresAsString()
public java.util.List getHighScoreList()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||