public class Value
extends java.lang.Object
Constructor and Description |
---|
Value(ValueType type,
java.lang.Object value)
The constructor
|
Modifier and Type | Method and Description |
---|---|
Value |
addition(Value value)
Used to add this value to another value
|
Value |
and(Value value)
Used to 'and' the parameter value from with value
|
Value |
divide(Value value)
Used to divide this value with another value
|
Value |
equals(Value value)
Used to perform a
== operation between this value and the value in the
parameter |
ValueType |
getType()
Used to get the type of the value
|
java.lang.Object |
getValue()
Used to get the raw value
|
Value |
greater(Value value)
Used to perform a
> operation between this value and the value in the
parameter |
Value |
greaterEquals(Value value)
Used to perform a
>= operation between this value and the value in the
parameter |
Value |
less(Value value)
Used to perform a
< operation between this value and the value in the
parameter |
Value |
lessEquals(Value value)
Used to perform a
<= operation between this value and the value in the
parameter |
Value |
multiply(Value value)
Used to multiply this value with another value
|
Value |
not()
Used to perform a not operation on this value and return the result
|
Value |
notequals(Value value)
Used to perform a
!= operation between this value and the value in the
parameter |
Value |
or(Value value)
Used to 'or' the parameter value from with value
|
void |
setType(ValueType type)
Used to set the type of the value
|
void |
setValue(java.lang.Object value)
Used to set the raw value
|
Value |
subtract(Value value)
Used to subtract the parameter value from this value
|
public Value(ValueType type, java.lang.Object value)
type
- The type of valuevalue
- The raw valuepublic java.lang.Object getValue()
public void setValue(java.lang.Object value)
value
- The raw valuepublic ValueType getType()
public void setType(ValueType type)
type
- The type of the valuepublic Value addition(Value value) throws ExpressionParserException
value
- The value to add this value toExpressionParserException
- Thrown if their is a problem performing the operation.public Value divide(Value value) throws ExpressionParserException
value
- The value to divide this value byExpressionParserException
- Thrown if their is a problem performing the operation.public Value multiply(Value value) throws ExpressionParserException
value
- The value to multiply this value byExpressionParserException
- Thrown if their is a problem performing the operation.public Value subtract(Value value) throws ExpressionParserException
value
- The value to subtractExpressionParserException
- Thrown if not supported by this valuepublic Value not()
ExpressionParserException
- Thrown if not supported by this valuepublic Value and(Value value)
value
- The value to 'and' withExpressionParserException
- Thrown if not supported by this valuepublic Value or(Value value)
value
- The value to 'or' withExpressionParserException
- Thrown if not supported by this valuepublic Value notequals(Value value)
!=
operation between this value and the value in the
parametervalue
- The value to perform the operation withExpressionParserException
- Thrown if not supported by this valuepublic Value equals(Value value)
==
operation between this value and the value in the
parametervalue
- The value to perform the operation withExpressionParserException
- Thrown if not supported by this valuepublic Value greater(Value value)
>
operation between this value and the value in the
parametervalue
- The value to perform the operation withExpressionParserException
- Thrown if not supported by this valuepublic Value greaterEquals(Value value)
>=
operation between this value and the value in the
parametervalue
- The value to perform the operation withExpressionParserException
- Thrown if not supported by this valuepublic Value less(Value value)
<
operation between this value and the value in the
parametervalue
- The value to perform the operation withExpressionParserException
- Thrown if not supported by this valuepublic Value lessEquals(Value value)
<=
operation between this value and the value in the
parametervalue
- The value to perform the operation withExpressionParserException
- Thrown if not supported by this value