@Runtime public class EventFilter<N,D> extends Object implements EventGenerator<N,D>
EventGenerator
which throws
away all events.
Used for initialization whenever a X_LLkParser
is created.
Should be replaced by something else (e.g. a SAXEventGenerator
by
calling parser.
X_LLkParser.setEventGenerator(EventGenerator)
.
Can be useful for deriving own event genertaors which only need to implement
a subset of the interface methods (what java calls "Adapter" !-)Constructor and Description |
---|
EventFilter() |
Modifier and Type | Method and Description |
---|---|
void |
allow() |
void |
characters(String text) |
void |
endElement(N name) |
void |
error(String message) |
void |
fatalError(String message) |
Location<D> |
getLocation() |
Location<D> |
getLocation(antlr.RecognitionException e) |
void |
startElement(N name) |
void |
suppress() |
void |
warning(String message) |
public void suppress()
suppress
in interface EventGenerator<N,D>
public void allow() throws antlr.SemanticException
allow
in interface EventGenerator<N,D>
antlr.SemanticException
public void startElement(N name) throws antlr.SemanticException
startElement
in interface EventGenerator<N,D>
antlr.SemanticException
public void endElement(N name) throws antlr.SemanticException
endElement
in interface EventGenerator<N,D>
antlr.SemanticException
public void characters(String text) throws antlr.SemanticException
characters
in interface EventGenerator<N,D>
antlr.SemanticException
public void warning(String message) throws antlr.SemanticException
warning
in interface EventGenerator<N,D>
antlr.SemanticException
public void error(String message) throws antlr.SemanticException
error
in interface EventGenerator<N,D>
antlr.SemanticException
public void fatalError(String message) throws antlr.SemanticException
fatalError
in interface EventGenerator<N,D>
antlr.SemanticException
public Location<D> getLocation()
getLocation
in interface EventGenerator<N,D>
public Location<D> getLocation(antlr.RecognitionException e)
getLocation
in interface EventGenerator<N,D>
see also the complete user documentation .