Module org.apache.lucene.core
Class Lucene95HnswVectorsWriter.RAVectorValues<T>
java.lang.Object
org.apache.lucene.codecs.lucene95.Lucene95HnswVectorsWriter.RAVectorValues<T>
- All Implemented Interfaces:
RandomAccessVectorValues<T>
- Enclosing class:
- Lucene95HnswVectorsWriter
private static class Lucene95HnswVectorsWriter.RAVectorValues<T>
extends Object
implements RandomAccessVectorValues<T>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopy()
Creates a new copy of thisRandomAccessVectorValues
.int
Return the dimension of the returned vector valuesint
size()
Return the number of vector valuesvectorValue
(int targetOrd) Return the vector value indexed at the given ordinal.
-
Field Details
-
vectors
-
dim
private final int dim
-
-
Constructor Details
-
RAVectorValues
-
-
Method Details
-
size
public int size()Description copied from interface:RandomAccessVectorValues
Return the number of vector values- Specified by:
size
in interfaceRandomAccessVectorValues<T>
-
dimension
public int dimension()Description copied from interface:RandomAccessVectorValues
Return the dimension of the returned vector values- Specified by:
dimension
in interfaceRandomAccessVectorValues<T>
-
vectorValue
Description copied from interface:RandomAccessVectorValues
Return the vector value indexed at the given ordinal.- Specified by:
vectorValue
in interfaceRandomAccessVectorValues<T>
- Parameters:
targetOrd
- a valid ordinal, ≥ 0 and <RandomAccessVectorValues.size()
.- Throws:
IOException
-
copy
Description copied from interface:RandomAccessVectorValues
Creates a new copy of thisRandomAccessVectorValues
. This is helpful when you need to access different values at once, to avoid overwriting the underlying float vector returned byRandomAccessVectorValues.vectorValue(int)
.- Specified by:
copy
in interfaceRandomAccessVectorValues<T>
- Throws:
IOException
-