Package opennlp.tools.tokenize.lattice
Record Class MecabDictionary.WordEntry
java.lang.Object
java.lang.Record
opennlp.tools.tokenize.lattice.MecabDictionary.WordEntry
- Record Components:
leftId- The left context id, an index into the connection matrix.rightId- The right context id, an index into the connection matrix.cost- The entry's own cost.features- The entry's feature columns, in file order.
- Enclosing class:
MecabDictionary
static record MecabDictionary.WordEntry(int leftId, int rightId, int cost, List<String> features)
extends Record
One lexicon or unknown-word entry.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintcost()Returns the value of thecostrecord component.final booleanIndicates whether some other object is "equal to" this one.features()Returns the value of thefeaturesrecord component.final inthashCode()Returns a hash code value for this object.intleftId()Returns the value of theleftIdrecord component.intrightId()Returns the value of therightIdrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
Constructor Details
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
leftId
public int leftId()Returns the value of theleftIdrecord component.- Returns:
- the value of the
leftIdrecord component
-
rightId
public int rightId()Returns the value of therightIdrecord component.- Returns:
- the value of the
rightIdrecord component
-
cost
public int cost()Returns the value of thecostrecord component.- Returns:
- the value of the
costrecord component
-
features
Returns the value of thefeaturesrecord component.- Returns:
- the value of the
featuresrecord component
-