| 
    xapian-core
    1.4.29
    
   | 
 
#include <glass_values.h>
 Collaboration diagram for GlassValueManager:Private Member Functions | |
| void | add_value (Xapian::docid did, Xapian::valueno slot, const std::string &val) | 
| void | remove_value (Xapian::docid did, Xapian::valueno slot) | 
| Xapian::docid | get_chunk_containing_did (Xapian::valueno slot, Xapian::docid did, std::string &chunk) const | 
| void | get_value_stats (Xapian::valueno slot) const | 
| Get the statistics for value slot slot.  More... | |
| void | get_value_stats (Xapian::valueno slot, ValueStats &stats) const | 
Private Attributes | |
| Xapian::valueno | mru_slot | 
| The value number for the most recently used value statistics.  More... | |
| ValueStats | mru_valstats | 
| The most recently used value statistics.  More... | |
| GlassPostListTable * | postlist_table | 
| GlassTermListTable * | termlist_table | 
| std::map< Xapian::docid, std::string > | slots | 
| std::map< Xapian::valueno, std::map< Xapian::docid, std::string > > | changes | 
| AutoPtr< GlassCursor > | cursor | 
Definition at line 77 of file glass_values.h.
      
  | 
  inline | 
Create a new GlassValueManager object.
Definition at line 114 of file glass_values.h.
| void GlassValueManager::add_document | ( | Xapian::docid | did, | 
| const Xapian::Document & | doc, | ||
| std::map< Xapian::valueno, ValueStats > & | value_stats | ||
| ) | 
Definition at line 351 of file glass_values.cc.
References Assert, ValueStats::freq, Xapian::ValueIterator::get_valueno(), ValueStats::lower_bound, pack_uint(), ValueStats::upper_bound, Xapian::Document::values_begin(), and Xapian::Document::values_end().
Referenced by GlassWritableDatabase::add_document_().
      
  | 
  private | 
Definition at line 133 of file glass_values.cc.
      
  | 
  inline | 
Definition at line 170 of file glass_values.h.
Referenced by GlassDatabase::cancel().
| void GlassValueManager::delete_document | ( | Xapian::docid | did, | 
| std::map< Xapian::valueno, ValueStats > & | value_stats | ||
| ) | 
Definition at line 403 of file glass_values.cc.
References Assert, AssertRelParanoid, ValueStats::freq, ValueStats::lower_bound, make_slot_key(), unpack_uint(), and ValueStats::upper_bound.
Referenced by GlassWritableDatabase::delete_document().
| void GlassValueManager::get_all_values | ( | std::map< Xapian::valueno, std::string > & | values, | 
| Xapian::docid | did | ||
| ) | const | 
Definition at line 493 of file glass_values.cc.
References Assert, make_slot_key(), GlassTable::throw_database_closed(), and unpack_uint().
Referenced by GlassDocument::do_get_all_values().
      
  | 
  private | 
Definition at line 154 of file glass_values.cc.
References LOGCALL, Glass::make_valuechunk_key(), RETURN, unpack_uint(), and unpack_uint_preserving_sort().
| string GlassValueManager::get_value | ( | Xapian::docid | did, | 
| Xapian::valueno | slot | ||
| ) | const | 
Definition at line 472 of file glass_values.cc.
References Glass::ValueChunkReader::skip_to().
Referenced by GlassDocument::do_get_value().
      
  | 
  inline | 
Definition at line 137 of file glass_values.h.
References ValueStats::freq.
Referenced by GlassDatabase::get_value_freq().
      
  | 
  inline | 
Definition at line 142 of file glass_values.h.
References ValueStats::lower_bound.
Referenced by GlassDatabase::get_value_lower_bound().
      
  | 
  private | 
Get the statistics for value slot slot.
Definition at line 528 of file glass_values.cc.
References Xapian::BAD_VALUENO, and LOGCALL_VOID.
      
  | 
  private | 
Definition at line 538 of file glass_values.cc.
References Assert, ValueStats::clear(), ValueStats::freq, LOGCALL_VOID, ValueStats::lower_bound, make_valuestats_key(), unpack_string(), unpack_uint(), and ValueStats::upper_bound.
      
  | 
  inline | 
Definition at line 147 of file glass_values.h.
References ValueStats::upper_bound.
Referenced by GlassDatabase::get_value_upper_bound().
      
  | 
  inline | 
Definition at line 166 of file glass_values.h.
Referenced by GlassDatabase::apply(), and GlassWritableDatabase::has_uncommitted_changes().
| void GlassValueManager::merge_changes | ( | ) | 
Definition at line 324 of file glass_values.cc.
References make_slot_key(), and Glass::ValueUpdater::update().
Referenced by GlassWritableDatabase::open_value_list(), and GlassDatabase::set_revision_number().
      
  | 
  private | 
Definition at line 144 of file glass_values.cc.
| void GlassValueManager::replace_document | ( | Xapian::docid | did, | 
| const Xapian::Document & | doc, | ||
| std::map< Xapian::valueno, ValueStats > & | value_stats | ||
| ) | 
Definition at line 447 of file glass_values.cc.
References Xapian::Document::get_docid(), and Xapian::Document::internal.
Referenced by GlassWritableDatabase::replace_document().
      
  | 
  inline | 
Ignore any old cached valuestats.
Definition at line 161 of file glass_values.h.
References Xapian::BAD_VALUENO.
Referenced by GlassDatabase::modifications_failed(), and GlassDatabase::open_tables().
| void GlassValueManager::set_value_stats | ( | std::map< Xapian::valueno, ValueStats > & | value_stats | ) | 
Write the updated statistics to the table.
If the freq member of the statistics for a particular slot is 0, the statistics for that slot will be cleared.
| value_stats | The statistics to set. | 
Definition at line 574 of file glass_values.cc.
References Xapian::BAD_VALUENO, ValueStats::freq, LOGCALL_VOID, ValueStats::lower_bound, make_valuestats_key(), pack_string(), pack_uint(), and ValueStats::upper_bound.
Referenced by GlassWritableDatabase::apply().
      
  | 
  private | 
Definition at line 94 of file glass_values.h.
      
  | 
  mutableprivate | 
Definition at line 96 of file glass_values.h.
      
  | 
  mutableprivate | 
The value number for the most recently used value statistics.
Set to Xapian::BAD_VALUENO if no value statistics are currently cached.
Definition at line 83 of file glass_values.h.
      
  | 
  mutableprivate | 
The most recently used value statistics.
Definition at line 86 of file glass_values.h.
      
  | 
  private | 
Definition at line 88 of file glass_values.h.
      
  | 
  private | 
Definition at line 92 of file glass_values.h.
      
  | 
  private | 
Definition at line 90 of file glass_values.h.