libdballe 9.6
Classes | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
dballe::db::BaseExplorer< Station > Class Template Reference

Classes

class  Update
 

Public Member Functions

 BaseExplorer (const std::string &pathname)
 
 BaseExplorer (const BaseExplorer &)=delete
 
 BaseExplorer (BaseExplorer &&)=delete
 
BaseExploreroperator= (const BaseExplorer &)=delete
 
BaseExploreroperator= (BaseExplorer &&)=delete
 
const dballe::Queryget_filter () const
 Get the current filter.
 
void set_filter (const dballe::Query &query)
 Set a new filter, updating all browsing data.
 
Update rebuild ()
 Throw away all cached data and rebuild the explorer from scratch.
 
Update update ()
 Merge new data into the explorer.
 
const dballe::db::BaseSummary< Station > & global_summary () const
 Get a reference to the global summary.
 
const dballe::db::BaseSummary< Station > & active_summary () const
 Get a reference to the summary for the current filter.
 
void to_json (core::JSONWriter &writer) const
 Export the explorer to JSON.
 

Protected Member Functions

void commit ()
 Commit changes to disk.
 
void update_active_summary ()
 Regenerate _active_summary based on filter.
 

Protected Attributes

std::shared_ptr< dballe::db::BaseSummary< Station > > _global_summary
 Summary of the whole database.
 
dballe::core::Query filter
 Currently active filter.
 
std::shared_ptr< dballe::db::BaseSummary< Station > > _active_summary
 Summary of active_filter.
 

Member Function Documentation

◆ rebuild()

template<typename Station >
Update dballe::db::BaseExplorer< Station >::rebuild ( )

Throw away all cached data and rebuild the explorer from scratch.

Use this when you suspect that the database has been externally modified


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