com.rapidminer.parameter
Class ParameterTypeList

java.lang.Object
  extended by com.rapidminer.parameter.ParameterType
      extended by com.rapidminer.parameter.ParameterTypeList
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable

public class ParameterTypeList
extends ParameterType

A parameter type for parameter lists. Operators ask for the list of the specified values with Operator.getParameterList(String). Please note that in principle arbitrary parameter types can be used for the list values. Internally, however, all values are transformed to strings. Therefore, operators retrieving values from non-string lists (for example for a parameter type category) have to transform the values themself, e.g. with the following code:

int index = ((ParameterTypeCategory)((ParameterTypeList)getParameters().getParameterType(PARAMETER_LIST)).getValueType()).getIndex(pair[1]);

Author:
Ingo Mierswa, Simon Fischer Exp $
See Also:
Serialized Form

Constructor Summary
ParameterTypeList(java.lang.String key, java.lang.String description, ParameterType valueType)
           
ParameterTypeList(java.lang.String key, java.lang.String description, ParameterType valueType, java.util.List defaultList)
           
 
Method Summary
 java.lang.Object getDefaultValue()
          Returns a value that can be used if the parameter is not set.
 java.lang.String getRange()
          Returns a human readable description of the range.
 ParameterType getValueType()
           
 java.lang.String getXML(java.lang.String indent, java.lang.String key, java.lang.String value, boolean hideDefault)
          Writes an xml representation of the given key-value pair.
 boolean isNumerical()
          Returns false.
 void setDefaultValue(java.lang.Object defaultValue)
          Sets the default value.
 
Methods inherited from class com.rapidminer.parameter.ParameterType
compareTo, getDescription, getKey, illegalValue, isExpert, isHidden, isOptional, registerDependencyCondition, setDescription, setExpert, setHidden, setKey, setShowRange, showRange, toString, toString, toXMLString, transformNewValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ParameterTypeList

public ParameterTypeList(java.lang.String key,
                         java.lang.String description,
                         ParameterType valueType)

ParameterTypeList

public ParameterTypeList(java.lang.String key,
                         java.lang.String description,
                         ParameterType valueType,
                         java.util.List defaultList)
Method Detail

getValueType

public ParameterType getValueType()

getDefaultValue

public java.lang.Object getDefaultValue()
Description copied from class: ParameterType
Returns a value that can be used if the parameter is not set.

Specified by:
getDefaultValue in class ParameterType

setDefaultValue

public void setDefaultValue(java.lang.Object defaultValue)
Description copied from class: ParameterType
Sets the default value.

Specified by:
setDefaultValue in class ParameterType

isNumerical

public boolean isNumerical()
Returns false.

Specified by:
isNumerical in class ParameterType

getXML

public java.lang.String getXML(java.lang.String indent,
                               java.lang.String key,
                               java.lang.String value,
                               boolean hideDefault)
Description copied from class: ParameterType
Writes an xml representation of the given key-value pair.

Specified by:
getXML in class ParameterType

getRange

public java.lang.String getRange()
Description copied from class: ParameterType
Returns a human readable description of the range.

Specified by:
getRange in class ParameterType


Copyright © 2001-2009 by Rapid-I