de.lmu.ifi.dbs.elki.utilities.optionhandling
Class IntListParameter
java.lang.Object
de.lmu.ifi.dbs.elki.logging.AbstractLoggable
de.lmu.ifi.dbs.elki.utilities.optionhandling.Option<T>
de.lmu.ifi.dbs.elki.utilities.optionhandling.Parameter<List<T>,List<T>>
de.lmu.ifi.dbs.elki.utilities.optionhandling.ListParameter<Integer>
de.lmu.ifi.dbs.elki.utilities.optionhandling.IntListParameter
- All Implemented Interfaces:
- Loggable
public class IntListParameter
- extends ListParameter<Integer>
Paramter class for a parameter specifying a list of integer values.
- Author:
- Elke Achtert
Method Summary |
protected String |
getParameterType()
Returns a string representation of the parameter's type. |
boolean |
isValid(String value)
Checks if the given argument is valid for this option. |
void |
setDefaultValue(int allListDefaultValue)
Sets the default value of this parameter. |
void |
setValue(String value)
Sets the value of the option. |
Methods inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.Parameter |
addConstraint, addConstraintList, getDefaultValue, getDescription, getValue, hasDefaultValue, isOptional, isSet, reset, setDefaultValue, setDefaultValueToValue, setOptional, tookDefaultValue |
Methods inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable |
debugFine, debugFiner, debugFinest, exception, message, progress, progress, progress, verbose, verbose, warning |
IntListParameter
@Deprecated
public IntListParameter(String name,
String description)
- Deprecated.
- Constructs an integer list parameter with the given name and description.
- Parameters:
name
- the parameter namedescription
- the parameter description
IntListParameter
@Deprecated
public IntListParameter(String name,
String description,
ParameterConstraint<List<Integer>> con)
- Deprecated.
- Constructs an integer list parameter with the given name, description, and parameter constraint.
- Parameters:
name
- the parameter namedescription
- the parameter descriptioncon
- the parameter constraint of this double list parameter
setValue
public void setValue(String value)
throws ParameterException
- Description copied from class:
Option
- Sets the value of the option.
- Specified by:
setValue
in class Option<List<Integer>>
- Parameters:
value
- the option's value to be set
- Throws:
ParameterException
- if the given value is not a valid value for this option.- See Also:
Option.setValue(String)
isValid
public boolean isValid(String value)
throws ParameterException
- Description copied from class:
Option
- Checks if the given argument is valid for this option.
- Specified by:
isValid
in class Option<List<Integer>>
- Parameters:
value
- option value to be checked
- Returns:
- true, if the given value is valid for this option
- Throws:
ParameterException
- if the given value is not a valid value for this option.- See Also:
Option.isValid(java.lang.String)
setDefaultValue
public void setDefaultValue(int allListDefaultValue)
- Sets the default value of this parameter.
- Parameters:
allListDefaultValue
- default value for all list elements of this parameter
getParameterType
protected String getParameterType()
- Returns a string representation of the parameter's type.
- Specified by:
getParameterType
in class Parameter<List<Integer>,List<Integer>>
- Returns:
- "<int_1,...,int_n>"
- See Also:
Parameter.getParameterType()