CernVM-FS
2.12.0
|
#include <history_sql.h>
Public Member Functions | |
History::Tag | RetrieveTag () const |
A mixin that allows to inject the RetrieveTag() method if it is needed in an SQL query subclass.
This allows us to orchestrate specific functionality in those classes as we need it, without relying on multiple inheritance. Otherwise one would inherit from sqlite::Sql more than once when inheriting from more than one of those mixin classes in a query subclass. In contrast, the mixins produce a clear (single) inheritance graph for each of the derived classes by chaining the functionality as seen below.
Example: class SqlListRollbackTags : public SqlRetrieveTag<SqlRollback<SqlHistory>> {}
´|` |
´|` |
Note: MixinT needs to be eventually derived from sqlite::Sql as it uses Sql::Retrieve...() methods to extract information from SQLite rows.
MixinT | the class that should gain RetrieveTag()'s functionality |
Definition at line 96 of file history_sql.h.
|
inline |
Retrieves a tag from a database row See SqlHistory::db_fields for a listing of the used SQLite data fields
Definition at line 104 of file history_sql.h.