rad  3.0.0
dataContext.hpp
Go to the documentation of this file.
1 
9 #ifndef HELLOMAL_DATA_CONTEXT_HPP_
10 #define HELLOMAL_DATA_CONTEXT_HPP_
11 
12 #include "config.hpp"
13 #include "dbInterface.hpp"
14 
15 namespace hellomal {
16 
21 class DataContext {
22  public:
32  DataContext(Config& config, rad::DbAdapter& db_adapter);
33 
37  virtual ~DataContext();
38 
42  void ReloadConfig();
43 
47  void UpdateDb();
48 
53 
54  DataContext(const DataContext&) = delete;
55  DataContext& operator=(const DataContext&) = delete;
56 
57  private:
58  Config& m_config;
59  rad::DbAdapter& m_runtime_db;
60  DbInterface m_db_interface;
61 };
62 
63 } // namespace hellomal
64 
65 #endif // HELLOMAL_DATA_CONTEXT_HPP_
hellomal::DataContext::~DataContext
virtual ~DataContext()
Definition: dataContext.cpp:27
hellomal::DataContext::operator=
DataContext & operator=(const DataContext &)=delete
Disable copy constructor.
hellomal::DataContext
Definition: dataContext.hpp:21
hellomal::DataContext::ReloadConfig
void ReloadConfig()
Definition: dataContext.cpp:31
hellomal::DbInterface
Definition: dbInterface.hpp:34
dbInterface.hpp
DbInterface class header file.
hellomal
Definition: actionMgr.cpp:21
config.hpp
Config class header file.
hellomal::DataContext::DataContext
DataContext(Config &config, rad::DbAdapter &db_adapter)
Definition: dataContext.cpp:19
hellomal::DataContext::DataContext
DataContext(const DataContext &)=delete
hellomal::DataContext::GetDbInterface
DbInterface & GetDbInterface()
Definition: dataContext.cpp:55
hellomal::Config
Definition: config.hpp:40
hellomal::DataContext::UpdateDb
void UpdateDb()
Definition: dataContext.cpp:38
rad::DbAdapter
Definition: dbAdapter.hpp:29