Package org.jparsec

Class ParserState

    • Field Detail

      • USED_ON_TOKEN_INPUT

        private static final java.lang.String USED_ON_TOKEN_INPUT
        See Also:
        Constant Field Values
      • input

        private final Token[] input
      • endIndex

        private final int endIndex
    • Constructor Detail

      • ParserState

        ParserState​(java.lang.String module,
                    java.lang.CharSequence source,
                    Token[] input,
                    int at,
                    SourceLocator locator,
                    int endIndex,
                    java.lang.Object result)
    • Method Detail

      • toIndex

        int toIndex​(int pos)
        Description copied from class: ParseContext
        Translates the logical position to physical index in the original source.
        Specified by:
        toIndex in class ParseContext
      • getToken

        Token getToken()
        Description copied from class: ParseContext
        Returns the current token. Only applicable to token level parser.
        Specified by:
        getToken in class ParseContext
      • peekChar

        char peekChar()
        Description copied from class: ParseContext
        Peeks the current character. Only applicable to character level parser.
        Specified by:
        peekChar in class ParseContext
      • characters

        java.lang.CharSequence characters()
        Description copied from class: ParseContext
        Reads the characters as input. Only applicable to character level parsers.
        Specified by:
        characters in class ParseContext
      • getInputName

        java.lang.String getInputName​(int pos)
        Description copied from class: ParseContext
        Returns the string representation of the current input (character or token).
        Specified by:
        getInputName in class ParseContext