org.teatrove.tea.parsetree
Class TernaryExpression

java.lang.Object
  extended by org.teatrove.tea.parsetree.Node
      extended by org.teatrove.tea.parsetree.Expression
          extended by org.teatrove.tea.parsetree.TernaryExpression
All Implemented Interfaces:
Serializable, Cloneable

public class TernaryExpression
extends Expression

Author:
Nick Hagan
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class org.teatrove.tea.parsetree.Expression
Expression.Conversion
 
Constructor Summary
TernaryExpression(SourceInfo info, Expression condition, Expression thenPart, Expression elsePart)
           
 
Method Summary
 Object accept(NodeVisitor visitor)
          Every subclass of Node must override this method with the following: return visitor.visit(this).
 Object clone()
          Returns a clone of this Node and all its children.
 Expression getCondition()
           
 Expression getElsePart()
           
 Expression getThenPart()
           
 void setCondition(Expression condition)
           
 void setElsePart(Expression elsePart)
           
 void setThenPart(Expression thenPart)
           
 
Methods inherited from class org.teatrove.tea.parsetree.Expression
convertTo, convertTo, forceConversion, getConversionChain, getInitialType, getType, getValue, isExceptionPossible, isValueKnown, setInitialType, setType
 
Methods inherited from class org.teatrove.tea.parsetree.Node
getSourceInfo, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TernaryExpression

public TernaryExpression(SourceInfo info,
                         Expression condition,
                         Expression thenPart,
                         Expression elsePart)
Method Detail

accept

public Object accept(NodeVisitor visitor)
Description copied from class: Node
Every subclass of Node must override this method with the following: return visitor.visit(this).

Overrides:
accept in class Expression
Parameters:
visitor - A visitor of this Node
Returns:
Node The Node returned by the visitor
See Also:
NodeVisitor

clone

public Object clone()
Description copied from class: Node
Returns a clone of this Node and all its children. Immutable child objects are not necessarily cloned

Overrides:
clone in class Expression

getCondition

public Expression getCondition()

setCondition

public void setCondition(Expression condition)

getThenPart

public Expression getThenPart()

setThenPart

public void setThenPart(Expression thenPart)

getElsePart

public Expression getElsePart()

setElsePart

public void setElsePart(Expression elsePart)


Copyright © 1997-2012 TeaTrove.org. All Rights Reserved.