Record Class OptimizedScalarQuantizer.QuantizationResult
java.lang.Object
java.lang.Record
org.apache.lucene.util.quantization.OptimizedScalarQuantizer.QuantizationResult
- Record Components:
lowerInterval
- the lower interval boundupperInterval
- the upper interval boundadditionalCorrection
- the additional correctionquantizedComponentSum
- the sum of the quantized components
- Enclosing class:
OptimizedScalarQuantizer
public static record OptimizedScalarQuantizer.QuantizationResult(float lowerInterval, float upperInterval, float additionalCorrection, int quantizedComponentSum)
extends Record
Quantization result containing the lower and upper interval bounds, the additional correction
-
Constructor Summary
ConstructorsConstructorDescriptionQuantizationResult
(float lowerInterval, float upperInterval, float additionalCorrection, int quantizedComponentSum) Creates an instance of aQuantizationResult
record class. -
Method Summary
Modifier and TypeMethodDescriptionfloat
Returns the value of theadditionalCorrection
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.float
Returns the value of thelowerInterval
record component.int
Returns the value of thequantizedComponentSum
record component.final String
toString()
Returns a string representation of this record class.float
Returns the value of theupperInterval
record component.
-
Constructor Details
-
QuantizationResult
public QuantizationResult(float lowerInterval, float upperInterval, float additionalCorrection, int quantizedComponentSum) Creates an instance of aQuantizationResult
record class.- Parameters:
lowerInterval
- the value for thelowerInterval
record componentupperInterval
- the value for theupperInterval
record componentadditionalCorrection
- the value for theadditionalCorrection
record componentquantizedComponentSum
- the value for thequantizedComponentSum
record component
-
-
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 '=='. -
lowerInterval
public float lowerInterval()Returns the value of thelowerInterval
record component.- Returns:
- the value of the
lowerInterval
record component
-
upperInterval
public float upperInterval()Returns the value of theupperInterval
record component.- Returns:
- the value of the
upperInterval
record component
-
additionalCorrection
public float additionalCorrection()Returns the value of theadditionalCorrection
record component.- Returns:
- the value of the
additionalCorrection
record component
-
quantizedComponentSum
public int quantizedComponentSum()Returns the value of thequantizedComponentSum
record component.- Returns:
- the value of the
quantizedComponentSum
record component
-