|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.huguesjohnson.hapsby.SaveGameDefinition
public class SaveGameDefinition
Class to define the attributes and editable fields of a save game.
| Constructor Summary | |
|---|---|
SaveGameDefinition()
Constructor, no logic implemented. |
|
| Method Summary | |
|---|---|
java.lang.String |
getGameDescription()
Returns the description of the game. |
java.lang.String |
getGameTitle()
Returns the game title. |
java.util.ArrayList<SaveGameProperty> |
getProperties()
Returns all properties in this save game definition. |
java.lang.String |
getSaveFilePattern()
Returns the name, or pattern of the save game. |
SaveGameProperty |
getSaveGameProperty(int index)
Accesses a specific save game property. |
void |
setGameDescription(java.lang.String gameDescription)
Sets the game description. |
void |
setGameTitle(java.lang.String gameTitle)
Sets the game title. |
void |
setProperties(java.util.ArrayList<SaveGameProperty> properties)
Sets the property list. |
void |
setSaveFilePattern(java.lang.String saveFilePattern)
Sets the save file pattern. |
java.lang.String |
toString()
Returns the game title. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public SaveGameDefinition()
| Method Detail |
|---|
public final java.lang.String getGameTitle()
public final java.lang.String getGameDescription()
public final java.lang.String getSaveFilePattern()
public java.util.ArrayList<SaveGameProperty> getProperties()
public SaveGameProperty getSaveGameProperty(int index)
index - Index of the element to retrieve.
SaveGameProperty at the specified index.public void setProperties(java.util.ArrayList<SaveGameProperty> properties)
properties - The new properties for the save game.public void setGameTitle(java.lang.String gameTitle)
gameTitle - The new title for the save game.public void setGameDescription(java.lang.String gameDescription)
gameDescription - The new game description.public void setSaveFilePattern(java.lang.String saveFilePattern)
saveFilePattern - The new file name (ie. save.dat) or pattern (ie. *.dat) of the game.public java.lang.String toString()
toString() is implicitly called by JList and JTable components when complex objects are added.
This needs to return the text that should be displayed in these controls. In this case, it's the game title.
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||