|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.stanford.nlp.parser.lexparser.UnaryGrammar
public class UnaryGrammar
Maintains efficient indexing of unary grammar rules.
Constructor Summary | |
---|---|
UnaryGrammar(int numStates)
|
|
UnaryGrammar(int numStates,
String stateSpace)
|
Method Summary | |
---|---|
void |
addRule(UnaryRule ur)
|
Iterator<UnaryRule> |
closedRuleIterator()
|
Iterator<UnaryRule> |
closedRuleIteratorByChild(int state)
|
Iterator<UnaryRule> |
closedRuleIteratorByParent(int state)
|
UnaryRule[] |
closedRulesByChild(int state)
|
UnaryRule[] |
closedRulesByParent(int state)
|
List<Integer> |
getBestPath(int parent,
int child)
|
Iterator<UnaryRule> |
iterator()
|
int |
numClosedRules()
|
int |
numRules()
|
void |
purgeRules()
Remove A -> A UnaryRules from bestRulesUnderMax. |
void |
readData(BufferedReader in)
Populates data in this UnaryGrammar from the character stream given by the Reader in. |
Iterator<UnaryRule> |
ruleIterator()
|
Iterator<UnaryRule> |
ruleIteratorByChild(int state)
|
Iterator<UnaryRule> |
ruleIteratorByParent(int state)
|
List<UnaryRule> |
rules()
|
List<UnaryRule> |
rulesByChild(int state)
|
List<UnaryRule> |
rulesByParent(int state)
|
List[] |
rulesWithParent()
|
double |
scoreRule(UnaryRule ur)
|
String |
toString()
|
void |
writeData(Writer w)
Writes out data from this Object to the Writer w. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public UnaryGrammar(int numStates)
public UnaryGrammar(int numStates, String stateSpace)
Method Detail |
---|
public int numClosedRules()
public Iterator<UnaryRule> closedRuleIterator()
public int numRules()
public Iterator<UnaryRule> iterator()
iterator
in interface Iterable<UnaryRule>
public Iterator<UnaryRule> ruleIterator()
public List<UnaryRule> rules()
public void purgeRules()
public List<Integer> getBestPath(int parent, int child)
public double scoreRule(UnaryRule ur)
public void addRule(UnaryRule ur)
public UnaryRule[] closedRulesByParent(int state)
public UnaryRule[] closedRulesByChild(int state)
public Iterator<UnaryRule> closedRuleIteratorByParent(int state)
public Iterator<UnaryRule> closedRuleIteratorByChild(int state)
public Iterator<UnaryRule> ruleIteratorByParent(int state)
public Iterator<UnaryRule> ruleIteratorByChild(int state)
public List<UnaryRule> rulesByParent(int state)
public List<UnaryRule> rulesByChild(int state)
public List[] rulesWithParent()
public void readData(BufferedReader in) throws IOException
IOException
public void writeData(Writer w) throws IOException
IOException
public String toString()
toString
in class Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |