Package ghidra.app.util.cparser.C

# Class CParserTokenManager

java.lang.Object
ghidra.app.util.cparser.C.CParserTokenManager

All Implemented Interfaces:
  `CParserConstants`

public class CParserTokenManager extends Object implements CParserConstants
Token Manager.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `protected char`
  `curChar`
  `PrintStream`
  `debugStream`
  Debug output.
  `protected SimpleCharStream`
  `input_stream`
  `static final int[]`
  `jjnewLexState`
  Lex State array.
  `static final String[]`
  `jjstrLiteralImages`
  Token literal values.
  `static final String[]`
  `lexStateNames`
  Lexer state names.

  ### Fields inherited from interface ghidra.app.util.cparser.C.CParserConstants

  `ALIGNAS, ALIGNOF, ASM, ASM_SEMI, ASMBLOCK, ASMBLOCKB, ASMBLOCKP, ATTRIBUTE, AUTO, BOOL, BREAK, CASE, CDECL, CHAR, CHARACTER_LITERAL, CONST, CONTINUE, DECIMAL_LITERAL, DECLSPEC, DEFAULT, DFLT, DIGIT, DO, DOUBLE, ELSE, ENUM, EOF, EXPONENT, EXTENSION, EXTERN, FAR, FASTCALL, FLOAT, FLOATING_POINT_LITERAL, FOR, GOTO, HEX_LITERAL, IDENTIFIER, IF, INLINE, INT, INT16, INT32, INT64, INT8, INTEGER_LITERAL, INTERFACE, LETTER, LINE, LINEALT, LINEBLOCK, LINENUMBER_LITERAL, LONG, NEAR, NORETURN, OBJC, OBJC_DIGIT, OBJC_IDENTIFIER, OBJC_IGNORE, OBJC_LETTER, OBJC_SEMI, OBJC2, OBJC2_END, OBJC2_IGNORE, OCTAL_LITERAL, PACKED, PASCALCALL, PATH_LITERAL, PCLOSE, PCOLON, PCOMMA, PDECIMAL_LITERAL, PDIGIT, PHEX_LITERAL, PIDENTIFIER, PINTEGER_LITERAL, PLETTER, PMINUS, POCTAL_LITERAL, POPEN, PPLUS, PRAGMA, PRAGMA_FUNC, PRAGMALINE, PROTOCOL, PSTAR, PSTRING_LITERAL, PTR32, PTR64, QUOTE_C, READABLETO, REGISTER, RESTRICT, RETURN, RUSTCALL, SHORT, SIGNED, SIZEOF, STATIC, STATICASSERT, STDCALL, STRING_LITERAL, STRUCT, SWITCH, THREADLOCAL, tokenImage, TYPEDEF, UNALIGNED, UNION, UNSIGNED, VECTORCALL, VOID, VOLATILE, W64, WHILE`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `CParserTokenManager(SimpleCharStream stream)`
  Constructor.
  `CParserTokenManager(SimpleCharStream stream, int lexState)`
  Constructor.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Token`
  `getNextToken()`
  Get the next Token.
  `protected Token`
  `jjFillToken()`
  `void`
  `ReInit(SimpleCharStream stream)`
  Reinitialise parser.
  `void`
  `ReInit(SimpleCharStream stream, int lexState)`
  Reinitialise parser.
  `void`
  `setDebugStream(PrintStream ds)`
  Set debug output.
  `void`
  `SwitchTo(int lexState)`
  Switch to specified lex state.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### debugStream

    public PrintStream debugStream
    Debug output.

  - ### jjstrLiteralImages

    public static final String[] jjstrLiteralImages
    Token literal values.

  - ### lexStateNames

    public static final String[] lexStateNames
    Lexer state names.

  - ### jjnewLexState

    public static final int[] jjnewLexState
    Lex State array.

  - ### input_stream

    protected SimpleCharStream input_stream

  - ### curChar

    protected char curChar

- ## Constructor Details

  - ### CParserTokenManager

    public CParserTokenManager(SimpleCharStream stream)
    Constructor.

  - ### CParserTokenManager

    public CParserTokenManager(SimpleCharStream stream, int lexState)
    Constructor.

- ## Method Details

  - ### setDebugStream

    public void setDebugStream(PrintStream ds)
    Set debug output.

  - ### ReInit

    public void ReInit(SimpleCharStream stream)
    Reinitialise parser.

  - ### ReInit

    public void ReInit(SimpleCharStream stream, int lexState)
    Reinitialise parser.

  - ### SwitchTo

    public void SwitchTo(int lexState)
    Switch to specified lex state.

  - ### jjFillToken

    protected Token jjFillToken()

  - ### getNextToken

    public Token getNextToken()
    Get the next Token.