public interface TextIndexingService
Represents a full-text indexing engine. It scans a document and modifies full-text index entries by decomposing texts of an indexed field, into a set of string tokens. It uses the full-text index to search for a specific text.
Modifier and Type | Method and Description |
---|---|
void |
clear()
Deletes all full-text index entries.
|
void |
close()
Closes all opened resources.
|
void |
commit()
Commits any unsaved changes.
|
void |
createIndex(NitriteId id,
java.lang.String field,
java.lang.String text)
Creates a full-text index entry from a specific
field
containing the text . |
void |
deleteIndex(NitriteId id,
java.lang.String field,
java.lang.String text)
Deletes a full-text index entry.
|
void |
deleteIndexesByField(java.lang.String field)
Deletes all full-text index entries of the
field . |
void |
drop()
Drops all full-text index entries of a collection.
|
java.util.Set<NitriteId> |
searchByIndex(java.lang.String field,
java.lang.String searchString)
Searches
searchString using the full-text index of the field . |
void |
updateIndex(NitriteId id,
java.lang.String field,
java.lang.String text)
Updates a full-text index entry.
|
void createIndex(NitriteId id, java.lang.String field, java.lang.String text)
Creates a full-text index entry from a specific field
containing the text
.
id
- the id associated with the document containing the text
field
- the indexed fieldtext
- the text to indexvoid updateIndex(NitriteId id, java.lang.String field, java.lang.String text)
Updates a full-text index entry.
id
- the id associated with the document containing the text
field
- the indexed fieldtext
- the text to updatevoid deleteIndex(NitriteId id, java.lang.String field, java.lang.String text)
Deletes a full-text index entry.
id
- the id associated with the document containing the text
field
- the indexed fieldtext
- the text to deletevoid deleteIndexesByField(java.lang.String field)
Deletes all full-text index entries of the field
.
field
- the fieldjava.util.Set<NitriteId> searchByIndex(java.lang.String field, java.lang.String searchString)
Searches searchString
using the full-text index of the field
.
field
- the fieldsearchString
- the search string to search using indexNitriteId
s for the matching documents.void drop()
Drops all full-text index entries of a collection.
void clear()
Deletes all full-text index entries.
void commit()
Commits any unsaved changes. Third-party implementation should use his method to persists unsaved changes.
void close()
Closes all opened resources. Third-party implementation should use this method to close all resources before database closes.