edu.wisc.ssec.mcidasv.startupmanager.options
Class SliderOption
java.lang.Object
edu.wisc.ssec.mcidasv.startupmanager.options.AbstractOption
edu.wisc.ssec.mcidasv.startupmanager.options.SliderOption
- All Implemented Interfaces:
- Option
public class SliderOption
- extends AbstractOption
minValue
private final int minValue
- See Also:
- Constant Field Values
maxValue
private final int maxValue
- See Also:
- Constant Field Values
total
private final int total
sliderValue
private int sliderValue
SliderOption
public SliderOption(String id,
String label,
String defaultValue,
OptionMaster.OptionPlatform optionPlatform,
OptionMaster.Visibility optionVisibility)
makeChangeListener
private ChangeListener makeChangeListener(JLabel sliderLabel)
getComponent
public JComponent getComponent()
- Description copied from class:
AbstractOption
- Returns the GUI component that represents the option.
BooleanOption
s are represented by a JCheckBox
, while
TextOption
s appear as a JTextField
.
- Specified by:
getComponent
in interface Option
- Specified by:
getComponent
in class AbstractOption
- Returns:
- The GUI representation of this option.
getValue
public String getValue()
- Description copied from class:
AbstractOption
- Returns the value of the option. Note that
BooleanOption
s
return either "0" or "1".
- Specified by:
getValue
in interface Option
- Specified by:
getValue
in class AbstractOption
- Returns:
- The current value of the option.
setValue
public void setValue(String newValue)
- Description copied from class:
AbstractOption
- Forces the value of the option to the data specified. Note that
BooleanOption
s accept either "0", or "1".
- Specified by:
setValue
in interface Option
- Specified by:
setValue
in class AbstractOption
- Parameters:
newValue
- New value to use.
toString
public String toString()
- Description copied from class:
AbstractOption
- Friendly string representation of the option.
- Specified by:
toString
in interface Option
- Specified by:
toString
in class AbstractOption
- Returns:
- String containing relevant info about the option.
- See Also:
TextOption.toString()
,
BooleanOption.toString()