- All Superinterfaces:
StatementTree
,Tree
public interface SwitchTree extends StatementTree
A tree node for a
switch
statement.
For example:
switch ( expression ) { cases }
- See Java Language Specification:
-
14.11 The switch Statement
- Since:
- 1.6
-
Nested Class Summary
-
Method Summary
Modifier and Type Method Description List<? extends CaseTree>
getCases()
Returns the cases for theswitch
statement.ExpressionTree
getExpression()
Returns the expression for theswitch
statement.
-
Method Details
-
getExpression
ExpressionTree getExpression()Returns the expression for theswitch
statement.- Returns:
- the expression
-
getCases
Returns the cases for theswitch
statement.- Returns:
- the cases
-