|
xapian-core
2.0.0
|
#include <honey_docdata.h>
Inheritance diagram for HoneyDocDataTable:
Collaboration diagram for HoneyDocDataTable:Public Member Functions | |
| HoneyDocDataTable (const std::string &dbdir, bool readonly) | |
| Create a new HoneyDocDataTable object. More... | |
| HoneyDocDataTable (int fd, off_t offset_, bool readonly) | |
| std::string | get_document_data (Xapian::docid did) const |
| Get the document data for document did. More... | |
| void | add_document_data (Xapian::docid did, const std::string &data) |
| Set the document data for document did. More... | |
| void | replace_document_data (Xapian::docid did, const std::string &data) |
| Replace the document data for document did. More... | |
| bool | delete_document_data (Xapian::docid did) |
| Delete the document data for document did. More... | |
| void | readahead_for_document (Xapian::docid did) const |
Public Member Functions inherited from HoneyLazyTable | |
| HoneyLazyTable (const char *name_, const std::string &path_, bool readonly) | |
| Create a new lazy table. More... | |
| HoneyLazyTable (const char *name_, int fd, off_t offset_, bool readonly) | |
Public Member Functions inherited from HoneyTable | |
| HoneyTable (const char *, const std::string &path_, bool read_only_, bool lazy_=false) | |
| HoneyTable (const char *, int fd, off_t offset_, bool read_only_, bool lazy_=false) | |
| ~HoneyTable () | |
| bool | is_writable () const |
| int | get_flags () const |
| void | create_and_open (int flags_, const Honey::RootInfo &root_info) |
| void | open (int flags_, const Honey::RootInfo &root_info, honey_revision_number_t) |
| void | close (bool permanent) |
| const std::string & | get_path () const |
| void | add (std::string_view key, const char *val, size_t val_size, bool compressed=false) |
| void | add (std::string_view key, std::string_view val, bool compressed=false) |
| void | flush_db () |
| void | cancel (const Honey::RootInfo &, honey_revision_number_t) |
| void | commit (honey_revision_number_t, Honey::RootInfo *root_info) |
| bool | sync () |
| bool | empty () const |
| bool | get_exact_entry (std::string_view key, std::string &tag) const |
| bool | key_exists (const std::string &key) const |
| bool | del (const std::string &) |
| bool | readahead_key (const std::string &) const |
| bool | is_modified () const |
| HoneyCursor * | cursor_get () const |
| bool | exists () const |
| bool | is_open () const |
| honey_tablesize_t | get_entry_count () const |
| honey_tablesize_t | get_approx_entry_count () const |
| Return an approximation of the number of entries in the table. More... | |
| off_t | get_root () const |
| off_t | get_offset () const |
Static Public Member Functions | |
| static std::string | make_key (Xapian::docid did) |
Static Public Member Functions inherited from HoneyTable | |
| static void | throw_database_closed () |
Definition at line 31 of file honey_docdata.h.
|
inline |
Create a new HoneyDocDataTable object.
This method does not create or open the table on disk - you must call the create() or open() methods respectively!
| dbdir | The directory the honey database is stored in. |
| readonly | true if we're opening read-only, else false. |
Definition at line 47 of file honey_docdata.h.
|
inline |
Definition at line 50 of file honey_docdata.h.
|
inline |
Set the document data for document did.
If the document might already exist, use replace_document_data() instead.
| did | The docid to set the document data for. |
| data | The document data to set. |
Definition at line 74 of file honey_docdata.h.
References HoneyTable::add(), and make_key().
|
inline |
Delete the document data for document did.
| did | The docid to delete the document data for. |
Definition at line 103 of file honey_docdata.h.
References HoneyTable::del(), and make_key().
Referenced by replace_document_data().
|
inline |
Get the document data for document did.
If the document doesn't exist, the empty string is returned.
| did | The docid to set the document data for. |
Definition at line 59 of file honey_docdata.h.
References HoneyTable::get_exact_entry(), and make_key().
|
inlinestatic |
Definition at line 33 of file honey_docdata.h.
References pack_uint_preserving_sort().
Referenced by add_document_data(), delete_document_data(), get_document_data(), readahead_for_document(), and replace_document_data().
|
inline |
Definition at line 105 of file honey_docdata.h.
References make_key(), and HoneyTable::readahead_key().
|
inline |
Replace the document data for document did.
Any existing data is replaced.
| did | The docid to replace the document data for. |
| data | The document data to set. |
Definition at line 87 of file honey_docdata.h.
References HoneyTable::add(), delete_document_data(), and make_key().