Package mondrian.olap
Class ParameterImpl
java.lang.Object
mondrian.olap.ParameterImpl
- All Implemented Interfaces:
ParameterCompilable
,Parameter
Implementation of
Parameter
.- Since:
- Jul 22, 2006
- Author:
- jhyde
-
Nested Class Summary
Nested classes/interfaces inherited from interface mondrian.olap.Parameter
Parameter.Scope
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncompile
(ExpCompiler compiler) protected Object
static Object
convertBack
(Object value) boolean
Returns whether this parameter is equal to another, based upon name, type and valueObject[]
Returns the expression which provides the default value for this Parameter.Returns the description of this Parameter.getName()
Returns the name of this Parameter.getScope()
Returns the scope where this parameter is defined.getType()
Returns the type of this Parameter.getValue()
Returns the value of this parameter.int
hashCode()
boolean
Returns whether the parameter can be modified.boolean
isSet()
Returns whether the value of this parameter has been set.void
setDefaultExp
(Exp defaultExp) void
setDescription
(String description) void
void
Sets the value of this parameter.void
Unsets the value of this parameter.
-
Constructor Details
-
ParameterImpl
-
-
Method Details
-
getScope
Description copied from interface:Parameter
Returns the scope where this parameter is defined. -
getType
Description copied from interface:Parameter
Returns the type of this Parameter. -
getDefaultExp
Description copied from interface:Parameter
Returns the expression which provides the default value for this Parameter. Never null.- Specified by:
getDefaultExp
in interfaceParameter
- Returns:
- Default value expression of the parameter
-
getName
Description copied from interface:Parameter
Returns the name of this Parameter. -
getValue
Description copied from interface:Parameter
Returns the value of this parameter.If
Parameter.setValue(Object)
has not been called, returns the default value of this parameter.The type of the value is (depending on the type of the parameter) a
String
,Number
, orMember
. -
setValue
Description copied from interface:Parameter
Sets the value of this parameter. -
isSet
public boolean isSet()Description copied from interface:Parameter
Returns whether the value of this parameter has been set.If the value has not been set, this parameter will return its default value.
Setting a parameter to
null
is not equivalent to unsetting it. To unset a parameter, callParameter.unsetValue()
. -
unsetValue
public void unsetValue()Description copied from interface:Parameter
Unsets the value of this parameter.After calling this method, the parameter will revert to its default value, as if
Parameter.setValue(Object)
had not been called, andParameter.isSet()
will returnfalse
.- Specified by:
unsetValue
in interfaceParameter
-
getDescription
Description copied from interface:Parameter
Returns the description of this Parameter.- Specified by:
getDescription
in interfaceParameter
- Returns:
- Description of the parameter
-
getChildren
-
equals
Returns whether this parameter is equal to another, based upon name, type and value -
hashCode
public int hashCode() -
isModifiable
public boolean isModifiable()Returns whether the parameter can be modified.- Specified by:
isModifiable
in interfaceParameter
- Returns:
- Whether parameter is modifiable
-
setDescription
-
setType
-
setDefaultExp
-
compile
- Specified by:
compile
in interfaceParameterCompilable
-
convert
-
convertBack
-