Class DoubleArrayConfigKey
java.lang.Object
uk.ac.starlink.ttools.plot2.config.ConfigKey<double[]>
uk.ac.starlink.ttools.plot2.config.DoubleArrayConfigKey
Config key for a list of floating point values.
- Since:
- 9 Jan 2017
- Author:
- Mark Taylor
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionSpecifier<double[]> Constructs a graphical control with which the user can specify a suitable value for association with this key.double[]stringToValue(String txt) Decodes a string value to the value type of this key.valueToString(double[] dvals) Reports a value as a string.Methods inherited from class ConfigKey
cast, getDefaultValue, getMeta, getValueClass, toString
-
Constructor Details
-
DoubleArrayConfigKey
Constructor.- Parameters:
meta- metadatadflt- default value
-
-
Method Details
-
valueToString
Description copied from class:ConfigKeyReports a value as a string. If at all possible the roundtripping should be possible, sostringToValue(valueToString(v)).equals(v). A null value, if permitted, should be represented as an empty string.- Specified by:
valueToStringin classConfigKey<double[]>- Parameters:
dvals- possible value associated with this key- Returns:
- string representation
-
stringToValue
Description copied from class:ConfigKeyDecodes a string value to the value type of this key. An empty string should be interpreted as a null value, but this may cause an exception if null is not a permissible value for this key.- Specified by:
stringToValuein classConfigKey<double[]>- Parameters:
txt- string representation of value- Returns:
- value
- Throws:
ConfigException
-
createSpecifier
Description copied from class:ConfigKeyConstructs a graphical control with which the user can specify a suitable value for association with this key.- Specified by:
createSpecifierin classConfigKey<double[]>- Returns:
- new specifier
-