6 namespace persistency {
14 throwException(
"GLOBAL_TAG table already exists in this schema.",
"GLOBAL_TAG::Table::create");
18 createTable(m_schema, descr.
get());
27 return q.retrievedRows();
32 boost::posix_time::ptime& snapshotTime) {
36 std::tie(validity, snapshotTime) = row;
38 return q.retrievedRows();
45 boost::posix_time::ptime& snapshotTime) {
48 for (
const auto& row : q)
49 std::tie(validity, description, release, snapshotTime) = row;
51 return q.retrievedRows();
58 const boost::posix_time::ptime& snapshotTime,
59 const boost::posix_time::ptime& insertionTime) {
61 std::tie(name, validity, description, release, snapshotTime, insertionTime));
62 insertInTable(m_schema,
tname, dataToInsert.
get());
69 const boost::posix_time::ptime& snapshotTime,
70 const boost::posix_time::ptime& insertionTime) {
73 std::tie(validity, description, release, snapshotTime, insertionTime));
75 updateTable(m_schema,
tname, buffer);
84 throwException(
"GLOBAL_TAG_MAP table already exists in this schema.",
"GLOBAL_TAG_MAP::Table::create");
88 createTable(m_schema, descr.
get());
92 std::vector<std::tuple<std::string, std::string, std::string> >&
tags) {
98 if (std::get<1>(row) ==
"-") {
99 std::get<1>(row) =
"";
103 return q.retrievedRows();
109 std::vector<std::tuple<std::string, std::string, std::string> >&
tags) {
114 const std::vector<std::tuple<std::string, std::string, std::string> >&
tags) {
116 for (
auto row :
tags)
117 inserter.
insert(std::tuple_cat(std::tie(gtName), row));
bool select(const std::string >Name, std::vector< std::tuple< std::string, std::string, std::string > > &tags) override
bool select(const std::string &name) override
void update(const std::string &name, cond::Time_t validity, const std::string &description, const std::string &release, const boost::posix_time::ptime &snapshotTime, const boost::posix_time::ptime &insertionTime) override
static constexpr char const * tname
const coral::TableDescription & get()
GLOBAL_TAG::Table m_gtTable
void insert(const std::string &name, cond::Time_t validity, const std::string &description, const std::string &release, const boost::posix_time::ptime &snapshotTime, const boost::posix_time::ptime &insertionTime) override
Table(coral::ISchema &schema)
void insert(const P ¶ms)
GLOBAL_TAG_MAP::Table & gtMapTable() override
GTSchema(coral::ISchema &schema)
unsigned long long Time_t
const coral::AttributeList & get() const
Query & addCondition(const T &value, const std::string condition="=")
void insert(const std::string >Name, const std::vector< std::tuple< std::string, std::string, std::string > > &tags) override
Query & addOrderClause(bool ascending=true)
static constexpr char const * tname
void setColumnData(const Params ¶ms)
GLOBAL_TAG::Table & gtTable() override
GLOBAL_TAG_MAP::Table m_gtMapTable
Table(coral::ISchema &schema)
void addWhereCondition(const P ¶m, const std::string condition="=")
void throwException(const std::string &message, const std::string &methodName)