| java.lang.Object fri.patterns.interpreter.parsergenerator.parsertables.SLRSyntaxNode fri.patterns.interpreter.parsergenerator.parsertables.LRSyntaxNode
All known Subclasses: fri.patterns.interpreter.parsergenerator.parsertables.LALRSyntaxNode,
Inner Class :protected class LRRuleStateItem extends RuleStateItem | |
Constructor Summary | |
public | LRSyntaxNode(Nullable nullable, FirstSets firstSets) Construction of node with FIRST-sets and nullability of all nonterminals in syntax. |
nullable | protected Nullable nullable(Code) | | LR node must know about nullability.
|
LRSyntaxNode | public LRSyntaxNode(Nullable nullable, FirstSets firstSets)(Code) | | Construction of node with FIRST-sets and nullability of all nonterminals in syntax.
|
addRulesDerivingPendingNonTerminal | protected void addRulesDerivingPendingNonTerminal(RuleStateItem itm, String nonterm, Syntax syntax, List newItems)(Code) | | Method called from closure, adopt all rules that derive the pending nonterminal.
Default lookaheads are calculated here.
|
addStartLookahead | protected void addStartLookahead(LRRuleStateItem item, int ruleIndex)(Code) | | When start node (ruleIndex == 0), add EPSILON lookahead.
|
createRuleStateItem | protected RuleStateItem createRuleStateItem(int ruleIndex, Rule rule)(Code) | | Factory-method that constructs a LRRuleStateItem.
A start-lookahead gets appended to the item when it is the start node.
|
createSyntaxNode | protected SLRSyntaxNode createSyntaxNode()(Code) | | Factory-method that constructs a LRSyntaxNode.
|
getNontermShiftSymbols | protected List getNontermShiftSymbols(FirstSets firstSets, String nonterm)(Code) | | Returns all symbols for which SHIFT must be put into PARSE-ACTION table for a nonterminal.
For LR and LALR this returns null.
|
getReduceSymbols | protected Iterator getReduceSymbols(FollowSets followSets, RuleStateItem item)(Code) | | Returns all symbols for which REDUCE must be put into PARSE-ACTION table.
For LR and LALR this returns the lookahead of the passed item.
|
Fields inherited from fri.patterns.interpreter.parsergenerator.parsertables.SLRSyntaxNode | protected Hashtable entries(Code)(Java Doc)
|
Methods inherited from fri.patterns.interpreter.parsergenerator.parsertables.SLRSyntaxNode | protected void addRulesDerivingPendingNonTerminal(RuleStateItem item, String nonterm, Syntax syntax, List todo)(Code)(Java Doc) protected List addShiftedItems(String symbol, Hashtable originatorEntries)(Code)(Java Doc) public List build(Syntax syntax, List syntaxNodes, Hashtable kernels)(Code)(Java Doc) protected void closure(Syntax syntax)(Code)(Java Doc) protected RuleStateItem createRuleStateItem(int ruleIndex, Rule rule)(Code)(Java Doc) protected SLRSyntaxNode createSyntaxNode()(Code)(Java Doc) public boolean equals(Object o)(Code)(Java Doc) public Hashtable fillGotoLine(int state)(Code)(Java Doc) public Hashtable fillParseActionLine(int state, FirstSets firstSets, FollowSets followSets)(Code)(Java Doc) protected void generateSyntaxNodes(List syntaxNodes, Syntax syntax, Hashtable kernels)(Code)(Java Doc) protected void generateSyntaxNodesFromItems(List syntaxNodes, Syntax syntax, Hashtable kernels)(Code)(Java Doc) protected List getNontermShiftSymbols(FirstSets firstSets, String nonterm)(Code)(Java Doc) protected Iterator getReduceSymbols(FollowSets followSets, RuleStateItem item)(Code)(Java Doc) public int hashCode()(Code)(Java Doc) protected void linkParentItemToChild(RuleStateItem parent, int newIndex, List syntaxNodes, RuleStateItem child)(Code)(Java Doc) protected void setParseTableLine(int state, Hashtable line, RuleStateItem item, Integer action, String terminal)(Code)(Java Doc) protected boolean setTableLine(String table, int state, Hashtable line, RuleStateItem item, Integer action, String terminal)(Code)(Java Doc) public String toString()(Code)(Java Doc)
|
|
|