1 #ifndef DBALLE_DB_V7_STATION_H
2 #define DBALLE_DB_V7_STATION_H
5 #include <dballe/db/v7/state.h>
23 virtual bool maybe_get_id(
const StationDesc& st,
int*
id) = 0;
24 virtual void _dump(std::function<
void(
int,
int,
const Coords& coords,
const char* ident)> out) = 0;
61 virtual void get_station_vars(
int id_station, std::function<
void(std::unique_ptr<wreport::Var>)> dest) = 0;
virtual stations_t::iterator get_id(State &st, const StationDesc &desc)
Get the station ID given latitude, longitude and mobile identifier.
Cache intermediate results during a database transaction, to avoid hitting the database multiple time...
Definition: state.h:140
virtual void add_station_vars(int id_station, Record &rec)=0
Add all station variables (without attributes) to rec.
Coordinates.
Definition: types.h:337
Key/value store where keys are strings and values are wreport variables.
Definition: record.h:17
Forward declarations for public dballe/sql names.
virtual ~Station()
Instantiate a Station object for this connection.
Definition: v7/station.h:20
void dump(FILE *out)
Dump the entire contents of the table to an output stream.
virtual void get_station_vars(int id_station, std::function< void(std::unique_ptr< wreport::Var >)> dest)=0
Export station variables.
virtual stations_t::iterator obtain_id(State &st, const StationDesc &desc)=0
Get the station ID given latitude, longitude and mobile identifier.
virtual stations_t::iterator lookup_id(State &st, int id)=0
Look up a station give its ID.