public class DimensionVisitor extends java.lang.Object implements ParserVisitor, JepComponent
Warning messages are sometimes generated. This list can
Modifier and Type | Field and Description |
---|---|
static Node.HookKey |
DIM_KEY
A Key to use with Nodes and Variables to store the dimensions.
|
Constructor and Description |
---|
DimensionVisitor()
Should only be used as when the
init(Jep) will be called. |
DimensionVisitor(Jep jep1) |
Modifier and Type | Method and Description |
---|---|
static Dimensions |
getDimByValue(java.lang.Object val) |
JepComponent |
getLightWeightInstance()
Gets a light-weight instance suitable for using in multiple threads.
|
java.util.List<java.lang.String> |
getWarnings()
The list of warnings when a variable has changed dimension.
|
void |
init(Jep jep1)
Initialize the component.
|
Dimensions |
visit(ASTConstant node,
java.lang.Object data) |
Dimensions |
visit(ASTFunNode node,
java.lang.Object data) |
Dimensions |
visit(ASTOpNode node,
java.lang.Object data) |
Dimensions |
visit(ASTVarNode node,
java.lang.Object data) |
Dimensions |
visit(Node node)
Annotate every node in the tree.
|
protected Dimensions |
visitAssign(ASTOpNode node,
java.lang.Object data) |
public static final Node.HookKey DIM_KEY
public DimensionVisitor()
init(Jep)
will be called.public DimensionVisitor(Jep jep1)
public static final Dimensions getDimByValue(java.lang.Object val)
public Dimensions visit(Node node) throws ParseException
node
- root node of the expressionParseException
public Dimensions visit(ASTConstant node, java.lang.Object data) throws ParseException
visit
in interface ParserVisitor
ParseException
public Dimensions visit(ASTVarNode node, java.lang.Object data) throws ParseException
visit
in interface ParserVisitor
ParseException
protected Dimensions visitAssign(ASTOpNode node, java.lang.Object data) throws ParseException
ParseException
public Dimensions visit(ASTFunNode node, java.lang.Object data) throws ParseException
visit
in interface ParserVisitor
ParseException
public Dimensions visit(ASTOpNode node, java.lang.Object data) throws ParseException
visit
in interface ParserVisitor
ParseException
public java.util.List<java.lang.String> getWarnings()
public void init(Jep jep1)
JepComponent
init
in interface JepComponent
jep1
- the current Jep instancepublic JepComponent getLightWeightInstance()
JepComponent
getLightWeightInstance
in interface JepComponent
Copyright © 2018 Singular Systems http://www.singularsys.com/jep