public class DoubleParameter extends NumberParameter<DoubleParameter,java.lang.Double>
constraints, defaultValue, givenValue, optionalParameter, optionid, shortDescription| Constructor and Description |
|---|
DoubleParameter(OptionID optionID)
Constructs a double parameter with the given optionID.
|
DoubleParameter(OptionID optionID,
double defaultValue)
Constructs a double parameter with the given optionID and default value.
|
| Modifier and Type | Method and Description |
|---|---|
double |
doubleValue()
Get the parameter value as double.
|
java.lang.String |
getSyntax()
Returns a string representation of the parameter's type.
|
java.lang.String |
getValueAsString()
Get the value as string.
|
protected java.lang.Double |
parseValue(java.lang.Object obj)
Parse a given value into the destination type.
|
addConstraint, describeValues, getConstraints, getDefaultValue, getDefaultValueAsString, getOptionID, getShortDescription, getValue, hasDefaultValue, isDefined, isOptional, isValid, setDefaultValue, setOptional, setShortDescription, setValue, setValueInternal, tookDefaultValue, tryDefaultValue, validatepublic DoubleParameter(OptionID optionID, double defaultValue)
optionID - the unique optionIDdefaultValue - the default value for this double parameterpublic DoubleParameter(OptionID optionID)
optionID - the unique id of this parameterpublic java.lang.String getValueAsString()
ParameternullgetValueAsString in interface Parameter<java.lang.Double>getValueAsString in class AbstractParameter<DoubleParameter,java.lang.Double>protected java.lang.Double parseValue(java.lang.Object obj)
throws WrongParameterValueException
AbstractParameterparseValue in class AbstractParameter<DoubleParameter,java.lang.Double>obj - Object to parse (may be a string representation!)WrongParameterValueExceptionpublic java.lang.String getSyntax()
getSyntax in interface Parameter<java.lang.Double>getSyntax in class AbstractParameter<DoubleParameter,java.lang.Double>public double doubleValue()
Copyright © 2019 ELKI Development Team. License information.