|
libdballe
7.7
|
Storage and index for measured values. More...
#include <value.h>
Public Member Functions | |
| void | clear () |
| size_t | insert (const Station &station, const LevTr &levtr, const Datetime &datetime, std::unique_ptr< wreport::Var > var, bool replace=true) |
| Insert a new value, or replace an existing one. | |
| size_t | insert (const Station &station, const LevTr &levtr, const Datetime &datetime, const wreport::Var &var, bool replace=true) |
| Insert a new value, or replace an existing one. | |
| bool | remove (const Station &station, const LevTr &levtr, const Datetime &datetime, wreport::Varcode code) |
| Remove a value. More... | |
| void | erase (size_t idx) |
| Removes a value, by index. | |
| void | query (const core::Query &q, Results< Station > &stations, Results< LevTr > &levtrs, Results< Value > &res) const |
| Query values returning the IDs. | |
| void | dump (FILE *out) const |
Public Member Functions inherited from dballe::memdb::ValueStorage< Value > | |
| void | clear () |
| size_t | element_count () const |
| Number of valid elements. More... | |
| Value * | get_checked (size_t idx) |
| const Value * | get_checked (size_t idx) const |
| std::vector< Value * >::reference | operator[] (size_t idx) |
| std::vector< Value * >::const_reference | operator[] (size_t idx) const |
| index_iterator | index_begin () const |
| index_iterator | index_end () const |
| void | copy_valptrs_to (OUTITER res) const |
| Send all T pointers to the given output iterator. | |
| void | copy_indices_to (OUTITER res) const |
| Send all T pointers to the given output iterator. | |
Protected Attributes | |
| Index< const Station * > | by_station |
| Index< const LevTr * > | by_levtr |
| Index< Date > | by_date |
Protected Attributes inherited from dballe::memdb::ValueStorage< Value > | |
| std::vector< Value * > | values |
| std::vector< size_t > | empty_slots |
Additional Inherited Members | |
Public Types inherited from dballe::memdb::ValueStorage< Value > | |
| typedef Value | value_type |
Protected Member Functions inherited from dballe::memdb::ValueStorage< Value > | |
| size_t | value_add (Value *value) |
| Add the value to the storage and return its index take ownership of the pointer memory management. | |
| void | value_remove (size_t pos) |
| Remove a value given its position. | |
Storage and index for measured values.
| bool dballe::memdb::Values::remove | ( | const Station & | station, |
| const LevTr & | levtr, | ||
| const Datetime & | datetime, | ||
| wreport::Varcode | code | ||
| ) |
Remove a value.
Returns true if found and removed, false if it was not found.
1.8.9.1