Extension SDK 10.1.2


oracle.jdeveloper.jot
Interface JotQuestionExpression

All Superinterfaces:
JotCodeElement, JotElement, JotExpression

public interface JotQuestionExpression
extends JotExpression

The JotQuestionExpression interface represents the conditional operator (? :). It has the form

   x < 10 ? "Foo" : "Bar"
 
Since:
5.0
See Also:
"Section 15.25 of the Java Language Specification Second Edition"

Field Summary

Fields inherited from interface oracle.jdeveloper.jot.JotExpression
ANONYMOUS_CLASS_ALLOCATION_EXPRESSION, ARRAY_ALLOCATION_EXPRESSION, ARRAY_DEREFERENCE_EXPRESSION, ARRAY_INITIALIZER_EXPRESSION, ASSIGNMENT_EXPRESSION, CLASS_ALLOCATION_EXPRESSION, INFIX_EXPRESSION, METHOD_CALL_EXPRESSION, NESTED_EXPRESSION, POST_INC_OR_DEC_EXPRESSION, PRE_INC_OR_DEC_EXPRESSION, PRIMARY_EXPRESSION, QUESTION_EXPRESSION, TYPECAST_EXPRESSION, UNARY_EXPRESSION, UNCATEGORIZED_EXPRESSION

Method Summary
JotExpression getCondition()
Retrieves the conditional sub-expression.
JotExpression getWhenFalseExpression()
Retrieves the expression evaluated when the condition is false.
JotExpression getWhenTrueExpression()
Retrieves the expression evaluated when the condition is true.
void setCondition(java.lang.String exp)
Sets the conditional sub-expression.
void setWhenFalseExpression(java.lang.String exp)
Sets the false sub-expression.
void setWhenTrueExpression(java.lang.String exp)
Sets the true sub-expression.

Methods inherited from interface oracle.jdeveloper.jot.JotExpression
getAsAnonymousClass, getAsArrayAllocation, getAsArrayDereference, getAsArrayInitializer, getAsAssignment, getAsClassAllocation, getAsInfixExpression, getAsMethodCall, getAsNestedExpression, getAsPostIncrementOrDecrement, getAsPreIncrementOrDecrement, getAsPrimaryExpression, getAsQuestionExpression, getAsTypecast, getAsUnaryExpression, getExpressionString, getExpressionType, getMinimumReferenceName, isParenthesized, renameObjectReference, resolveTypeReference, setParenthesized

Methods inherited from interface oracle.jdeveloper.jot.JotCodeElement
addPrecedingComment, childrenContainErrors, delete, getContainingJotFile, getLeftWhitespace, getLength, getRightWhitespace, isInError, isSource, setLeftWhitespace, setRightWhitespace

Methods inherited from interface oracle.jdeveloper.jot.JotElement
getChildren, getContainedElements, getElementName, getElementType, getEndOffset, getID, getJotWorkArea, getParent, getStartOffset, isExistent, isReadOnly, isStructureKnown, setParent

Method Detail

getCondition

public JotExpression getCondition()
                           throws JotInvalidElementException
Retrieves the conditional sub-expression.
Throws:
JotInvalidElementException

setCondition

public void setCondition(java.lang.String exp)
                  throws JotInvalidElementException
Sets the conditional sub-expression. The existing sub-expression is removed.
Parameters:
exp - the new expression string.
Throws:
JotInvalidElementException

getWhenTrueExpression

public JotExpression getWhenTrueExpression()
                                    throws JotInvalidElementException
Retrieves the expression evaluated when the condition is true.
Throws:
JotInvalidElementException

setWhenTrueExpression

public void setWhenTrueExpression(java.lang.String exp)
                           throws JotInvalidElementException
Sets the true sub-expression. The existing true sub-expression is removed.
Parameters:
exp - the new expression string.
Throws:
JotInvalidElementException

getWhenFalseExpression

public JotExpression getWhenFalseExpression()
                                     throws JotInvalidElementException
Retrieves the expression evaluated when the condition is false.
Throws:
JotInvalidElementException

setWhenFalseExpression

public void setWhenFalseExpression(java.lang.String exp)
                            throws JotInvalidElementException
Sets the false sub-expression. The existing true sub-expression is removed.
Parameters:
exp - the new expression string.
Throws:
JotInvalidElementException

Extension SDK


Copyright © 1997, 2004, Oracle. All rights reserved.