10 #ifndef _STRUS_STORAGE_TRANSACTION_INTERFACE_HPP_INCLUDED
11 #define _STRUS_STORAGE_TRANSACTION_INTERFACE_HPP_INCLUDED
14 #include "strus/numericVariant.hpp"
20 class StorageDocumentInterface;
22 class StorageDocumentUpdateInterface;
44 const Index& docno_)=0;
49 const std::string& docid)=0;
54 const std::string& username)=0;
62 const std::string& varname,
63 const NumericVariant& value)=0;
int32_t Index
Number type generally used for locally counted indices.
Definition: index.hpp:29
virtual StorageDocumentUpdateInterface * createDocumentUpdate(const Index &docno_)=0
Create an interface for a document to be updated within this transaction.
virtual unsigned int nofDocumentsAffected() const =0
Get the number of documents affected by the last transaction in case of a successful commit...
virtual void deleteUserAccessRights(const std::string &username)=0
Declare the access rights of a user to any document to be removed from the storage within this transa...
Object to declare all items for one insert/replace of a document in the storage.
Definition: storageDocumentInterface.hpp:21
Object to declare all items for one insert/update of a document in the storage.
Definition: storageTransactionInterface.hpp:26
virtual void deleteDocument(const std::string &docid)=0
Declare a document to be removed from the storage within this transaction.
Interface for contructing a document for inserting it into the storage.
virtual ~StorageTransactionInterface()
Destructor.
Definition: storageTransactionInterface.hpp:31
virtual bool commit()=0
Insert all documents and executes all commands defined in the transaction or none if one operation fa...
virtual void updateDocumentFrequency(const std::string &type, const std::string &value, int df_change)=0
Update of document frequency for features not in search index that get an implicitely stored df assig...
virtual void rollback()=0
Rollback of the transaction, no changes made.
virtual void updateMetaData(const Index &docno, const std::string &varname, const NumericVariant &value)=0
Update of meta data for a specific document (without creating it)
virtual StorageDocumentInterface * createDocument(const std::string &docid_)=0
Create one document to be inserted/replaced within this transaction.
Object to declare the items for an update of a document in the storage.
Definition: storageDocumentUpdateInterface.hpp:21