Class Expression
java.lang.Object
com.aquima.interactions.rule.parser.Expression
- All Implemented Interfaces:
IExpression
,Serializable
- Direct Known Subclasses:
Condition
This class holds a single expression.
- Since:
- 5.0
- Author:
- O. Kerpershoek
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
evaluateWith
(InferenceContext context) This method will evaluate the expression and return the result as a value object.This method will return the expected output data type of the expression.This method return the original (unparsed) expression.protected IExpr
String[]
Returns a list of the entity names which could be used as root scope during expression evaluation.int
hashCode()
boolean
Returns whether the output of the expression is a list.toString()
-
Constructor Details
-
Method Details
-
getExpressionObj
-
getExpression
Description copied from interface:IExpression
This method return the original (unparsed) expression.- Specified by:
getExpression
in interfaceIExpression
- Returns:
- String containing the original expression.
-
getScopeObjects
Description copied from interface:IExpression
Returns a list of the entity names which could be used as root scope during expression evaluation. This does not necessarily mean these scope objects will be used. All returned scope objects are lowercase, since the expression evaluator is case-insensitive it sees them as lowercase.- Specified by:
getScopeObjects
in interfaceIExpression
- Returns:
- Never null
-
getResultTypeName
-
evaluateWith
Description copied from interface:IExpression
This method will evaluate the expression and return the result as a value object.- Specified by:
evaluateWith
in interfaceIExpression
- Parameters:
context
- object containing the objects that are visible for the expression.- Returns:
- Value object with the result of the expression.
-
getDataType
Description copied from interface:IExpression
This method will return the expected output data type of the expression. Never null but in some cases it can be DataType.ANY if it is unknown.- Specified by:
getDataType
in interfaceIExpression
- Returns:
- DataType
-
isMultivalue
public boolean isMultivalue()Description copied from interface:IExpression
Returns whether the output of the expression is a list.- Specified by:
isMultivalue
in interfaceIExpression
- Returns:
- boolean
-
toString
-
hashCode
public int hashCode() -
equals
-