pl.edu.pjwstk.yaod.yaql.abstractsyntaxtree.expressions.ternary
Class ConditionExpression

java.lang.Object
  |
  +--pl.edu.pjwstk.yaod.yaql.abstractsyntaxtree.AbstractSyntaxTree
        |
        +--pl.edu.pjwstk.yaod.yaql.abstractsyntaxtree.Expression
              |
              +--pl.edu.pjwstk.yaod.yaql.abstractsyntaxtree.expressions.TernaryExpression
                    |
                    +--pl.edu.pjwstk.yaod.yaql.abstractsyntaxtree.expressions.ternary.ConditionExpression
All Implemented Interfaces:
java.io.Serializable

public class ConditionExpression
extends TernaryExpression

The ConditionExpression class represents the ternary condition expression nodes in the abstract syntax tree.

Author:
Jakub Trzetrzelewski, jakub_trzetrzelewski@yahoo.com
See Also:
Serialized Form

Field Summary
 OperatorTerminal lo
           
 OperatorTerminal ro
           
 
Fields inherited from class pl.edu.pjwstk.yaod.yaql.abstractsyntaxtree.expressions.TernaryExpression
l, m, r
 
Constructor Summary
ConditionExpression(Expression l, Expression m, Expression r, OperatorTerminal lo, OperatorTerminal ro)
          Creates a new ternary expression node with the given expressions l, m and r and terminals lo and ro.
 
Method Summary
 java.lang.String getSpellingAndPosition()
          Returns the spelling and positions of all terminals in a node.
 java.lang.String getTypeAsString()
          Returns the abstract syntax tree node type as a string value.
 
Methods inherited from class pl.edu.pjwstk.yaod.yaql.abstractsyntaxtree.expressions.TernaryExpression
accept, show
 
Methods inherited from class pl.edu.pjwstk.yaod.yaql.abstractsyntaxtree.AbstractSyntaxTree
getLongestTypeAsSpacesString, getPreparedTypeAsString, show
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

lo

public OperatorTerminal lo

ro

public OperatorTerminal ro
Constructor Detail

ConditionExpression

public ConditionExpression(Expression l,
                           Expression m,
                           Expression r,
                           OperatorTerminal lo,
                           OperatorTerminal ro)
Creates a new ternary expression node with the given expressions l, m and r and terminals lo and ro.
Parameters:
l - any expression.
m - any expression.
r - any expression.
lo - operator terminal.
ro - operator terminal.
Method Detail

getTypeAsString

public java.lang.String getTypeAsString()
Returns the abstract syntax tree node type as a string value.
Overrides:
getTypeAsString in class AbstractSyntaxTree
Returns:
the abstract syntax tree node type as string.

getSpellingAndPosition

public java.lang.String getSpellingAndPosition()
Returns the spelling and positions of all terminals in a node.
Overrides:
getSpellingAndPosition in class AbstractSyntaxTree
Returns:
the spelling and positions of all terminals in a node.