Top Description Fields Constructors Methods
org.antlr.runtime

public Class CharStreamState

extends Object
Class Inheritance

When walking ahead with cyclic DFA or for syntactic predicates, we need to record the state of the input stream (char index, line, etc...) so that we can rewind the state after scanning ahead. This is the complete state of a stream.

Field Summary

Modifier and TypeField and Description
pack-priv int
charPositionInLine

What char position 0..n-1 in line is scanner before processing buffer[p]?

pack-priv int
line

What line number is the scanner at before processing buffer[p]?

pack-priv int
p

Index into the char stream of next lookahead char

Constructor Summary

AccessConstructor and Description
public

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

charPositionInLineback to summary
pack-priv int charPositionInLine

What char position 0..n-1 in line is scanner before processing buffer[p]?

lineback to summary
pack-priv int line

What line number is the scanner at before processing buffer[p]?

pback to summary
pack-priv int p

Index into the char stream of next lookahead char

Constructor Detail

CharStreamStateback to summary
public CharStreamState()