public class IndexMatcher extends Object
| Constructor and Description |
|---|
IndexMatcher(IndexMaterializationStrategy indexGrammar) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canMatch(IndexedNonterminal materializableNonterminal,
IndexedNonterminal instantiableNonterminal)
Determines whether there is a materialization and an instantiation such that the
indices of the given nonterminals are equal.
|
Pair<AbstractIndexSymbol,List<IndexSymbol>> |
getMaterializationRule(IndexedNonterminal materializableNonterminal,
IndexedNonterminal instantiableNonterminal) |
List<IndexSymbol> |
getNecessaryInstantiation(IndexedNonterminal materializableNonterminal,
IndexedNonterminal instantiableNonterminal)
The sequence of symbols with which to replace the index variable at the end
of the index of the instantiableNonterminal in order to achieve equal indices
|
boolean |
needsInstantiation(IndexedNonterminal materializableNonterminal,
IndexedNonterminal instantiableNonterminal)
Determines whether the materializableNonterminal has to be instantiated to achieve equal indices
(can be false for concrete indices)
|
boolean |
needsMaterialization(IndexedNonterminal materializableNonterminal,
IndexedNonterminal instantiableNonterminal)
Determines whether the materializableNonterminal has to be materialized to achieve equal indices
|
public IndexMatcher(IndexMaterializationStrategy indexGrammar)
public boolean canMatch(IndexedNonterminal materializableNonterminal, IndexedNonterminal instantiableNonterminal)
materializableNonterminal - a nonterminal with a (possibly) abstract indexinstantiableNonterminal - a nonterminal with a (possibly) instantiable indexpublic boolean needsMaterialization(IndexedNonterminal materializableNonterminal, IndexedNonterminal instantiableNonterminal)
materializableNonterminal - the nonterminal in the graph which shall be replacedinstantiableNonterminal - the nonterminal representing the lhs of a rulepublic Pair<AbstractIndexSymbol,List<IndexSymbol>> getMaterializationRule(IndexedNonterminal materializableNonterminal, IndexedNonterminal instantiableNonterminal)
public boolean needsInstantiation(IndexedNonterminal materializableNonterminal, IndexedNonterminal instantiableNonterminal)
materializableNonterminal - the nonterminal in the graph which shall be replacedinstantiableNonterminal - the nonterminal representing the lhs of a rulepublic List<IndexSymbol> getNecessaryInstantiation(IndexedNonterminal materializableNonterminal, IndexedNonterminal instantiableNonterminal)
materializableNonterminal - the nonterminal in the graph that shall be replacedinstantiableNonterminal - the nonterminal representing the lhs in the grammarCopyright © 2019. All rights reserved.