org.makumba.providers.query.mql
Class MqlNode
java.lang.Object
antlr.BaseAST
antlr.CommonAST
org.makumba.providers.query.mql.MqlNode
- All Implemented Interfaces:
- antlr.collections.AST, Serializable
- Direct Known Subclasses:
- MqlBinaryOperator, MqlDotNode, MqlIdentNode
public class MqlNode
- extends antlr.CommonAST
The root of Mql analysis tree nodes. It performs analysis as the tree is built. It should know how to determine its
Makumba type, if it is not a parameter.
- Version:
- $Id: MqlNode.java,v 1.1 Aug 5, 2008 5:38:16 PM cristi Exp $
- Author:
- Cristian Bogdan
- See Also:
- Serialized Form
Fields inherited from class antlr.BaseAST |
down, right |
Methods inherited from class antlr.CommonAST |
getText, getType, initialize, initialize |
Methods inherited from class antlr.BaseAST |
addChild, decode, encode, equals, equalsList, equalsListPartial, equalsTree, equalsTreePartial, findAll, findAllPartial, getColumn, getFirstChild, getLine, getNextSibling, getNumberOfChildren, getTokenNames, removeChildren, setVerboseStringConversion, toStringList, toStringTree, xmlSerialize, xmlSerializeNode, xmlSerializeRootClose, xmlSerializeRootOpen |
walker
MqlSqlWalker walker
checkAsIds
protected ArrayList<String> checkAsIds
MqlNode
public MqlNode()
getWalker
protected MqlSqlWalker getWalker()
setWalker
protected void setWalker(MqlSqlWalker walker)
setFather
public void setFather(MqlNode node)
- we analyze the tree as it is built
getFather
public MqlNode getFather()
setFirstChild
public void setFirstChild(antlr.collections.AST a)
- we analyze the tree as it is built, we call oneMoreChild() to see whether we are ready for analysis
- Specified by:
setFirstChild
in interface antlr.collections.AST
- Overrides:
setFirstChild
in class antlr.BaseAST
setNextSibling
public void setNextSibling(antlr.collections.AST a)
- we analyze the tree as it is built, we call oneMoreChild() of the father to see whether it is ready for analysis
- Specified by:
setNextSibling
in interface antlr.collections.AST
- Overrides:
setNextSibling
in class antlr.BaseAST
oneMoreChild
protected void oneMoreChild(MqlNode child)
findMakType
protected FieldDefinition findMakType(MqlNode child)
setMakType
public void setMakType(FieldDefinition fd)
getMakType
public FieldDefinition getMakType()
setText
public void setText(String text)
- Specified by:
setText
in interface antlr.collections.AST
- Overrides:
setText
in class antlr.CommonAST
setType
public void setType(int type)
- Specified by:
setType
in interface antlr.collections.AST
- Overrides:
setType
in class antlr.CommonAST
initialize
public void initialize(antlr.collections.AST t)
- Specified by:
initialize
in interface antlr.collections.AST
- Overrides:
initialize
in class antlr.CommonAST
knownType
String knownType()
checkForOperandType
protected void checkForOperandType(MqlNode ast)
isParam
boolean isParam()
isFunctionCall
boolean isFunctionCall()
- whether this is a custom MDD function call
checkOperandTypes
void checkOperandTypes(MqlNode left,
MqlNode right)
throws antlr.SemanticException
- Throws:
antlr.SemanticException
getOriginalText
public String getOriginalText()
writeTo
public void writeTo(NameResolver.TextList t)
toString
public String toString()
- Specified by:
toString
in interface antlr.collections.AST
- Overrides:
toString
in class antlr.BaseAST
setTextList
public void setTextList(NameResolver.TextList tl)
checkAndRewriteOperand
protected boolean checkAndRewriteOperand(MqlNode left,
MqlNode right)
throws antlr.SemanticException
- Symmetrically check both sides for operands that need to be rewritten
- Throws:
antlr.SemanticException
checkParam
protected boolean checkParam(MqlNode left,
MqlNode right)
makeBooleanFieldDefinition
protected FieldDefinition makeBooleanFieldDefinition()