Package org.jboss.jdeparser
Interface JSwitch
-
- All Superinterfaces:
JCommentable
,JStatement
public interface JSwitch extends JStatement
Aswitch
statement.- Author:
- David M. Lloyd
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description JBlock
_case(java.lang.String constName)
Add a switch case for anenum
constant.JBlock
_case(JExpr expr)
Add a switch case.JBlock
_default()
Add the default block.-
Methods inherited from interface org.jboss.jdeparser.JCommentable
blockComment, lineComment
-
-
-
-
Method Detail
-
_case
JBlock _case(JExpr expr)
Add a switch case.- Parameters:
expr
- the case expression- Returns:
- a sub-block for the case logic
-
_case
JBlock _case(java.lang.String constName)
Add a switch case for anenum
constant.- Parameters:
constName
- the constant name- Returns:
- a sub-block for the case logic
-
_default
JBlock _default()
Add the default block.- Returns:
- the default sub-block
-
-