ifw
0.0.1-dev
|
#include <dataContext.hpp>
Public Member Functions | |
DataContext (Config &config, rad::DbAdapter &db_adapter) | |
virtual | ~DataContext () |
void | ReloadConfig () |
Reload the configuration from file and reconnect to the in-memory DB. More... | |
void | UpdateDb () |
Try to connect to the DB and update the application configuration. More... | |
DbInterface & | GetDbInterface () |
DataContext (const DataContext &)=delete | |
DataContext & | operator= (const DataContext &)=delete |
DataContext (Config &config, rad::DbAdapter &db_adapter) | |
virtual | ~DataContext () |
void | ReloadConfig () |
Reload the configuration from file and reconnect to the in-memory DB. More... | |
void | UpdateDb () |
Try to connect to the DB and update the application configuration. More... | |
DbInterface & | GetDbInterface () |
DataContext (const DataContext &)=delete | |
DataContext & | operator= (const DataContext &)=delete |
This class provide access to the application run-time data including the in-memory DB.
ctd::qatk::qapp2::DataContext::DataContext | ( | Config & | config, |
rad::DbAdapter & | db_adapter | ||
) |
This constructor uses the application configuration to initialize the adapter object to the in-memory DB. The DB adapter is then used to initialize the DB interface object that can be used to access the DB key-value pairs.
[in] | config | Reference to the application configuration. |
|
virtual |
|
delete |
ctd::qatk::qapp2::DataContext::DataContext | ( | Config & | config, |
rad::DbAdapter & | db_adapter | ||
) |
This constructor uses the application configuration to initialize the adapter object to the in-memory DB. The DB adapter is then used to initialize the DB interface object that can be used to access the DB key-value pairs.
[in] | config | Reference to the application configuration. |
|
virtual |
|
delete |
DbInterface & ctd::qatk::qapp2::DataContext::GetDbInterface | ( | ) |
DbInterface& ctd::qatk::qapp2::DataContext::GetDbInterface | ( | ) |
|
delete |
|
delete |
void ctd::qatk::qapp2::DataContext::ReloadConfig | ( | ) |
Reload the configuration from file and reconnect to the in-memory DB.
void ctd::qatk::qapp2::DataContext::ReloadConfig | ( | ) |
Reload the configuration from file and reconnect to the in-memory DB.
void ctd::qatk::qapp2::DataContext::UpdateDb | ( | ) |
Try to connect to the DB and update the application configuration.
void ctd::qatk::qapp2::DataContext::UpdateDb | ( | ) |
Try to connect to the DB and update the application configuration.