1 #ifndef DBA_MEMDB_STATION_H 2 #define DBA_MEMDB_STATION_H 4 #include <dballe/memdb/valuestorage.h> 5 #include <dballe/memdb/index.h> 24 template<
typename T>
struct Results;
36 Station(
size_t id,
const Coords& coords,
const std::string& report)
37 : id(
id), coords(coords), mobile(
false), report(report) {}
38 Station(
size_t id,
double lat,
double lon,
const std::string& report)
39 : id(
id), coords(lat, lon), mobile(
false), report(report) {}
42 Station(
size_t id,
const Coords& coords,
const std::string& ident,
const std::string& report)
43 : id(
id), coords(coords), mobile(
true), ident(ident), report(report) {}
44 Station(
size_t id,
double lat,
double lon,
const std::string& ident,
const std::string& report)
45 : id(
id), coords(lat, lon), mobile(
true), ident(ident), report(report) {}
55 bool operator<(
const Station& o)
const {
return id < o.id; }
56 bool operator>(
const Station& o)
const {
return id > o.id; }
57 bool operator==(
const Station& o)
const {
return id == o.id; }
58 bool operator!=(
const Station& o)
const {
return id != o.id; }
74 size_t obtain_fixed(
const Coords& coords,
const std::string& report,
bool create=
true);
77 size_t obtain_mobile(
const Coords& coords,
const std::string& ident,
const std::string& report,
bool create=
true);
80 size_t obtain(
const Record& rec,
bool create=
true);
88 void dump(FILE* out)
const;
Store an array of physical data all on the same level.
Definition: context.h:44
Definition: mem/cursor.h:14
Storage for related physical data.
Definition: msg.h:133
Coordinates.
Definition: types.h:320
Key/value store where keys are strings and values are wreport variables.
Definition: record.h:16
Standard dballe::Query implementation.
Definition: core/query.h:29
Copyright (C) 2008–2010 ARPA-SIM urpsim@smr.arpa.emr.it
Definition: cmdline.h:17
Station information.
Definition: memdb/station.h:27
Storage and index for station information.
Definition: memdb/station.h:62
Definition: memdb/levtr.h:16