Object to declare the items for an update of a document in the storage.
More...
#include <storageDocumentUpdateInterface.hpp>
|
virtual | ~StorageDocumentUpdateInterface () |
| Destructor. More...
|
|
virtual void | addSearchIndexTerm (const std::string &type_, const std::string &value_, const Index &position_)=0 |
| Add one occurrence of a term to the search index excluding all features of this type previously added in another update context. More...
|
|
virtual void | addSearchIndexStructure (const std::string &struct_, const IndexRange &source_, const IndexRange &sink_)=0 |
| Add a structure (relation of ordinal position ranges) in the the document for retrieval. More...
|
|
virtual void | addForwardIndexTerm (const std::string &type_, const std::string &value_, const Index &position_)=0 |
| Add one occurrence of a term to the forward index excluding all features of this type previously added in another update context. More...
|
|
virtual void | clearSearchIndexTerm (const std::string &type_)=0 |
| Clear all previous occurrencies of a term type in a document in the search index. More...
|
|
virtual void | clearSearchIndexStructure (const std::string &struct_)=0 |
| Clear all previous occurrencies of a structure in a document in the search index. More...
|
|
virtual void | clearForwardIndexTerm (const std::string &type_)=0 |
| Clear all previous occurrencies of a term type in a document in the forward index. More...
|
|
virtual void | setMetaData (const std::string &name_, const NumericVariant &value_)=0 |
| Define a meta data element of the document by name. More...
|
|
virtual void | setAttribute (const std::string &name_, const std::string &value_)=0 |
| Define an attribute (string) of the document. More...
|
|
virtual void | clearAttribute (const std::string &name_)=0 |
| Delete an attribute (string) of the document. More...
|
|
virtual void | setUserAccessRight (const std::string &username_)=0 |
| Allow a user to access the document. More...
|
|
virtual void | clearUserAccessRight (const std::string &username_)=0 |
| Disallow a user to access the document. More...
|
|
virtual void | clearUserAccessRights ()=0 |
| Clear the user rights for all users. More...
|
|
virtual void | done ()=0 |
| Closing the document definition. More...
|
|
Object to declare the items for an update of a document in the storage.
virtual strus::StorageDocumentUpdateInterface::~StorageDocumentUpdateInterface |
( |
| ) |
|
|
inlinevirtual |
virtual void strus::StorageDocumentUpdateInterface::addForwardIndexTerm |
( |
const std::string & |
type_, |
|
|
const std::string & |
value_, |
|
|
const Index & |
position_ |
|
) |
| |
|
pure virtual |
Add one occurrence of a term to the forward index excluding all features of this type previously added in another update context.
- Parameters
-
[in] | type_ | type name of the term |
[in] | value_ | value string of the term |
[in] | position_ | position of the term in the document |
- Note
- All forward index terms of this type that are not readded with this document update get removed
virtual void strus::StorageDocumentUpdateInterface::addSearchIndexStructure |
( |
const std::string & |
struct_, |
|
|
const IndexRange & |
source_, |
|
|
const IndexRange & |
sink_ |
|
) |
| |
|
pure virtual |
Add a structure (relation of ordinal position ranges) in the the document for retrieval.
- Parameters
-
[in] | struct_ | structure type name |
[in] | source_ | position range of the relation source in the document |
[in] | sink_ | position range of the relation sink in the document |
- Note
- All search index structures of this type that are not readded with this document update get removed
virtual void strus::StorageDocumentUpdateInterface::addSearchIndexTerm |
( |
const std::string & |
type_, |
|
|
const std::string & |
value_, |
|
|
const Index & |
position_ |
|
) |
| |
|
pure virtual |
Add one occurrence of a term to the search index excluding all features of this type previously added in another update context.
- Parameters
-
[in] | type_ | type name of the term |
[in] | value_ | value string of the term |
[in] | position_ | ordinal position (term count position) of the term in the document |
- Note
- All search index terms of this type that are not readded with this document update get removed
virtual void strus::StorageDocumentUpdateInterface::clearAttribute |
( |
const std::string & |
name_ | ) |
|
|
pure virtual |
Delete an attribute (string) of the document.
- Note
- Attributes are used for summarization in a query result
- Parameters
-
[in] | name_ | name of the attribute |
virtual void strus::StorageDocumentUpdateInterface::clearForwardIndexTerm |
( |
const std::string & |
type_ | ) |
|
|
pure virtual |
Clear all previous occurrencies of a term type in a document in the forward index.
- Parameters
-
[in] | type_ | type name of the terms to erase |
- Note
- The call of this function happens implicitely, if one or more features of this type are added to the update
virtual void strus::StorageDocumentUpdateInterface::clearSearchIndexStructure |
( |
const std::string & |
struct_ | ) |
|
|
pure virtual |
Clear all previous occurrencies of a structure in a document in the search index.
- Parameters
-
[in] | struct_ | type name of the structures to erase |
- Note
- The call of this function happens implicitely, if one or more features of this type are added to the update
virtual void strus::StorageDocumentUpdateInterface::clearSearchIndexTerm |
( |
const std::string & |
type_ | ) |
|
|
pure virtual |
Clear all previous occurrencies of a term type in a document in the search index.
- Parameters
-
[in] | type_ | type name of the terms to erase |
- Note
- The call of this function happens implicitely, if one or more features of this type are added to the update
virtual void strus::StorageDocumentUpdateInterface::clearUserAccessRight |
( |
const std::string & |
username_ | ) |
|
|
pure virtual |
Disallow a user to access the document.
- Parameters
-
[in] | username_ | name of the user to allow access |
virtual void strus::StorageDocumentUpdateInterface::clearUserAccessRights |
( |
| ) |
|
|
pure virtual |
Clear the user rights for all users.
virtual void strus::StorageDocumentUpdateInterface::done |
( |
| ) |
|
|
pure virtual |
Closing the document definition.
virtual void strus::StorageDocumentUpdateInterface::setAttribute |
( |
const std::string & |
name_, |
|
|
const std::string & |
value_ |
|
) |
| |
|
pure virtual |
Define an attribute (string) of the document.
- Note
- Attributes are used for summarization in a query result
- Parameters
-
[in] | name_ | name of the attribute |
[in] | value_ | value of the document attribute |
virtual void strus::StorageDocumentUpdateInterface::setMetaData |
( |
const std::string & |
name_, |
|
|
const NumericVariant & |
value_ |
|
) |
| |
|
pure virtual |
Define a meta data element of the document by name.
- Note
- Meta data are used for query restrictions and for document weights in query result ranking
-
Document meta data have to be declared in advance when creating the storage or with an alter metadata table command when no clients are running on this storage.
- Parameters
-
[in] | name_ | name of the existing meta data element |
[in] | value_ | value of the element |
virtual void strus::StorageDocumentUpdateInterface::setUserAccessRight |
( |
const std::string & |
username_ | ) |
|
|
pure virtual |
Allow a user to access the document.
- Parameters
-
[in] | username_ | name of the user to allow access |
- Note
- Adding no user means that nobody can search for the document if access control is enabled
-
The storage has to be created with "acl=yes" for enabling access control
The documentation for this class was generated from the following file: