xapian-core  2.0.0
Public Member Functions | List of all members
HoneyPostListTable Class Reference

#include <honey_postlisttable.h>

+ Inheritance diagram for HoneyPostListTable:
+ Collaboration diagram for HoneyPostListTable:

Public Member Functions

 HoneyPostListTable (const std::string &dbdir, bool readonly)
 Create a new HoneyPostListTable object. More...
 
 HoneyPostListTable (int fd, off_t offset_, bool readonly)
 
bool term_exists (std::string_view term) const
 
HoneyPostListopen_post_list (const HoneyDatabase *db, std::string_view term, bool need_read_pos) const
 
void get_freqs (std::string_view term, Xapian::doccount *termfreq_ptr, Xapian::termcount *collfreq_ptr) const
 
void get_used_docid_range (Xapian::doccount doccount, Xapian::docid &first, Xapian::docid &last) const
 
Xapian::termcount get_wdf_upper_bound (std::string_view term) const
 
std::string get_metadata (std::string_view key) const
 
void merge_doclen_changes (const std::map< Xapian::docid, Xapian::termcount > &changes)
 
void merge_changes (const std::string &term, const HoneyInverter::PostingChanges &changes)
 
- 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
 
HoneyCursorcursor_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
 

Additional Inherited Members

- Static Public Member Functions inherited from HoneyTable
static void throw_database_closed ()
 

Detailed Description

Definition at line 38 of file honey_postlisttable.h.

Constructor & Destructor Documentation

◆ HoneyPostListTable() [1/2]

HoneyPostListTable::HoneyPostListTable ( const std::string &  dbdir,
bool  readonly 
)
inline

Create a new HoneyPostListTable object.

This method does not create or open the table on disk - you must call the create() or open() methods respectively!

Parameters
dbdirThe directory the honey database is stored in.
readonlytrue if we're opening read-only, else false.

Definition at line 48 of file honey_postlisttable.h.

◆ HoneyPostListTable() [2/2]

HoneyPostListTable::HoneyPostListTable ( int  fd,
off_t  offset_,
bool  readonly 
)
inline

Definition at line 51 of file honey_postlisttable.h.

Member Function Documentation

◆ get_freqs()

void HoneyPostListTable::get_freqs ( std::string_view  term,
Xapian::doccount termfreq_ptr,
Xapian::termcount collfreq_ptr 
) const

◆ get_metadata()

std::string HoneyPostListTable::get_metadata ( std::string_view  key) const
inline

Definition at line 72 of file honey_postlisttable.h.

References HoneyTable::get_exact_entry().

Referenced by HoneyDatabase::get_metadata().

◆ get_used_docid_range()

void HoneyPostListTable::get_used_docid_range ( Xapian::doccount  doccount,
Xapian::docid first,
Xapian::docid last 
) const

◆ get_wdf_upper_bound()

Xapian::termcount HoneyPostListTable::get_wdf_upper_bound ( std::string_view  term) const

◆ merge_changes()

void HoneyPostListTable::merge_changes ( const std::string &  term,
const HoneyInverter::PostingChanges changes 
)
inline

◆ merge_doclen_changes()

void HoneyPostListTable::merge_doclen_changes ( const std::map< Xapian::docid, Xapian::termcount > &  changes)
inline

Definition at line 79 of file honey_postlisttable.h.

Referenced by HoneyInverter::flush_doclengths().

◆ open_post_list()

HoneyPostList * HoneyPostListTable::open_post_list ( const HoneyDatabase db,
std::string_view  term,
bool  need_read_pos 
) const

Definition at line 39 of file honey_postlisttable.cc.

References Assert, Honey::make_postingchunk_key(), and term.

Referenced by HoneyDatabase::open_leaf_post_list().

◆ term_exists()

bool HoneyPostListTable::term_exists ( std::string_view  term) const
inline

The documentation for this class was generated from the following files: