Package VASSAL.configure
Class StringArrayConfigurer
java.lang.Object
VASSAL.configure.Configurer
VASSAL.configure.StringArrayConfigurer
- Direct Known Subclasses:
FormattedStringArrayConfigurer
public class StringArrayConfigurer extends Configurer
A Configurer that returns an array of Strings
-
Field Summary
Fields Modifier and Type Field Description protected JList<String>
list
protected DefaultListModel<String>
model
protected JPanel
panel
protected JTextField
textField
Fields inherited from class VASSAL.configure.Configurer
changeSupport, frozen, key, name, NAME_PROPERTY, noUpdate, value
-
Constructor Summary
Constructors Constructor Description StringArrayConfigurer(String key, String name)
StringArrayConfigurer(String key, String name, Object val)
-
Method Summary
Modifier and Type Method Description protected void
addTextActionListener(ActionListener a)
void
addValue(String s)
static String
arrayToString(String[] s)
Component
getControls()
GUI interface for setting the option in an editing windowDefaultListModel<String>
getModel()
String[]
getStringArray()
protected Component
getTextComponent()
protected String
getTextValue()
String
getValueString()
static void
main(String[] args)
void
removeValue(String s)
protected void
setTextValue(String s)
void
setValue(Object o)
Set the Object valuevoid
setValue(String s)
Set the Object value from a Stringstatic String[]
stringToArray(String s)
protected void
updateModel()
Methods inherited from class VASSAL.configure.Configurer
addPropertyChangeListener, fireUpdate, getKey, getName, getValue, isFrozen, removePropertyChangeListener, setFrozen, setName
-
Field Details
-
panel
-
list
-
model
-
textField
-
-
Constructor Details
-
StringArrayConfigurer
-
StringArrayConfigurer
-
-
Method Details
-
getModel
-
addValue
-
removeValue
-
getControls
Description copied from class:Configurer
GUI interface for setting the option in an editing window- Specified by:
getControls
in classConfigurer
-
getTextComponent
-
getTextValue
-
setTextValue
-
addTextActionListener
-
getStringArray
-
getValueString
- Specified by:
getValueString
in classConfigurer
- Returns:
- a String representation of the Object value
-
arrayToString
-
setValue
Description copied from class:Configurer
Set the Object value- Overrides:
setValue
in classConfigurer
-
setValue
Description copied from class:Configurer
Set the Object value from a String- Specified by:
setValue
in classConfigurer
-
stringToArray
-
updateModel
protected void updateModel() -
main
-