Package nl.gx.forms.wmpformapi.api.base
Class SimpleParameter
- java.lang.Object
-
- nl.gx.forms.wmpformapi.api.base.SimpleParameter
-
- All Implemented Interfaces:
BasicParameter
public class SimpleParameter extends Object implements BasicParameter
Simple base class for the Parameter
-
-
Constructor Summary
Constructors Constructor Description SimpleParameter(ParameterDefinition parameterDefinition, String value, ParameterMode mode)
Constructor for the SimpleParameter.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description String
getExpression()
Returns the JavaScript expression that returns the value for this Parameter.FormStep
getFormStep()
Returns the FormStep for this Parameter.String
getFragment()
Returns the fragment identifier or value for this Parameter.LanguageLabel
getLanguageLabel()
Returns the language label for this Parameter.boolean
getOverridden()
Deprecated.use getParameterMode insteadParameterDefinition
getParameterDefinition()
Returns the ParameterDefinition for this Parameter.ParameterMode
getParameterMode()
Returns the mode for this Parameter.String
getTextValue()
Returns the text value for this Parameter.String
getValue()
Returns the value for this Parameter.void
setTextValue(String myTextValue)
-
-
-
Constructor Detail
-
SimpleParameter
public SimpleParameter(ParameterDefinition parameterDefinition, String value, ParameterMode mode)
Constructor for the SimpleParameter.- Parameters:
parameterDefinition
- the definition describing this parametervalue
- the value assigned to itmode
- the mode in which to evaluate the value- See Also:
ParameterMode
-
-
Method Detail
-
getFormStep
public FormStep getFormStep()
Returns the FormStep for this Parameter. This property is used for parameters of typeFormStep
.- Specified by:
getFormStep
in interfaceBasicParameter
- Returns:
- the form step for this Parameter
-
getLanguageLabel
public LanguageLabel getLanguageLabel()
Returns the language label for this Parameter. This property is used for parameters of type Language Label.- Specified by:
getLanguageLabel
in interfaceBasicParameter
- Returns:
- the language label for this parameter
-
getOverridden
public boolean getOverridden()
Deprecated.use getParameterMode insteadReturns whether the mode in which to evaluate this parameter is overridden. This is no longer in use since the mode is determined by theParameterMode
property.- Returns:
- whether the mode in which to evaluate this parameter is overridden
-
getParameterDefinition
public ParameterDefinition getParameterDefinition()
Returns the ParameterDefinition for this Parameter.- Specified by:
getParameterDefinition
in interfaceBasicParameter
- Returns:
- the ParameterDefinition which describes this parameter.
-
getValue
public String getValue()
Returns the value for this Parameter. This property is used for parameters of type String, Textarea, Page, FormFragment and for when the parameter type has been overridden; in the latter case, the value is a JavaScript expression.- Specified by:
getValue
in interfaceBasicParameter
- Returns:
- value for this Parameter
- See Also:
ParameterMode#getType()
-
getExpression
public String getExpression()
Returns the JavaScript expression that returns the value for this Parameter.- Specified by:
getExpression
in interfaceBasicParameter
- Returns:
- the JavaScript expression that returns the value for this Parameter
-
getFragment
public String getFragment()
Returns the fragment identifier or value for this Parameter. When the parameter is of type FormFragment identifier, the identifier relative to the FormVersion is stored (e.g. formstepidentifier.formfragmentidentifier). This method is only valid if this parameter is of type fragment.- Specified by:
getFragment
in interfaceBasicParameter
- Returns:
- the fragment value for this parameter
-
getParameterMode
public ParameterMode getParameterMode()
Returns the mode for this Parameter.- Specified by:
getParameterMode
in interfaceBasicParameter
- Returns:
- the mode for this Parameter
- See Also:
ParameterMode
-
setTextValue
public void setTextValue(String myTextValue)
-
getTextValue
public String getTextValue()
Returns the text value for this Parameter. This property is used for parameters of type Text. It returns the text value in a language context.- Specified by:
getTextValue
in interfaceBasicParameter
- Returns:
- value for this Parameter
- See Also:
ParameterMode#getType()
-
-