Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

Source code: javax/ide/model/java/source/tree/SimpleStatementT.java


1   /*
2    * @(#)SimpleStatementT.java
3    */
4   
5   package javax.ide.model.java.source.tree;
6   
7   /**
8    * Common supertype for statements that have no child statement but
9    * may optionally have expressions. This includes the following types
10   * of statements: empty, expression, break, continue, return, throw,
11   * assert. <p/>
12   *
13   * @author Andy Yu
14   * */
15  public interface SimpleStatementT
16    extends StatementT
17  {
18    // ----------------------------------------------------------------------
19  
20    /**
21     * Valid for "break" and "continue" statements.
22     * @return The name of the target label. Null if none.
23     */
24    public NameT getExpressionName();
25  
26    /**
27     * Valid for "return", "throw", and "assert" statements and for
28     * "case" labels.
29     *
30     * @return the ExpressionT for this expression symbol. Null if this
31     * is an empty expression statement.
32     */
33    public ExpressionT getExpression();
34  
35    /**
36     * Valid for "assert" statements.
37     * Syntax is "assert boolean-expr: output-expr;".
38     *
39     * @return the output expression. Null if none was declared or if
40     * this is not an assert statement.
41     */
42    public ExpressionT getOutputExpression();
43  
44  
45    // ----------------------------------------------------------------------
46  }