|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.stanford.nlp.trees.UnnamedDependency
public class UnnamedDependency
An individual dependency between a head and a dependent. The head and dependent are represented as a Label. For example, these can be a Word or a WordTag. If one wishes the dependencies to preserve positions in a sentence, then each can be a LabeledConstituent.
Constructor Summary | |
---|---|
UnnamedDependency(Label regent,
Label dependent)
|
|
UnnamedDependency(java.lang.String regent,
int regentStartIndex,
int regentEndIndex,
java.lang.String dependent,
int depStartIndex,
int depEndIndex)
|
|
UnnamedDependency(java.lang.String regent,
int regentIndex,
java.lang.String dependent,
int dependentIndex)
|
|
UnnamedDependency(java.lang.String regent,
java.lang.String dependent)
|
Method Summary | |
---|---|
int |
compareTo(java.lang.Object obj)
Implementation of comparison for UnnamedDependency . |
DependencyFactory |
dependencyFactory()
Provide a factory for this kind of dependency |
Label |
dependent()
Describes the dependent (argument/modifier) of the dependency relation. |
boolean |
equalIgnoringName(java.lang.Object o)
Are two dependencies equal if you ignore the dependency name. |
boolean |
equals(java.lang.Object o)
|
static DependencyFactory |
factory()
|
Label |
governor()
Describes the governor (regent/head) of the dependency relation. |
int |
hashCode()
|
java.lang.Object |
name()
Names the type of dependency (subject, instrument, ...). |
java.lang.String |
toString()
|
java.lang.String |
toString(java.lang.String format)
Provide different printing options via a String keyword. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public UnnamedDependency(java.lang.String regent, java.lang.String dependent)
public UnnamedDependency(java.lang.String regent, int regentIndex, java.lang.String dependent, int dependentIndex)
public UnnamedDependency(java.lang.String regent, int regentStartIndex, int regentEndIndex, java.lang.String dependent, int depStartIndex, int depEndIndex)
public UnnamedDependency(Label regent, Label dependent)
Method Detail |
---|
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public boolean equalIgnoringName(java.lang.Object o)
Dependency
equalIgnoringName
in interface Dependency
public int compareTo(java.lang.Object obj)
UnnamedDependency
.
Orders by governor, then dependent, then name.
compareTo
in interface java.lang.Comparable
obj
- object to compare to
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String toString(java.lang.String format)
toString
in interface Dependency
public Label governor()
Dependency
governor
in interface Dependency
public Label dependent()
Dependency
dependent
in interface Dependency
public java.lang.Object name()
Dependency
name
in interface Dependency
public DependencyFactory dependencyFactory()
Dependency
dependencyFactory
in interface Dependency
public static DependencyFactory factory()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |