pub struct IndexDocuments<'t, 'i, 'a, FP, FA> { /* private fields */ }Implementations§
Source§impl<'t, 'i, 'a, FP, FA> IndexDocuments<'t, 'i, 'a, FP, FA>
impl<'t, 'i, 'a, FP, FA> IndexDocuments<'t, 'i, 'a, FP, FA>
pub fn new( wtxn: &'t mut RwTxn<'i>, index: &'i Index, indexer_config: &'a IndexerConfig, config: IndexDocumentsConfig, progress: FP, should_abort: FA, ) -> Result<IndexDocuments<'t, 'i, 'a, FP, FA>>
Sourcepub fn add_documents<R: Read + Seek>(
self,
reader: DocumentsBatchReader<R>,
) -> Result<(Self, StdResult<u64, UserError>)>
pub fn add_documents<R: Read + Seek>( self, reader: DocumentsBatchReader<R>, ) -> Result<(Self, StdResult<u64, UserError>)>
Adds a batch of documents to the current builder.
Since the documents are progressively added to the writer, a failure will cause only
return an error and not the IndexDocuments struct as it is invalid to use it afterward.
Returns the number of documents added to the builder.
pub fn with_embedders(self, embedders: EmbeddingConfigs) -> Self
pub fn execute(self) -> Result<DocumentAdditionResult>
Sourcepub fn execute_raw(self, output: TransformOutput) -> Result<u64>
pub fn execute_raw(self, output: TransformOutput) -> Result<u64>
Returns the total number of documents in the index after the update.
pub fn execute_prefix_databases( self, word_docids: Option<Merger<CursorClonableMmap, MergeDeladdCboRoaringBitmaps>>, exact_word_docids: Option<Merger<CursorClonableMmap, MergeDeladdCboRoaringBitmaps>>, word_position_docids: Option<Merger<CursorClonableMmap, MergeDeladdCboRoaringBitmaps>>, word_fid_docids: Option<Merger<CursorClonableMmap, MergeDeladdCboRoaringBitmaps>>, ) -> Result<()>
Auto Trait Implementations§
impl<'t, 'i, 'a, FP, FA> Freeze for IndexDocuments<'t, 'i, 'a, FP, FA>
impl<'t, 'i, 'a, FP, FA> !RefUnwindSafe for IndexDocuments<'t, 'i, 'a, FP, FA>
impl<'t, 'i, 'a, FP, FA> Send for IndexDocuments<'t, 'i, 'a, FP, FA>
impl<'t, 'i, 'a, FP, FA> !Sync for IndexDocuments<'t, 'i, 'a, FP, FA>
impl<'t, 'i, 'a, FP, FA> Unpin for IndexDocuments<'t, 'i, 'a, FP, FA>
impl<'t, 'i, 'a, FP, FA> !UnwindSafe for IndexDocuments<'t, 'i, 'a, FP, FA>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more