|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--VASSAL.build.AbstractBuildable
|
+--VASSAL.build.module.ModuleExtension
An optional extension to a GameModule Like a GameModule, it is built from scratch from a 'buildFile' in a DataArchive The components described in the buildFile are appended to components in the base DataArchive
| Nested Class Summary | |
static class |
ModuleExtension.RegCmd
A command that verifies that a certain extension has been loaded |
| Field Summary | |
static java.lang.String |
BASE_MODULE_NAME
|
static java.lang.String |
BASE_MODULE_VERSION
|
static java.lang.String |
VERSION
|
| Fields inherited from class VASSAL.build.AbstractBuildable |
buildComponents |
| Constructor Summary | |
ModuleExtension(DataArchive archive)
|
|
| Method Summary | |
void |
addTo(Buildable parent)
Adds this component to its parent. |
void |
build()
|
java.lang.String |
buildString()
|
boolean |
confirmExit()
|
java.lang.Class[] |
getAllowableConfigureComponents()
|
java.lang.String[] |
getAttributeNames()
|
java.lang.String |
getAttributeValueString(java.lang.String key)
Return a String representation of the attribute with the given name. |
DataArchive |
getDataArchive()
|
javax.swing.Action |
getEditAction(java.awt.Frame f)
|
HelpFile |
getHelpFile()
|
java.lang.String |
getName()
|
Command |
getRestoreCommand()
When saving a game, each GameComponent should return a Command that, when executed, restores the GameComponent to its
state when the game was saved
If this component has no persistent state, return null |
java.lang.String |
getVersion()
|
void |
remove(ExtensionElement el)
|
void |
removeFrom(Buildable parent)
|
void |
save()
|
void |
saveAs()
|
void |
setAttribute(java.lang.String key,
java.lang.Object value)
Sets an attribute value for this component. |
void |
setup(boolean gameStarting)
Notify the GameComponent that a game has started/ended |
| Methods inherited from class VASSAL.build.AbstractBuildable |
add, build, getBuildComponents, getBuildElement, getComponents |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String BASE_MODULE_NAME
public static final java.lang.String BASE_MODULE_VERSION
public static final java.lang.String VERSION
| Constructor Detail |
public ModuleExtension(DataArchive archive)
| Method Detail |
public java.lang.String getVersion()
public DataArchive getDataArchive()
public void build()
public Command getRestoreCommand()
GameComponentCommand that, when executed, restores the GameComponent to its
state when the game was saved
If this component has no persistent state, return null
getRestoreCommand in interface GameComponentpublic void setup(boolean gameStarting)
GameComponent
setup in interface GameComponentgameStarting - if true, a game is starting. If false, then a game is endingpublic java.lang.String[] getAttributeNames()
getAttributeNames in class AbstractBuildablepublic java.lang.Class[] getAllowableConfigureComponents()
public HelpFile getHelpFile()
public void removeFrom(Buildable parent)
public boolean confirmExit()
public java.lang.String getAttributeValueString(java.lang.String key)
AbstractBuildableAbstractBuildable.setAttribute(java.lang.String, java.lang.Object).
getAttributeValueString in class AbstractBuildablekey - the name of the attribute. Will be one of those
listed in AbstractBuildable.getAttributeNames()
public void setAttribute(java.lang.String key,
java.lang.Object value)
AbstractBuildablekey
parameter will be one of those listed in AbstractBuildable.getAttributeNames().
If the value parameter is a String, it will be the
value returned by AbstractBuildable.getAttributeValueString(java.lang.String) for the same
key. If the implementing class extends
AbstractConfigurable, then value will be
an instance of the corresponding Class listed in
AbstractConfigurable.getAttributeTypes()
setAttribute in class AbstractBuildablekey - the name of the attribute. Will be one of those
listed in AbstractBuildable.getAttributeNames()public void addTo(Buildable parent)
Buildable
addTo in interface Buildablepublic java.lang.String getName()
public java.lang.String buildString()
public void save()
throws java.io.IOException
java.io.IOException
public void saveAs()
throws java.io.IOException
java.io.IOExceptionpublic void remove(ExtensionElement el)
public javax.swing.Action getEditAction(java.awt.Frame f)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||