Class CelAstNode
java.lang.Object
org.impulsegraph.compiler.cel.CelAstNode
Abstract Syntax Tree (AST) node for Google Common Expression Language (CEL).
Optionally annotated with
AlgebraicSignature containing domain bounds
and algebraic properties.-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionCelAstNode(CelAstNode.Kind kind, String text, long intVal, double floatVal, boolean boolVal, String strVal, List<CelAstNode> children) CelAstNode(CelAstNode.Kind kind, String text, long intVal, double floatVal, boolean boolVal, String strVal, List<CelAstNode> children, AlgebraicSignature signature) -
Method Summary
Modifier and TypeMethodDescriptionbooleanboolVal()children()booleandoublefloatVal()inthashCode()longintVal()kind()static CelAstNodemakeBinary(String op, CelAstNode lhs, CelAstNode rhs) static CelAstNodemakeBool(boolean val) static CelAstNodemakeCall(String func, List<CelAstNode> args) static CelAstNodemakeFloat(double val) static CelAstNodestatic CelAstNodemakeInt(long val) static CelAstNodemakeList(List<CelAstNode> elements) static CelAstNodemakeMember(CelAstNode target, String field) static CelAstNodestatic CelAstNodemakeString(String val) static CelAstNodemakeTernary(CelAstNode cond, CelAstNode thenBranch, CelAstNode elseBranch) static CelAstNodemakeUnary(String op, CelAstNode operand) strVal()text()toString()withChildren(List<CelAstNode> newChildren) withSignature(AlgebraicSignature newSig)
-
Constructor Details
-
CelAstNode
public CelAstNode(CelAstNode.Kind kind, String text, long intVal, double floatVal, boolean boolVal, String strVal, List<CelAstNode> children) -
CelAstNode
public CelAstNode(CelAstNode.Kind kind, String text, long intVal, double floatVal, boolean boolVal, String strVal, List<CelAstNode> children, AlgebraicSignature signature)
-
-
Method Details
-
kind
-
text
-
intVal
public long intVal() -
floatVal
public double floatVal() -
boolVal
public boolean boolVal() -
strVal
-
children
-
signature
-
makeInt
-
makeFloat
-
makeBool
-
makeString
-
makeIdent
-
makeParam
-
makeMember
-
makeUnary
-
makeBinary
-
makeTernary
-
makeCall
-
makeList
-
withChildren
-
withSignature
-
equals
-
hashCode
-
toString
-