Class ParameterString
- java.lang.Object
-
- gov.nih.mipav.model.scripting.parameters.Parameter
-
- gov.nih.mipav.model.scripting.parameters.ParameterString
-
- Direct Known Subclasses:
ParameterFile
,ParameterImage
public class ParameterString extends Parameter
A string parameter used in either the recording or execution of a script action.
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
value
The parameter's value.-
Fields inherited from class gov.nih.mipav.model.scripting.parameters.Parameter
PARAM_BOOLEAN, PARAM_DOUBLE, PARAM_EXTERNAL_IMAGE, PARAM_FILE, PARAM_FLOAT, PARAM_IMAGE, PARAM_INT, PARAM_LIST, PARAM_LONG, PARAM_SHORT, PARAM_STRING, PARAM_USHORT
-
-
Constructor Summary
Constructors Constructor Description ParameterString(java.lang.String paramLabel)
Creates a new ParameterString object without any value.ParameterString(java.lang.String paramLabel, int paramType)
Creates a new ParameterString object without any value.ParameterString(java.lang.String paramLabel, int paramType, java.lang.String paramValue)
Creates a new ParameterString object.ParameterString(java.lang.String paramLabel, java.lang.String paramValue)
Creates a new ParameterString with a new value.ParameterString(java.lang.String paramLabel, java.lang.String paramTypeString, java.lang.String paramValue)
Creates a new ParameterString object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getValue()
Returns the parameter value.java.lang.String
getValueString()
Returns the parameter value as a string.void
setValue(java.lang.String paramValueString)
Changes the parameter's current value.-
Methods inherited from class gov.nih.mipav.model.scripting.parameters.Parameter
convertToString, getLabel, getParent, getParentConditionValueString, getType, getTypeFromString, getTypeString, getTypeString, isOptional, isParentConditionValueMet, isValueAssigned, setOptional, setParent, setParentCondition, setParentConditionValue, setValueAssigned
-
-
-
-
Constructor Detail
-
ParameterString
public ParameterString(java.lang.String paramLabel) throws ParserException
Creates a new ParameterString object without any value.- Parameters:
paramLabel
- The label/name to give to this parameter.- Throws:
ParserException
- If there is a problem creating the parameter.
-
ParameterString
public ParameterString(java.lang.String paramLabel, java.lang.String paramValue) throws ParserException
Creates a new ParameterString with a new value.- Parameters:
paramLabel
- The label/name to give to this parameter.paramValue
- The new parameter value.- Throws:
ParserException
- If there is a problem creating the parameter.
-
ParameterString
public ParameterString(java.lang.String paramLabel, int paramType) throws ParserException
Creates a new ParameterString object without any value.- Parameters:
paramLabel
- The label/name to give to this parameter.paramType
- The type of this parameter (should be PARAM_STRING).- Throws:
ParserException
- If there is a problem creating the parameter.
-
ParameterString
public ParameterString(java.lang.String paramLabel, java.lang.String paramTypeString, java.lang.String paramValue) throws ParserException
Creates a new ParameterString object.- Parameters:
paramLabel
- The label/name to give to this parameter.paramTypeString
- The type of this parameter, in string form.paramValue
- The new parameter value.- Throws:
ParserException
- If there is a problem creating the parameter.
-
ParameterString
public ParameterString(java.lang.String paramLabel, int paramType, java.lang.String paramValue) throws ParserException
Creates a new ParameterString object.- Parameters:
paramLabel
- The label/name to give to this parameter.paramType
- The type of this parameter (should be PARAM_STRING).paramValue
- The new parameter value.- Throws:
ParserException
- If there is a problem creating the parameter.
-
-
Method Detail
-
getValue
public java.lang.String getValue()
Returns the parameter value.- Returns:
- The parameter value.
-
getValueString
public java.lang.String getValueString()
Returns the parameter value as a string.- Specified by:
getValueString
in classParameter
- Returns:
- The parameter value in string form.
-
setValue
public void setValue(java.lang.String paramValueString) throws ParserException
Changes the parameter's current value.- Specified by:
setValue
in classParameter
- Parameters:
paramValueString
- The new parameter value.- Throws:
ParserException
- If there is a problem changing the parameter value.
-
-