1#ifndef DBALLE_DB_V7_INTERNALS_H
2#define DBALLE_DB_V7_INTERNALS_H
4#include <wreport/var.h>
12struct AttributeList :
public std::vector<std::pair<wreport::Varcode, const char*>>
16 push_back(std::make_pair(code, value));
22 for (const_iterator i = begin(); i != end(); ++i)
23 if (i->first == code)
return i->second;
33 const char* res =
nullptr;
34 for (iterator i = begin(); i != end(); ++i)
43 while (!empty() && back().second ==
nullptr)
Store a list of attributes to be inserted/updated in the database.
Definition: internals.h:13
const char * pop(wreport::Varcode code)
Get a value by code, returns nullptr if not found, removes it from the AttributeList.
Definition: internals.h:31
const char * get(wreport::Varcode code) const
Get a value by code, returns nullptr if not found.
Definition: internals.h:20