Package antlr
Class BlockContext
- java.lang.Object
-
- antlr.BlockContext
-
- Direct Known Subclasses:
TreeBlockContext
class BlockContext extends java.lang.Object
BlockContext stores the information needed when creating an alternative (list of elements). Entering a subrule requires that we save this state as each block of alternatives requires state such as "tail of current alternative."
-
-
Field Summary
Fields Modifier and Type Field Description (package private) int
altNum
(package private) AlternativeBlock
block
(package private) BlockEndElement
blockEnd
-
Constructor Summary
Constructors Constructor Description BlockContext()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addAlternativeElement(AlternativeElement e)
Alternative
currentAlt()
AlternativeElement
currentElement()
-
-
-
Field Detail
-
block
AlternativeBlock block
-
altNum
int altNum
-
blockEnd
BlockEndElement blockEnd
-
-
Method Detail
-
addAlternativeElement
public void addAlternativeElement(AlternativeElement e)
-
currentAlt
public Alternative currentAlt()
-
currentElement
public AlternativeElement currentElement()
-
-