1 #ifndef DBALLE_DB_V7_DRIVER_H 2 #define DBALLE_DB_V7_DRIVER_H 5 #include <dballe/db/defs.h> 7 #include <dballe/db/v7/state.h> 8 #include <dballe/db/v7/data.h> 9 #include <wreport/var.h> 19 struct StationQueryBuilder;
20 struct DataQueryBuilder;
21 struct SummaryQueryBuilder;
47 virtual std::unique_ptr<v7::Data>
create_data() = 0;
Definition: v7/qbuilder.h:81
Definition: v7/qbuilder.h:124
void create_tables(db::Format format)
Create all missing tables for a DB with the given format.
virtual void run_station_data_query(const v7::DataQueryBuilder &qb, std::function< void(int id_station, const StationDesc &station, int id_data, std::unique_ptr< wreport::Var > var)>)=0
Run a station data query, iterating on the resulting variables.
virtual std::unique_ptr< v7::LevTr > create_levtr()=0
Precompiled queries to manipulate the levtr table.
virtual void remove_all_v7()
Empty all tables for V7 databases, assuming that they exist, without touching the repinfo table...
Forward declarations for public dballe/sql names.
Copyright (C) 2008–2010 ARPA-SIM urpsim@smr.arpa.emr.it
Definition: cmdline.h:17
void remove_all(db::Format format)
Empty all tables for a DB with the given format.
virtual void run_station_query(const v7::StationQueryBuilder &qb, std::function< void(int id_station, const StationDesc &station)>)=0
Run a station query, iterating on the resulting stations.
Range of datetimes.
Definition: types.h:272
virtual void vacuum_v7()=0
Perform database cleanup/maintenance on v7 databases.
virtual void run_summary_query(const v7::SummaryQueryBuilder &qb, std::function< void(int id_station, const StationDesc &station, int id_levtr, wreport::Varcode code, const DatetimeRange &datetime, size_t size)>)=0
Run a summary query, iterating on the resulting variables.
virtual void run_data_query(const v7::DataQueryBuilder &qb, std::function< void(int id_station, const StationDesc &station, int id_levtr, const Datetime &datetime, int id_data, std::unique_ptr< wreport::Var > var)>)=0
Run a data query, iterating on the resulting variables.
Date and time.
Definition: types.h:158
virtual std::unique_ptr< v7::StationData > create_station_data()=0
Precompiled queries to manipulate the data table.
virtual std::unique_ptr< v7::Data > create_data()=0
Precompiled queries to manipulate the data table.
virtual std::unique_ptr< v7::Repinfo > create_repinfo()=0
Precompiled queries to manipulate the repinfo table.
virtual void create_tables_v7()=0
Create all missing tables for V7 databases.
virtual void delete_tables_v7()=0
Delete all existing tables for V7 databases.
virtual std::unique_ptr< v7::Station > create_station()=0
Precompiled queries to manipulate the station table.
static std::unique_ptr< Driver > create(dballe::sql::Connection &conn)
Create a Driver for this connection.
void delete_tables(db::Format format)
Delete all existing tables for a DB with the given format.
Definition: v7/driver.h:26
Definition: v7/qbuilder.h:91