Interface IndexIndexer
-
public interface IndexIndexer
An indexer scoped to a single index.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description CompletableFuture<?>
add(DocumentReferenceProvider referenceProvider, DocumentContributor documentContributor, DocumentCommitStrategy commitStrategy, DocumentRefreshStrategy refreshStrategy)
Add a document to the index, assuming that the document is absent from the index.CompletableFuture<?>
addOrUpdate(DocumentReferenceProvider referenceProvider, DocumentContributor documentContributor, DocumentCommitStrategy commitStrategy, DocumentRefreshStrategy refreshStrategy)
Update a document in the index, or add it if it's absent from the index.CompletableFuture<?>
delete(DocumentReferenceProvider referenceProvider, DocumentCommitStrategy commitStrategy, DocumentRefreshStrategy refreshStrategy)
Delete a document from the index.
-
-
-
Method Detail
-
add
CompletableFuture<?> add(DocumentReferenceProvider referenceProvider, DocumentContributor documentContributor, DocumentCommitStrategy commitStrategy, DocumentRefreshStrategy refreshStrategy)
Add a document to the index, assuming that the document is absent from the index.- Parameters:
referenceProvider
- A source of information about the identity of the document to add.documentContributor
- A contributor to the document, adding fields to the indexed document.commitStrategy
- How to handle the commit.refreshStrategy
- How to handle the refresh.- Returns:
- A
CompletableFuture
that completes once the document is added.
-
addOrUpdate
CompletableFuture<?> addOrUpdate(DocumentReferenceProvider referenceProvider, DocumentContributor documentContributor, DocumentCommitStrategy commitStrategy, DocumentRefreshStrategy refreshStrategy)
Update a document in the index, or add it if it's absent from the index.- Parameters:
referenceProvider
- A source of information about the identity of the document to update.documentContributor
- A contributor to the document, adding fields to the indexed document.commitStrategy
- How to handle the commit.refreshStrategy
- How to handle the refresh.- Returns:
- A
CompletableFuture
that completes once the document is updated.
-
delete
CompletableFuture<?> delete(DocumentReferenceProvider referenceProvider, DocumentCommitStrategy commitStrategy, DocumentRefreshStrategy refreshStrategy)
Delete a document from the index.- Parameters:
referenceProvider
- A source of information about the identity of the document to delete.commitStrategy
- How to handle the commit.refreshStrategy
- How to handle the refresh.- Returns:
- A
CompletableFuture
that completes once the document is deleted.
-
-