|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TableFactoryMethod<I extends NodeItem<I>>
Method Summary | |
---|---|
Grammar |
buildGrammar(Collection<? extends ProductionDecl> productions,
Set<? extends NonTerminalDecl> starts,
TerminalDecl eof)
builds the augmented grammar |
I |
createStartItem(ProductionDecl production,
TerminalDecl eof)
Create the kernel item for the start states |
NodeClosureComputer<I> |
getClosureComputer(Grammar grammar,
GrammarSets grammarSets,
TerminalDecl eof)
Returns the closure computer for this method |
Set<TerminalDecl> |
getLookaheads(Grammar g,
GrammarSets grammarSets,
I item,
NodeDecl<I> node)
returns the set of lookahead corresponding to a reduce action by item |
void |
initializeComputation(NodeFactory<I> factory,
Grammar grammar,
GrammarSets grammarSets,
TerminalDecl eof)
Initialize some computation (for LALR) |
Method Detail |
---|
NodeClosureComputer<I> getClosureComputer(Grammar grammar, GrammarSets grammarSets, TerminalDecl eof)
grammar
- the grammargrammarSets
- the grammar setseof
- the end of file terminal
Grammar buildGrammar(Collection<? extends ProductionDecl> productions, Set<? extends NonTerminalDecl> starts, TerminalDecl eof)
productions
- list of productionsstarts
- list of startseof
- terminal eof
Set<TerminalDecl> getLookaheads(Grammar g, GrammarSets grammarSets, I item, NodeDecl<I> node)
g
- the grammargrammarSets
- nullable, first and follow sets corresponding to gitem
- the item to reduce bynode
- the node
I createStartItem(ProductionDecl production, TerminalDecl eof)
production
- the starting productioneof
- the end of file terminal
void initializeComputation(NodeFactory<I> factory, Grammar grammar, GrammarSets grammarSets, TerminalDecl eof)
factory
- the factory used to build nodesgrammar
- the grammargrammarSets
- grammarSets first and follow sets corresponding the grammareof
- the end of file terminal
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |