Record Class IVFVectorsReader.FieldEntry

java.lang.Object
java.lang.Record
org.elasticsearch.index.codec.vectors.IVFVectorsReader.FieldEntry
Enclosing class:
IVFVectorsReader

protected static record IVFVectorsReader.FieldEntry(org.apache.lucene.index.VectorSimilarityFunction similarityFunction, org.apache.lucene.index.VectorEncoding vectorEncoding, long centroidOffset, long centroidLength, long[] postingListOffsets, float[] globalCentroid, float globalCentroidDp) extends Record
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    FieldEntry(org.apache.lucene.index.VectorSimilarityFunction similarityFunction, org.apache.lucene.index.VectorEncoding vectorEncoding, long centroidOffset, long centroidLength, long[] postingListOffsets, float[] globalCentroid, float globalCentroidDp)
    Creates an instance of a FieldEntry record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    long
    Returns the value of the centroidLength record component.
    long
    Returns the value of the centroidOffset record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    float[]
    Returns the value of the globalCentroid record component.
    float
    Returns the value of the globalCentroidDp record component.
    final int
    Returns a hash code value for this object.
    long[]
    Returns the value of the postingListOffsets record component.
    org.apache.lucene.index.VectorSimilarityFunction
    Returns the value of the similarityFunction record component.
    final String
    Returns a string representation of this record class.
    org.apache.lucene.index.VectorEncoding
    Returns the value of the vectorEncoding record component.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • FieldEntry

      protected FieldEntry(org.apache.lucene.index.VectorSimilarityFunction similarityFunction, org.apache.lucene.index.VectorEncoding vectorEncoding, long centroidOffset, long centroidLength, long[] postingListOffsets, float[] globalCentroid, float globalCentroidDp)
      Creates an instance of a FieldEntry record class.
      Parameters:
      similarityFunction - the value for the similarityFunction record component
      vectorEncoding - the value for the vectorEncoding record component
      centroidOffset - the value for the centroidOffset record component
      centroidLength - the value for the centroidLength record component
      postingListOffsets - the value for the postingListOffsets record component
      globalCentroid - the value for the globalCentroid record component
      globalCentroidDp - the value for the globalCentroidDp record component
  • Method Details

    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • 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.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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 with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • similarityFunction

      public org.apache.lucene.index.VectorSimilarityFunction similarityFunction()
      Returns the value of the similarityFunction record component.
      Returns:
      the value of the similarityFunction record component
    • vectorEncoding

      public org.apache.lucene.index.VectorEncoding vectorEncoding()
      Returns the value of the vectorEncoding record component.
      Returns:
      the value of the vectorEncoding record component
    • centroidOffset

      public long centroidOffset()
      Returns the value of the centroidOffset record component.
      Returns:
      the value of the centroidOffset record component
    • centroidLength

      public long centroidLength()
      Returns the value of the centroidLength record component.
      Returns:
      the value of the centroidLength record component
    • postingListOffsets

      public long[] postingListOffsets()
      Returns the value of the postingListOffsets record component.
      Returns:
      the value of the postingListOffsets record component
    • globalCentroid

      public float[] globalCentroid()
      Returns the value of the globalCentroid record component.
      Returns:
      the value of the globalCentroid record component
    • globalCentroidDp

      public float globalCentroidDp()
      Returns the value of the globalCentroidDp record component.
      Returns:
      the value of the globalCentroidDp record component