|
Object-oriented Parser System v3.6 |
|||||||||
| PREV NEXT | FRAMES NO FRAMES | |||||||||
noInput.
IOException into an error.
advance(int).
Input.charSequence();
can return this or new object.
Follow.marked.
ParserFactory.read() is false.
Input provider, allows access to a string using mutable
Inputs.StringBuilder.
Buffer.newInput(java.lang.StringBuilder) and advance(int).
ParserFactory aspect: build a tree.recognize.
Rule.
noInput and
lookahead and follow intersect.
Input provider, allows access to a string using immutable
Inputs.StringBuilder.
Input provider, allows access to a stream using immutable
Inputs.BufferedReader.
Permute.
delimit zero or more times.
delimit zero or more times.
ParserFactory aspect: display Parser.literals, Parser.patterns,
and Parser.rules as an indented tree.List-based tree.
dump helper must do.Parser to accept end of input.
parser() will return null.
Utils.error.
ParserFactory will assign the symbol values beginning with this one.
foldl.ParserFactory aspect: compute follow sets.parser:
set endOfFile for start rule; keep propagating until nothing changes.
Node.lookahead.
ParserFactory aspect: generate source code.Lookahead has not been run
or if Parser.Node.lookahead was initialized out of range.
lineNo.
Scanner.advance(scanner.Input).
Literal.
getLookahead().
Parser.Token.pattern.
Literal.
Pattern.
Token name (inefficient).
ParserFactory aspect: recover grammar from parser tree.Tree.Expression tree.
Parser.patterns, Parser.rules, and Parser.lookaheads.
Scanner.advance(scanner.Input).
error.
ParserFactory.Parser to accept a literal string.
ParserFactory.nextSymbol, ParserFactory.literals, ParserFactory.lookaheads.
Literal strings.
Parser.literals.
ParserFactory aspect: check LL(1).ParserFactory aspect: compute lookahead sets.Parser.
Parser.lookaheads.
Node.
Parser.lookaheads.
Parser to look up symbols for literals.
Parser to look up symbols for literals.
Parser to look up symbols for literals.
Parser to look up symbols for literals.
ParserFactory
and serializes the grammar tree to standard output.
ArrayList.
repeat zero or more times.
commands is used recursively.
Rule: set to indicate that rule needs to be traversed again.
Mvalue).ParserFactory aspect: generate functional source code.StringBuilder.
StringBuilder.
BufferedReader.
InputStream.
BufferedReader.
InputStream.
Terminal.
noInput:
if Build.addNull, add null to current collection.
noInput: do nothing.
Nonterminal name to index in ParserFactory.rules.
error.
ParserFactory aspect: observe recognition.recognize.
Observe.Observer.repeat at most once.
ParserFunction.ParserFactory and set up using package access.
ParserFactory.parser or null if there was an ParserFactory.error.
Nodes.Nodes.Nodes with delimiters.Nodes.List with lookahead.Rule.Nodes.Nodes.Token name.Nodes.Nodes.Nodes.Nonterminal name.Nodes.Literal and Token.Pattern.Nodes.Parsers.Scanner.
Parser.Parser, executed by parse.Parser to accept a pattern match.
Parser.patterns.
ParserFactory.nextSymbol, ParserFactory.tokens, ParserFactory.patterns, ParserFactory.lookaheads.
Pattern per Token name in order of definition.
Parser.patterns.
Permute:
arrange to collect into collection for alternative.
Permute.
PermutedList.
PermutedList.
Group:
send current follow set to descendant and ask it to propagate;
if lookahead of descendant accepts empty input add that lookahead to current follow set and remove empty input,
else set that lookahead as new current follow set.
Repeator to call ParserFactory.repeat
or ParserFactory.delimit,
or the Repeator created by the alternatives.
ParserFactory aspect: recognize input.ParserFactory aspect: check each rule for unlimited recursion.parser does not have unlimited recursion.
parse parse on Input.Boot and rfc.rfc.Repeat.Parser.rules.
ParserFactory.nonterminals, ParserFactory.rules, and Parser.start.
Rule per Nonterminal name in order of definition.
Parser.rules.
recognize.
Parser does for a scanner.ParserFactory.andThen
to produce the second parser and bind a value into its scope.Parser.Literal is accepted: does nothing.
Parser.Token is accepted: does nothing.
Parser.Nonterminal is accepted: does nothing.
Parser.Literal is accepted.
Parser.Token is accepted.
Parser.Nonterminal is accepted.
ArrayList.
repeat at least once.
Parser.rules.
Input provider, allows access to a stream using mutable
Inputs.BufferedReader.
Stream.newInput(java.io.BufferedReader) and advance(int).
MessageFormat.format templates to
generate output.
MessageFormat.format templates to generate output.
Scanner test driver, reads from scanner and prints to out.
Gl.yyLex.token().
Lambda.yyLex.token().
Scheme.yyLex.token().
ParserFactory.tokens.
yyLex.token().
Scanner.token().
Scanner.advance(scanner.Input).
Token name to index in ParserFactory.patterns.
Symbols, Literal, and Pattern set.
Observe.Observer into a Proxy for tracing.
Env.prev.
Gl.yyLex.value().
Lambda.yyLex.value().
Scheme.yyLex.value().
yyLex.value().
Scanner.value().
Scanner.advance(scanner.Input).
Rule:
push Build.current, visit right hand side, pop Build.current;
silently filter by invoking Build.builder.
Nonterminal:
visit rule; if result is ArrayList flatten,
else add result to Build.current.
Token:
add value to Build.current, then delegate to base class.
Permute:
collect each alternative separately,
add the collections, flattened, in order of definition.
PermutedList.
noInput to each alternative.
ParserFactory.
Sequence.
noInput if min is zero.
noInput in body or visit on deep pass.
noInput is allowed.
noInput is allowed.
Parser.orElse(mops.Parser).
Parser.andThen(mops.Scope) if more then one.
Rule:
save Observe.observer, replace it by result of init,
visit right hand side, send reduce,
restore Observe.observer, send shift.
Token:
send shift, then delegate to base class.
Literal:
send shift, then delegate to base class.
Visitor.
Rule: visit right hand side.
Nonterminal: visit rule.
Literal or Token: advance scanner.
Group:
for each element: visit if lookahead matches,
else if lookahead accepts noInput delegate to Recognize.noInput(),
else issue an error;
advance scanner until lookahead matches, visit.
Repeat:
(greedy algorithm) iterate body as a Group
until maximum is reached, or minimum is reached and lookahead does not match.
Delimit:
(greedy algorithm)
essentially like Repeat with visits to the delimiter interspersed;
complicated by the fact that either body or delimiter (but not both) can
accept noInput.
Xor: exactly one alternative must match.
Permute: (greedy algorithm)
copies ranges from directly nested Repeat
(but not Delimit),
continues to check lookaheads and visit appropriate alternatives
until for Or one or for And all
ranges and alternatives have been found.
PermutedList: (greedy algorithm)
essentially like Permute with visits to the delimiter interspersed.
noInput, otherwise check body.
Repeat.
visit(Node).
visit(Node).
visit(Node).
visit(Group).
visit(Repeat).
visit(Group).
visit(Group).
visit(Xor).
visit(Permute).
visit(Permute).
visit(Permute).
visit(PermutedList).
visit(PermutedList).
visit(Node).
visit(Node).
visit(Terminal).
visit(Terminal).
|
(c) 2008 Axel T. Schreiner |
|||||||||
| PREV NEXT | FRAMES NO FRAMES | |||||||||