public interface Expression extends Serializable
Expressions are organized into a tree-like structure with nodes representing sub-expressions.
Certain types of nodes have certain requirements towards the number or types of nodes that are expected as sub-expressions to an expression.
Modifier and Type | Method and Description |
---|---|
List<Expression> |
getChildren()
Returns the list of sub-expressions (child expressions) to the current expression node.
|
ExpressionPrecedenceEnum |
getPrecedence()
Returns precedence.
|
String |
getTreeObjectName()
Returns the tree of object name, for use by tools to assign an identifier to an expression.
|
void |
setChildren(List<Expression> children)
Sets the list of sub-expressions (child expressions) to the current expression node.
|
void |
setTreeObjectName(String objectName)
Sets the tree of object name, for use by tools to assign an identifier to an expression.
|
void |
toEPL(StringWriter writer,
ExpressionPrecedenceEnum parentPrecedence)
Write expression considering precedence.
|
List<Expression> getChildren()
void setChildren(List<Expression> children)
children
- child expressions or empty list if there are no child expressionsString getTreeObjectName()
void setTreeObjectName(String objectName)
objectName
- tree object idExpressionPrecedenceEnum getPrecedence()
void toEPL(StringWriter writer, ExpressionPrecedenceEnum parentPrecedence)
writer
- to useparentPrecedence
- precedence