- 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 theswitchstatement.ExpressionTreegetExpression()Returns the expression for theswitchstatement.
-
Method Details
-
getExpression
ExpressionTree getExpression()Returns the expression for theswitchstatement.- Returns:
- the expression
-
getCases
Returns the cases for theswitchstatement.- Returns:
- the cases
-