#include <chert_record.h>


Public Member Functions | |
| ChertRecordTable (const string &path_, bool readonly_) | |
| Create a new table object. | |
| string | get_record (Xapian::docid did) const |
| Retrieve a document from the table. | |
| Xapian::doccount | get_doccount () const |
| Get the number of records in the table. | |
| void | replace_record (const string &data, Xapian::docid did) |
| void | delete_record (Xapian::docid did) |
| Delete a record from the table. | |
Definition at line 36 of file chert_record.h.
| ChertRecordTable::ChertRecordTable | ( | const string & | path_, | |
| bool | readonly_ | |||
| ) | [inline] |
Create a new table object.
This does not create the table on disk - the create() method must be called before the table is created on disk
This also does not open the table - the open() method must be called before use is made of the table.
| path_ | - Path at which the table is stored. | |
| readonly_ | - whether to open the table for read only access. |
Definition at line 50 of file chert_record.h.
| void ChertRecordTable::delete_record | ( | Xapian::docid | did | ) |
Delete a record from the table.
Definition at line 76 of file chert_record.cc.
References ChertTable::del(), LOGCALL_VOID, make_key(), and Xapian::Internal::str().
Referenced by ChertWritableDatabase::delete_document().
| Xapian::doccount ChertRecordTable::get_doccount | ( | ) | const |
Get the number of records in the table.
Definition at line 56 of file chert_record.cc.
References ChertTable::get_entry_count(), LOGCALL, rare, and RETURN.
Referenced by ChertDatabase::get_avlength(), and ChertDatabase::get_doccount().
| string ChertRecordTable::get_record | ( | Xapian::docid | did | ) | const |
Retrieve a document from the table.
Definition at line 43 of file chert_record.cc.
References ChertTable::get_exact_entry(), LOGCALL, make_key(), RETURN, and Xapian::Internal::str().
Referenced by ChertDocument::do_get_data().
| void ChertRecordTable::replace_record | ( | const string & | data, | |
| Xapian::docid | did | |||
| ) |
Definition at line 69 of file chert_record.cc.
References ChertTable::add(), LOGCALL_VOID, and make_key().
Referenced by ChertWritableDatabase::add_document_(), and ChertWritableDatabase::replace_document().