Enum Class TokenType

java.lang.Object
java.lang.Enum<TokenType>
org.openoffice.da.comp.w2lcommon.tex.tokenizer.TokenType
All Implemented Interfaces:
Serializable, Comparable<TokenType>, Constable

public enum TokenType extends Enum<TokenType>
This enumerates possible TeX tokens. According to chapter 7 in "The TeX book", a token is either a character with an associated catcode or a control sequence. We add "end of input" token as a convenience. Not all catcodes can actually end up in a token, so we only include the relevant ones.
  • Enum Constant Details

    • ESCAPE

      public static final TokenType ESCAPE
    • BEGIN_GROUP

      public static final TokenType BEGIN_GROUP
    • END_GROUP

      public static final TokenType END_GROUP
    • MATH_SHIFT

      public static final TokenType MATH_SHIFT
    • ALIGNMENT_TAB

      public static final TokenType ALIGNMENT_TAB
    • PARAMETER

      public static final TokenType PARAMETER
    • SUPERSCRIPT

      public static final TokenType SUPERSCRIPT
    • SUBSCRIPT

      public static final TokenType SUBSCRIPT
    • SPACE

      public static final TokenType SPACE
    • LETTER

      public static final TokenType LETTER
    • OTHER

      public static final TokenType OTHER
    • ACTIVE

      public static final TokenType ACTIVE
    • COMMAND_SEQUENCE

      public static final TokenType COMMAND_SEQUENCE
    • ENDINPUT

      public static final TokenType ENDINPUT
  • Method Details

    • values

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

      public static TokenType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified name
      NullPointerException - if the argument is null