Package edu.cmu.tetrad.util
Class Parameters
java.lang.Object
edu.cmu.tetrad.util.Parameters
- All Implemented Interfaces:
- TetradSerializable,- Serializable
Stores a list of named parameters with their values. Stores default values for known parameters. Returns a list of
 parameters with their values, for the parameters whose values have been retrieved, using the toString method.
- Version:
- $Id: $Id
- Author:
- josephramsey
- See Also:
- 
Constructor SummaryConstructorsConstructorDescriptionConstructor for Parameters.Parameters(Parameters parameters) Constructor for Parameters.
- 
Method SummaryModifier and TypeMethodDescriptionReturns the object value of the given parameter, looking up its default in the ParamDescriptions map.Returns the object value of the given parameter, using the given default.booleangetBoolean(String name) Returns the boolean value of the given parameter, looking up its default in the ParamDescriptions map.booleangetBoolean(String name, boolean defaultValue) Returns the boolean value of the given parameter, using the given default.doubleReturns the double value of the given parameter, looking up its default in the ParamDescriptions map.doubleReturns the object value of the given parameter, using the given default.intReturns the integer value of the given parameter, looking up its default in the ParamDescriptions map.intReturns the integer value of the given parameter, looking up its default in the ParamDescriptions map.longReturns the long value of the given parameter, looking up its default in the ParamDescriptions map.longReturns the long value of the given parameter, looking up its default in the ParamDescriptions map.intgetNumValues(String name) Returns the number of values for the parameter.getParametersNames.Returns the string value of the given parameter, looking up its default in the ParamDescriptions map.Returns the string value of the given parameter, using the given default.Object[]Returns the values set for the given parameter.voidputAll(Parameters parameters) putAll.voidRemoves the specified parameter from the list of parameters.static ParametersserializableInstance.voidSets the given parameter to the given value.voidSets the value(s) of the given parameter to a list of strings.voidSets the given parameter to the given value.voidSets the value(s) of the given parameter to a list of values.toString()
- 
Constructor Details- 
Parameterspublic Parameters()Constructor for Parameters. 
- 
ParametersConstructor for Parameters. - Parameters:
- parameters- a- Parametersobject
 
 
- 
- 
Method Details- 
serializableInstanceserializableInstance. - Returns:
- a Parametersobject
 
- 
putAllputAll. - Parameters:
- parameters- a- Parametersobject
 
- 
toStringReturns a list of the parameters whose values were actually used in the course of the simulation. 
- 
getIntReturns the integer value of the given parameter, looking up its default in the ParamDescriptions map.- Parameters:
- name- The name of the parameter.
- Returns:
- The integer value of this parameter.
 
- 
getLongReturns the long value of the given parameter, looking up its default in the ParamDescriptions map.- Parameters:
- name- The name of the parameter.
- Returns:
- The long value of this parameter.
 
- 
getBooleanReturns the boolean value of the given parameter, looking up its default in the ParamDescriptions map.- Parameters:
- name- The name of the parameter.
- Returns:
- The boolean value of this parameter.
 
- 
getDoubleReturns the double value of the given parameter, looking up its default in the ParamDescriptions map.- Parameters:
- name- The name or the parameter.
- Returns:
- The double value of this parameter.
 
- 
getStringReturns the string value of the given parameter, looking up its default in the ParamDescriptions map.- Parameters:
- name- The name or the parameter.
- Returns:
- The string value of this parameter.
 
- 
getReturns the object value of the given parameter, looking up its default in the ParamDescriptions map.- Parameters:
- name- The name of the parameter.
- Returns:
- The object value of this parameter.
 
- 
getIntReturns the integer value of the given parameter, looking up its default in the ParamDescriptions map.- Parameters:
- name- The name of the parameter.
- defaultValue- a int
- Returns:
- The integer value of this parameter.
 
- 
getLongReturns the long value of the given parameter, looking up its default in the ParamDescriptions map.- Parameters:
- name- The name of the parameter.
- defaultValue- a long
- Returns:
- The long value of this parameter.
 
- 
getBooleanReturns the boolean value of the given parameter, using the given default.- Parameters:
- name- The name of the parameter.
- defaultValue- a boolean
- Returns:
- The boolean value of this parameter.
 
- 
getDoubleReturns the object value of the given parameter, using the given default.- Parameters:
- name- The name of the parameter.
- defaultValue- a double
- Returns:
- The double value of this parameter.
 
- 
getStringReturns the string value of the given parameter, using the given default.- Parameters:
- name- The name of the parameter.
- defaultValue- a- Stringobject
- Returns:
- The string value of this parameter.
 
- 
getReturns the object value of the given parameter, using the given default.- Parameters:
- name- The name of the parameter.
- defaultValue- a- Objectobject
- Returns:
- The object value of this parameter.
 
- 
getValuesReturns the values set for the given parameter. Usually of length 1.- Parameters:
- name- The name of the parameter.
- Returns:
- The array of values.
 
- 
setSets the value(s) of the given parameter to a list of strings.- Parameters:
- name- The name of the parameter.
- n- A list of values for the parameter.
 
- 
setSets the value(s) of the given parameter to a list of values.- Parameters:
- name- The name of the parameter.
- s- A list of strings for the parameter.
 
- 
getNumValuesReturns the number of values for the parameter.- Parameters:
- name- The name of the parameter.
- Returns:
- The number of values set for that parameter.
 
- 
setSets the given parameter to the given value.- Parameters:
- name- The name of the parameter.
- value- The value of the parameter (a single value).
 
- 
setSets the given parameter to the given value.- Parameters:
- name- The name of the parameter.
- value- The value of the parameter (a single value).
 
- 
getParametersNamesgetParametersNames. - Returns:
- a Setobject
 
- 
removeRemoves the specified parameter from the list of parameters.- Parameters:
- parameter- The parameter to remove.
 
 
-