View Javadoc

    1   /**
    2    * BSD-style license; for more info see http://pmd.sourceforge.net/license.html
    3    */
    4   package net.sourceforge.pmd.lang.dfa;
    5
    6   /**
    7    * @author raik
    8    */
    9   // TODO This should be an enum?
    10  public class NodeType {
    11
    12      public static final int IF_EXPR = 1;
    13      public static final int IF_LAST_STATEMENT = 2;
    14      public static final int IF_LAST_STATEMENT_WITHOUT_ELSE = 3;
    15      public static final int ELSE_LAST_STATEMENT = 4;
    16
    17      public static final int WHILE_EXPR = 10;
    18      public static final int WHILE_LAST_STATEMENT = 11;
    19
    20      public static final int SWITCH_START = 20;
    21      public static final int CASE_LAST_STATEMENT = 21;
    22      public static final int SWITCH_LAST_DEFAULT_STATEMENT = 22;
    23      public static final int SWITCH_END = 23;
    24
    25      public static final int FOR_INIT = 30;
    26      public static final int FOR_EXPR = 31;
    27      public static final int FOR_UPDATE = 32;
    28      public static final int FOR_BEFORE_FIRST_STATEMENT = 33;
    29      public static final int FOR_END = 34;
    30
    31      public static final int DO_BEFORE_FIRST_STATEMENT = 40;
    32      public static final int DO_EXPR = 41;
    33
    34      public static final int RETURN_STATEMENT = 50;
    35      public static final int BREAK_STATEMENT = 51;
    36      public static final int CONTINUE_STATEMENT = 52;
    37
    38      public static final int LABEL_STATEMENT = 60;
    39      public static final int LABEL_LAST_STATEMENT = 61;
    40
    41      // TODO - throw statements?
    42      public static final int THROW_STATEMENT = 70;
    43  }