public class Dap4Parser extends Dap4Actions
Modifier and Type | Class and Description |
---|---|
static interface |
dap4.core.dmr.parser.Dap4ParserBody.Lexer
Communication interface between the scanner and the Bison-generated
parser Dap4ParserBody.
|
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
bisonSkeleton
Name of the skeleton that generated this parser.
|
static java.lang.String |
bisonVersion
Version number for the Bison executable that generated this parser.
|
protected boolean |
debug |
protected ErrorResponse |
errorresponse |
protected DapFactory |
factory |
protected static boolean |
isdatadmr |
protected DapDataset |
root |
protected java.util.Deque<DapNode> |
scopestack |
static int |
YYABORT
Returned by a Bison action in order to stop the parsing process and
return failure (false).
|
static int |
YYACCEPT
Returned by a Bison action in order to stop the parsing process and
return success (true).
|
static int |
YYERROR
Returned by a Bison action in order to start error recovery without
printing an error message.
|
static int |
YYPUSH_MORE
Returned by a Bison action in order to request a new token.
|
Constructor and Description |
---|
Dap4Parser(DapFactory factory) |
Modifier and Type | Method and Description |
---|---|
int |
getDebugLevel()
Answer the verbosity of the debugging output; 0 means that all kinds of
output from the parser are suppressed.
|
java.io.PrintStream |
getDebugStream()
Return the PrintStream on which the debugging output is
printed.
|
DapDataset |
getDMR() |
ErrorResponse |
getErrorResponse() |
boolean |
getErrorVerbose()
Return whether verbose error messages are enabled.
|
boolean |
parse(java.lang.String input) |
void |
push_parse_initialize()
(Re-)Initialize the state of the push parser.
|
int |
push_parse(int yylextoken,
java.lang.Object yylexval,
Bison.Position yylexpos)
Push parse given input from an external lexer.
|
int |
push_parse(int yylextoken,
java.lang.Object yylexval,
dap4.core.dmr.parser.Dap4ParserBody.Location yylexloc)
Push Parse input from external lexer
|
boolean |
recovering()
Return whether error recovery is being done.
|
void |
setDebugLevel(int level)
Set the verbosity of the debugging output; 0 means that all kinds of
output from the parser are suppressed.
|
void |
setDebugStream(java.io.PrintStream s)
Set the PrintStream on which the debug output is printed.
|
void |
setErrorVerbose(boolean verbose)
Set the verbosity of error messages.
|
protected void |
yycdebug(java.lang.String s) |
void |
yyerror(Bison.Position pos,
java.lang.String msg)
Print an error message via the lexer.
|
void |
yyerror(dap4.core.dmr.parser.Dap4ParserBody.Location loc,
java.lang.String msg)
Print an error message via the lexer.
|
void |
yyerror(java.lang.String msg)
Print an error message via the lexer.
|
yyevent
characters, endDocument, endElement, endPrefixMapping, error, fatalError, getLocator, ignorableWhitespace, locatedError, locatedEvent, notationDecl, processingInstruction, report, resolveEntity, setDocumentLocator, skippedEntity, startDocument, startElement, startPrefixMapping, trace, unparsedEntityDecl, warning
protected static final boolean isdatadmr
protected DapFactory factory
protected ErrorResponse errorresponse
protected java.util.Deque<DapNode> scopestack
protected DapDataset root
protected boolean debug
public static final java.lang.String bisonVersion
public static final java.lang.String bisonSkeleton
public static final int YYACCEPT
public static final int YYABORT
public static final int YYPUSH_MORE
public static final int YYERROR
public Dap4Parser(DapFactory factory)
public ErrorResponse getErrorResponse()
public DapDataset getDMR()
public boolean parse(java.lang.String input) throws org.xml.sax.SAXException
parse
in class SaxEventHandler
org.xml.sax.SAXException
public final boolean getErrorVerbose()
public final void setErrorVerbose(boolean verbose)
verbose
- True to request verbose error messages.public final java.io.PrintStream getDebugStream()
public final void setDebugStream(java.io.PrintStream s)
s
- The stream that is used for debugging output.public final int getDebugLevel()
public final void setDebugLevel(int level)
level
- The verbosity level for debugging output.public final void yyerror(java.lang.String msg)
null
location.msg
- The error message.public final void yyerror(dap4.core.dmr.parser.Dap4ParserBody.Location loc, java.lang.String msg)
loc
- The location associated with the message.msg
- The error message.public final void yyerror(Bison.Position pos, java.lang.String msg)
pos
- The position associated with the message.msg
- The error message.protected final void yycdebug(java.lang.String s)
public final boolean recovering()
public int push_parse(int yylextoken, java.lang.Object yylexval, dap4.core.dmr.parser.Dap4ParserBody.Location yylexloc) throws DapException, DapException
yylextoken
- current tokenyylexval
- current lvalyylexloc
- current positionDapException
public void push_parse_initialize()
public int push_parse(int yylextoken, java.lang.Object yylexval, Bison.Position yylexpos) throws DapException, DapException
yylextoken
- current tokenyylexval
- current lvalyylexpos
- current positionDapException