Module org.apache.lucene.suggest
Record Class ContextQuery.ContextMetaData
java.lang.Object
java.lang.Record
org.apache.lucene.search.suggest.document.ContextQuery.ContextMetaData
- Record Components:
boost
- Boost associated with a context valueexact
- flag to indicate whether the context value should be treated as an exact value or a context prefix
- Enclosing class:
ContextQuery
Holder for context value meta data
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
ContextMetaData
(float boost, boolean exact) Creates an instance of aContextMetaData
record class. -
Method Summary
Modifier and TypeMethodDescriptionfloat
boost()
Returns the value of theboost
record component.final boolean
Indicates whether some other object is "equal to" this one.boolean
exact()
Returns the value of theexact
record component.final int
hashCode()
Returns a hash code value for this object.final String
toString()
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. All components in this record class are compared with '=='. -
boost
public float boost()Returns the value of theboost
record component.- Returns:
- the value of the
boost
record component
-
exact
public boolean exact()Returns the value of theexact
record component.- Returns:
- the value of the
exact
record component
-