Enum TerminalKind

java.lang.Object
java.lang.Enum<TerminalKind>
org.oristool.lello.parse.TerminalKind
All Implemented Interfaces:
Serializable, Comparable<TerminalKind>

public enum TerminalKind extends Enum<TerminalKind>
Represents the kind of a terminal symbol. The kind of a terminal symbol influences the behavior (precedence, associativity, etc...) of the parser when it encounters the symbol.
  • Enum Constant Details

    • UNKNOWN

      public static final TerminalKind UNKNOWN
      An unknown terminal symbol.
    • EOF

      public static final TerminalKind EOF
      Indicates the end of an input.
    • CONSTANT_NIL

      public static final TerminalKind CONSTANT_NIL
      Represents the constant nil.
    • CONSTANT_BOOLEAN

      public static final TerminalKind CONSTANT_BOOLEAN
      A BOOLEAN constant.
    • CONSTANT_INTEGER

      public static final TerminalKind CONSTANT_INTEGER
      An INTEGER constant.
    • CONSTANT_REAL

      public static final TerminalKind CONSTANT_REAL
      A REAL constant.
    • CONSTANT_STRING

      public static final TerminalKind CONSTANT_STRING
      A STRING constant.
    • IDENTIFIER

      public static final TerminalKind IDENTIFIER
      An identifier such as a variable name of function name.
    • BIN_OP_LOGIC_TERMS

      public static final TerminalKind BIN_OP_LOGIC_TERMS
      A logic binary operator which has the same precedence as logical or.
    • BIN_OP_LOGIC_FACTORS

      public static final TerminalKind BIN_OP_LOGIC_FACTORS
      A logic binary operator which has the same precedence as logical and.
    • PREFIX_OP_LOGIC

      public static final TerminalKind PREFIX_OP_LOGIC
      A prefixed logic unary operator.
    • SUFFIX_OP_LOGIC

      public static final TerminalKind SUFFIX_OP_LOGIC
      A suffixed logic unary operator.
    • BIN_OP_RELS

      public static final TerminalKind BIN_OP_RELS
      A relational binary operator such as == or <=.
    • BIN_OP_TERMS

      public static final TerminalKind BIN_OP_TERMS
      An arithmetic binary operator which has the same precedence as the addition.
    • BIN_OP_FACTORS

      public static final TerminalKind BIN_OP_FACTORS
      An arithmetic binary operator which has the same precedence as the multiplication.
    • PREFIX_OP

      public static final TerminalKind PREFIX_OP
      A prefixed arithmetic unary operator.
    • SUFFIX_OP

      public static final TerminalKind SUFFIX_OP
      A suffixed arithmetic unary operator.
    • BIN_OP_POWERS

      public static final TerminalKind BIN_OP_POWERS
      An arithmetic binary operator which has the same precedence as the power.
    • BRACKET_OPEN

      public static final TerminalKind BRACKET_OPEN
      An open bracket.
    • BRACKET_CLOSE

      public static final TerminalKind BRACKET_CLOSE
      A closing bracket.
    • COMMA

      public static final TerminalKind COMMA
      A comma.
  • Method Details

    • values

      public static TerminalKind[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static TerminalKind valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null