Record Class Lucene91HnswVectorsReader.FieldEntry
java.lang.Object
java.lang.Record
org.apache.lucene.backward_codecs.lucene91.Lucene91HnswVectorsReader.FieldEntry
- Enclosing class:
Lucene91HnswVectorsReader
private static record Lucene91HnswVectorsReader.FieldEntry(VectorSimilarityFunction similarityFunction, long vectorDataOffset, long vectorDataLength, long vectorIndexOffset, long vectorIndexLength, int maxConn, int numLevels, int dimension, int size, int[] ordToDoc, IntUnaryOperator ordToDocOperator, int[][] nodesByLevel, long[] graphOffsetsByLevel)
extends Record
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final int
The field for thedimension
record component.private final long[]
The field for thegraphOffsetsByLevel
record component.private final int
The field for themaxConn
record component.private final int[][]
The field for thenodesByLevel
record component.private final int
The field for thenumLevels
record component.private final int[]
The field for theordToDoc
record component.private final IntUnaryOperator
The field for theordToDocOperator
record component.private final VectorSimilarityFunction
The field for thesimilarityFunction
record component.private final int
The field for thesize
record component.private final long
The field for thevectorDataLength
record component.private final long
The field for thevectorDataOffset
record component.private final long
The field for thevectorIndexLength
record component.private final long
The field for thevectorIndexOffset
record component. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
FieldEntry
(VectorSimilarityFunction similarityFunction, long vectorDataOffset, long vectorDataLength, long vectorIndexOffset, long vectorIndexLength, int maxConn, int numLevels, int dimension, int size, int[] ordToDoc, IntUnaryOperator ordToDocOperator, int[][] nodesByLevel, long[] graphOffsetsByLevel) Creates an instance of aFieldEntry
record class. -
Method Summary
Modifier and TypeMethodDescription(package private) static Lucene91HnswVectorsReader.FieldEntry
create
(DataInput input, VectorSimilarityFunction similarityFunction) int
Returns the value of thedimension
record component.final boolean
Indicates whether some other object is "equal to" this one.long[]
Returns the value of thegraphOffsetsByLevel
record component.final int
hashCode()
Returns a hash code value for this object.int
maxConn()
Returns the value of themaxConn
record component.int[][]
Returns the value of thenodesByLevel
record component.int
Returns the value of thenumLevels
record component.int[]
ordToDoc()
Returns the value of theordToDoc
record component.(package private) int
ordToDoc
(int ord) Returns the value of theordToDocOperator
record component.Returns the value of thesimilarityFunction
record component.int
size()
Returns the value of thesize
record component.final String
toString()
Returns a string representation of this record class.long
Returns the value of thevectorDataLength
record component.long
Returns the value of thevectorDataOffset
record component.long
Returns the value of thevectorIndexLength
record component.long
Returns the value of thevectorIndexOffset
record component.
-
Field Details
-
similarityFunction
The field for thesimilarityFunction
record component. -
vectorDataOffset
private final long vectorDataOffsetThe field for thevectorDataOffset
record component. -
vectorDataLength
private final long vectorDataLengthThe field for thevectorDataLength
record component. -
vectorIndexOffset
private final long vectorIndexOffsetThe field for thevectorIndexOffset
record component. -
vectorIndexLength
private final long vectorIndexLengthThe field for thevectorIndexLength
record component. -
maxConn
private final int maxConnThe field for themaxConn
record component. -
numLevels
private final int numLevelsThe field for thenumLevels
record component. -
dimension
private final int dimensionThe field for thedimension
record component. -
size
private final int sizeThe field for thesize
record component. -
ordToDoc
private final int[] ordToDocThe field for theordToDoc
record component. -
ordToDocOperator
The field for theordToDocOperator
record component. -
nodesByLevel
private final int[][] nodesByLevelThe field for thenodesByLevel
record component. -
graphOffsetsByLevel
private final long[] graphOffsetsByLevelThe field for thegraphOffsetsByLevel
record component.
-
-
Constructor Details
-
FieldEntry
private FieldEntry(VectorSimilarityFunction similarityFunction, long vectorDataOffset, long vectorDataLength, long vectorIndexOffset, long vectorIndexLength, int maxConn, int numLevels, int dimension, int size, int[] ordToDoc, IntUnaryOperator ordToDocOperator, int[][] nodesByLevel, long[] graphOffsetsByLevel) Creates an instance of aFieldEntry
record class.- Parameters:
similarityFunction
- the value for thesimilarityFunction
record componentvectorDataOffset
- the value for thevectorDataOffset
record componentvectorDataLength
- the value for thevectorDataLength
record componentvectorIndexOffset
- the value for thevectorIndexOffset
record componentvectorIndexLength
- the value for thevectorIndexLength
record componentmaxConn
- the value for themaxConn
record componentnumLevels
- the value for thenumLevels
record componentdimension
- the value for thedimension
record componentsize
- the value for thesize
record componentordToDoc
- the value for theordToDoc
record componentordToDocOperator
- the value for theordToDocOperator
record componentnodesByLevel
- the value for thenodesByLevel
record componentgraphOffsetsByLevel
- the value for thegraphOffsetsByLevel
record component
-
-
Method Details
-
create
static Lucene91HnswVectorsReader.FieldEntry create(DataInput input, VectorSimilarityFunction similarityFunction) throws IOException - Throws:
IOException
-
ordToDoc
int ordToDoc(int ord) -
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 '=='. -
similarityFunction
Returns the value of thesimilarityFunction
record component.- Returns:
- the value of the
similarityFunction
record component
-
vectorDataOffset
public long vectorDataOffset()Returns the value of thevectorDataOffset
record component.- Returns:
- the value of the
vectorDataOffset
record component
-
vectorDataLength
public long vectorDataLength()Returns the value of thevectorDataLength
record component.- Returns:
- the value of the
vectorDataLength
record component
-
vectorIndexOffset
public long vectorIndexOffset()Returns the value of thevectorIndexOffset
record component.- Returns:
- the value of the
vectorIndexOffset
record component
-
vectorIndexLength
public long vectorIndexLength()Returns the value of thevectorIndexLength
record component.- Returns:
- the value of the
vectorIndexLength
record component
-
maxConn
public int maxConn()Returns the value of themaxConn
record component.- Returns:
- the value of the
maxConn
record component
-
numLevels
public int numLevels()Returns the value of thenumLevels
record component.- Returns:
- the value of the
numLevels
record component
-
dimension
public int dimension()Returns the value of thedimension
record component.- Returns:
- the value of the
dimension
record component
-
size
public int size()Returns the value of thesize
record component.- Returns:
- the value of the
size
record component
-
ordToDoc
public int[] ordToDoc()Returns the value of theordToDoc
record component.- Returns:
- the value of the
ordToDoc
record component
-
ordToDocOperator
Returns the value of theordToDocOperator
record component.- Returns:
- the value of the
ordToDocOperator
record component
-
nodesByLevel
public int[][] nodesByLevel()Returns the value of thenodesByLevel
record component.- Returns:
- the value of the
nodesByLevel
record component
-
graphOffsetsByLevel
public long[] graphOffsetsByLevel()Returns the value of thegraphOffsetsByLevel
record component.- Returns:
- the value of the
graphOffsetsByLevel
record component
-