Object to declare all items for one insert/update of a document in the storage.
More...
#include <storageTransactionInterface.hpp>
Object to declare all items for one insert/update of a document in the storage.
virtual strus::StorageTransactionInterface::~StorageTransactionInterface |
( |
| ) |
|
|
inlinevirtual |
virtual bool strus::StorageTransactionInterface::commit |
( |
| ) |
|
|
pure virtual |
Insert all documents and executes all commands defined in the transaction or none if one operation fails.
- Returns
- true on success, false on error
Create one document to be inserted/replaced within this transaction.
- Parameters
-
[in] | docid_ | identifier of the document |
- Returns
- the document object
Create an interface for a document to be updated within this transaction.
- Parameters
-
[in] | docno_ | document number of the document (StorageClientInterface::documentNumber( const std::string&)) |
- Returns
- the document updater object
virtual void strus::StorageTransactionInterface::deleteDocument |
( |
const std::string & |
docid | ) |
|
|
pure virtual |
Declare a document to be removed from the storage within this transaction.
- Parameters
-
[in] | docid | document identifier (URI) |
virtual void strus::StorageTransactionInterface::deleteUserAccessRights |
( |
const std::string & |
username | ) |
|
|
pure virtual |
Declare the access rights of a user to any document to be removed from the storage within this transaction.
- Parameters
-
virtual unsigned int strus::StorageTransactionInterface::nofDocumentsAffected |
( |
| ) |
const |
|
pure virtual |
Get the number of documents affected by the last transaction in case of a successful commit.
- Returns
- the number of documents (deletes,updates,inserts)
virtual void strus::StorageTransactionInterface::rollback |
( |
| ) |
|
|
pure virtual |
Rollback of the transaction, no changes made.
virtual void strus::StorageTransactionInterface::updateDocumentFrequency |
( |
const std::string & |
type, |
|
|
const std::string & |
value, |
|
|
int |
df_change |
|
) |
| |
|
pure virtual |
Update of document frequency for features not in search index that get an implicitely stored df assigned.
- Parameters
-
[in] | type | type of the feature |
[in] | value | value of the feature |
[in] | df_change | document frequency increment/decrement for feature type/value |
- Note
- This method is useful if you want to store the document frequency for features in the forward index, that do not get a df value assigned implicitely. For example for weighting of extracted features with their occurrence and idf.
virtual void strus::StorageTransactionInterface::updateMetaData |
( |
const Index & |
docno, |
|
|
const std::string & |
varname, |
|
|
const NumericVariant & |
value |
|
) |
| |
|
pure virtual |
Update of meta data for a specific document (without creating it)
- Parameters
-
[in] | docno | document number |
[in] | varname | meta data element name to update |
[in] | value | new value of this meta data element |
The documentation for this class was generated from the following file: