Class AST.SimpleExpression
java.lang.Object
nz.org.riskscape.defaults.classifier.AST
nz.org.riskscape.defaults.classifier.AST.SimpleExpression
- All Implemented Interfaces:
AST.ExpressionDecl
- Enclosing class:
- AST
-
Nested Class Summary
Nested classes/interfaces inherited from class nz.org.riskscape.defaults.classifier.AST
AST.ExpressionDecl, AST.Filter, AST.FunctionDecl, AST.Metadata, AST.SimpleExpression, AST.SimpleType, AST.StructExpression, AST.StructType -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionSimpleExpression(nz.org.riskscape.dsl.Token identifier, List<nz.org.riskscape.dsl.Token> expressionParts) SimpleExpression(nz.org.riskscape.dsl.Token identifier, List<nz.org.riskscape.dsl.Token> expressionParts, String expression) Creates a newSimpleExpressioninstance.SimpleExpression(nz.org.riskscape.dsl.Token identifier, nz.org.riskscape.dsl.Token exprToken) -
Method Summary
Modifier and TypeMethodDescriptionvoidprotected booleanstatic AST.SimpleExpressionTesting constructorbooleannz.org.riskscape.dsl.TokenThe raw string of the expression.List<nz.org.riskscape.dsl.Token>List ofTokens that make up the expression.nz.org.riskscape.dsl.TokeninthashCode()toString()
-
Field Details
-
identifier
public final nz.org.riskscape.dsl.Token identifier -
expressionParts
List of
Tokens that make up the expression. -
expression
The raw string of the expression. This is formed by concatenating the raw value from each
Tokenfrom expressionParts. -
built
public nz.org.riskscape.rl.ast.Expression built
-
-
Constructor Details
-
SimpleExpression
public SimpleExpression(nz.org.riskscape.dsl.Token identifier, nz.org.riskscape.dsl.Token exprToken) -
SimpleExpression
public SimpleExpression(nz.org.riskscape.dsl.Token identifier, List<nz.org.riskscape.dsl.Token> expressionParts) -
SimpleExpression
public SimpleExpression(nz.org.riskscape.dsl.Token identifier, List<nz.org.riskscape.dsl.Token> expressionParts, String expression) Creates a new
SimpleExpressioninstance.- Parameters:
identifier-expressionParts- List ofTokens that make up the expression.expression- The raw string of the expression. This is formed by concatenating the raw value from eachTokenfrom expressionParts.
-
-
Method Details
-
create
Testing constructor
-
build
public void build(List<nz.org.riskscape.problem.Problem> problems, nz.org.riskscape.rl.ExpressionParser parser) - Specified by:
buildin interfaceAST.ExpressionDecl
-
scanStructKeys
- Specified by:
scanStructKeysin interfaceAST.ExpressionDecl
-
getBoundaryToken
public nz.org.riskscape.dsl.Token getBoundaryToken()- Specified by:
getBoundaryTokenin classAST
-
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-
getIdentifier
public nz.org.riskscape.dsl.Token getIdentifier()- Specified by:
getIdentifierin interfaceAST.ExpressionDecl- Overrides:
getIdentifierin classAST
-
getExpressionParts
List of
Tokens that make up the expression. -
getExpression
The raw string of the expression. This is formed by concatenating the raw value from each
Tokenfrom expressionParts.
-