Package VASSAL.counters
Class SetGlobalProperty
java.lang.Object
VASSAL.counters.Decorator
VASSAL.counters.DynamicProperty
VASSAL.counters.SetGlobalProperty
- All Implemented Interfaces:
IncrementProperty.Constraints,PropertyChangerConfigurer.Constraints,PropertyNameSource,PropertyPrompt.Constraints,PropertyPrompt.DialogParent,PropertySource,EditablePiece,GamePiece,PropertyExporter,StateMergeable,TranslatablePiece,PersistentPropertyContainer
public class SetGlobalProperty extends DynamicProperty
- Author:
- Brent Easton A trait that allows counters to manipulate the value of Global properties. Uses the Property manipulation functionality of DynamicPropert, but applies them to Global Properties.
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static classSetGlobalProperty.EdNested classes/interfaces inherited from class VASSAL.counters.DynamicProperty
DynamicProperty.DynamicKeyCommand, DynamicProperty.DynamicKeyCommandConfigurer -
Field Summary
Fields Modifier and Type Field Description static StringCURRENT_ZONEprotected Decoratordecprotected Stringdescriptionstatic StringIDstatic StringNAMED_MAPstatic StringNAMED_ZONEprotected PropertyChangeSupportpropertyChangeSupportprotected StringpropertyLevelprotected StringsearchNameFields inherited from class VASSAL.counters.DynamicProperty
format, key, keyCommandListConfig, keyCommands, maxValue, menuCommands, minValue, numeric, value, wrapFields inherited from interface VASSAL.counters.PropertyExporter
LOCALIZED_NAMEFields inherited from interface VASSAL.i18n.TranslatablePiece
PREFIX -
Constructor Summary
Constructors Constructor Description SetGlobalProperty()SetGlobalProperty(String type, GamePiece p) -
Method Summary
Modifier and Type Method Description StringgetDescription()A plain-English description of this type of piecePieceEditorgetEditor()Get the configurer for this traitHelpFilegetHelpFile()ObjectgetLocalizedProperty(Object key)ObjectgetProperty(Object key)StringmyGetState()StringmyGetType()CommandmyKeyEvent(KeyStroke stroke)The response of this trait alone to the given KeyStrokevoidmySetState(String state)Set just the state of this traitvoidmySetType(String s)Set the type information for this piece.voidsetProperty(Object key, Object val)Other properties, possibly game-specific, can be associated with a piece.Methods inherited from class VASSAL.counters.DynamicProperty
boundingBox, decodeConstraints, draw, encodeConstraints, getComponent, getI18nData, getKey, getMaximumValue, getMinimumValue, getName, getPropertyNames, getPropertySource, getShape, getValue, isNumeric, isWrap, myGetKeyCommands, setValueMethods inherited from class VASSAL.counters.Decorator
getCommandDescription, getDecorator, getI18nData, getI18nData, getId, getInner, getInnermost, getKeyCommands, getLocalizedName, getMap, getOuter, getOutermost, getParent, getPersistentProperty, getPosition, getProperties, getState, getTranslation, getType, isSelected, keyEvent, mergeState, putOldProperties, repack, reportDataError, reportDataError, reportDataError, setId, setInner, setMap, setOldProperties, setOldProperties, setParent, setPersistentProperty, setPosition, setSelected, setState, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface VASSAL.counters.GamePiece
getId, getLocalizedName, getMap, getParent, getPosition, getState, getType, keyEvent, setId, setMap, setParent, setPosition, setStateMethods inherited from interface VASSAL.counters.PropertyExporter
getProperties
-
Field Details
-
propertyChangeSupport
-
ID
- See Also:
- Constant Field Values
-
CURRENT_ZONE
- See Also:
- Constant Field Values
-
NAMED_ZONE
- See Also:
- Constant Field Values
-
NAMED_MAP
- See Also:
- Constant Field Values
-
description
-
propertyLevel
-
searchName
-
dec
-
-
Constructor Details
-
SetGlobalProperty
public SetGlobalProperty() -
SetGlobalProperty
-
-
Method Details
-
getDescription
Description copied from interface:EditablePieceA plain-English description of this type of piece- Specified by:
getDescriptionin interfaceEditablePiece- Overrides:
getDescriptionin classDynamicProperty
-
mySetType
Description copied from interface:EditablePieceSet the type information for this piece. SeeDecorator.myGetType()- Specified by:
mySetTypein interfaceEditablePiece- Overrides:
mySetTypein classDynamicProperty
-
myGetType
- Overrides:
myGetTypein classDynamicProperty- Returns:
- the type of this trait alone
- See Also:
Decorator.getType()
-
myGetState
- Overrides:
myGetStatein classDynamicProperty- Returns:
- the state of this trait alone
- See Also:
Decorator.getState()
-
mySetState
Description copied from class:DecoratorSet just the state of this trait- Overrides:
mySetStatein classDynamicProperty- See Also:
Decorator.myGetState()
-
getProperty
- Specified by:
getPropertyin interfaceGamePiece- Specified by:
getPropertyin interfacePropertySource- Overrides:
getPropertyin classDynamicProperty
-
getLocalizedProperty
- Specified by:
getLocalizedPropertyin interfacePropertySource- Overrides:
getLocalizedPropertyin classDynamicProperty
-
setProperty
Description copied from interface:GamePieceOther properties, possibly game-specific, can be associated with a piece. The properties may or may not need to be encoded in the piece'sGamePiece.getState()method.- Specified by:
setPropertyin interfaceGamePiece- Overrides:
setPropertyin classDynamicProperty
-
getHelpFile
- Specified by:
getHelpFilein interfaceEditablePiece- Overrides:
getHelpFilein classDynamicProperty
-
myKeyEvent
Description copied from class:DecoratorThe response of this trait alone to the given KeyStroke- Overrides:
myKeyEventin classDynamicProperty- Parameters:
stroke- Stroke to apply- Returns:
- Generated Command or null if no effect
- See Also:
Decorator.keyEvent(javax.swing.KeyStroke)
-
getEditor
Description copied from interface:EditablePieceGet the configurer for this trait- Specified by:
getEditorin interfaceEditablePiece- Overrides:
getEditorin classDynamicProperty
-