Record Class MascSentence.QuarkExtractor
java.lang.Object
java.lang.Record
opennlp.tools.formats.masc.MascSentence.QuarkExtractor
- Record Components:
wordsById- Quarks of the sentence organized by their idallDocumentWords- Quarks of the document organized by their id
- Enclosing class:
MascSentence
-
Field Summary
FieldsModifier and TypeFieldDescriptionThe field for theallDocumentWordsrecord component.The field for thewordsByIdrecord component. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theallDocumentWordsrecord component.final booleanIndicates whether some other object is "equal to" this one.private MascWordget(int key) Extract a quark by its keyfinal inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.Returns the value of thewordsByIdrecord component.
-
Field Details
-
wordsById
-
allDocumentWords
The field for theallDocumentWordsrecord component.
-
-
Constructor Details
-
QuarkExtractor
-
-
Method Details
-
get
Extract a quark by its key- Parameters:
key- The quark's ID- Returns:
- The
quark reference. - Throws:
IOException- Thrown if thekeywas not found in the document.
-
toString
-
hashCode
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
wordsById
-
allDocumentWords
Returns the value of theallDocumentWordsrecord component.- Returns:
- the value of the
allDocumentWordsrecord component
-