public class Conditional extends Operator
Constructor and Description |
---|
Conditional(ExtList children)
Conditional.
|
Modifier and Type | Method and Description |
---|---|
int |
getArity()
Get arity.
|
KeYJavaType |
getKeYJavaType(Services javaServ,
ExecutionContext ec)
returns the
KeYJavaType of an expression |
int |
getNotation()
Get notation.
|
int |
getPrecedence()
Get precedence.
|
boolean |
isLeftAssociative()
Checks if this operator is left or right associative.
|
void |
prettyPrint(PrettyPrinter p)
Pretty printing the source element.
|
void |
visit(Visitor v)
calls the corresponding method of a visitor in order to
perform some action/transformation on this element
|
getArguments, getChildAt, getChildCount, getExpressionAt, getExpressionCount, getFirstElement, getFirstElementIncludingBlocks, getLastElement, isToBeParenthesized, precedes, reuseSignature
compatibleBlockSize, computeHashCode, equals, equalsModRenaming, getArrayPos, match, matchChildren
getComments, hashCode, prettyPrintMain
getEndPosition, getParentClass, getPositionInfo, getRelativePosition, getStartPosition, setParentClass, toSource, toString, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getComments, match
equalsModRenaming, getEndPosition, getPositionInfo, getRelativePosition, getStartPosition
public Conditional(ExtList children)
children
- list of children the first one is the guard expression,
the second one the then expression and the last one the else expr.public int getArity()
public int getPrecedence()
getPrecedence
in class Operator
public int getNotation()
getNotation
in class Operator
public boolean isLeftAssociative()
isLeftAssociative
in class Operator
true
, if the operator is left associative,
false
otherwise.public void visit(Visitor v)
v
- the Visitorpublic void prettyPrint(PrettyPrinter p) throws java.io.IOException
JavaSourceElement
prettyPrint
in interface SourceElement
prettyPrint
in class JavaProgramElement
p
- a pretty printer.java.io.IOException
- occasionally thrown.public KeYJavaType getKeYJavaType(Services javaServ, ExecutionContext ec)
Expression
KeYJavaType
of an expressiongetKeYJavaType
in interface Expression
getKeYJavaType
in class Operator