Package opennlp.tools.langdetect
Record Class ProbingLanguageDetectionResult
java.lang.Object
java.lang.Record
opennlp.tools.langdetect.ProbingLanguageDetectionResult
- Record Components:
languages
- Thelanguages
detected.length
- The length in codepoints of text processed.
A data container encapsulating language detection results.
-
Constructor Summary
ConstructorDescriptionProbingLanguageDetectionResult
(Language[] languages, int length) Creates an instance of aProbingLanguageDetectionResult
record class. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.Language[]
Deprecated, for removal: This API element is subject to removal in a future version.int
Deprecated, for removal: This API element is subject to removal in a future version.final int
hashCode()
Returns a hash code value for this object.Language[]
Returns the value of thelanguages
record component.int
length()
Returns the value of thelength
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
Method Details
-
getLanguages
Deprecated, for removal: This API element is subject to removal in a future version. -
getLength
Deprecated, for removal: This API element is subject to removal in a future version. -
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 '=='. -
languages
Returns the value of thelanguages
record component.- Returns:
- the value of the
languages
record component
-
length
public int length()Returns the value of thelength
record component.- Returns:
- the value of the
length
record component
-