libdballe  6.8
Public Member Functions | Protected Attributes
dballe::memdb::StationValues Class Reference

Storage and index for station information. More...

#include <stationvalue.h>

Inheritance diagram for dballe::memdb::StationValues:
dballe::memdb::ValueStorage< StationValue >

Public Member Functions

void clear ()
 
bool has_variables_for (const Station &station) const
 
const StationValueget (const Station &station, wreport::Varcode code) const
 
size_t insert (const Station &station, std::auto_ptr< wreport::Var > var, bool replace=true)
 Insert a new value, or replace an existing one for the same station.
 
size_t insert (const Station &station, const wreport::Var &var, bool replace=true)
 Insert a new value, or replace an existing one for the same station.
 
bool remove (const Station &station, wreport::Varcode code)
 Remove a value. More...
 
void fill_record (const Station &station, Record &rec) const
 Fill a record with all the variables for this station.
 
void fill_msg (const Station &station, msg::Context &ctx) const
 Fill a message context with all the variables for this station.
 
void query (const Record &rec, Results< Station > &stations, Results< StationValue > &res) const
 Query values for the given stations.
 
void dump (FILE *out) const
 
- Public Member Functions inherited from dballe::memdb::ValueStorage< StationValue >
void clear ()
 
size_t element_count () const
 Number of valid elements. More...
 
StationValueget_checked (size_t idx)
 
const StationValueget_checked (size_t idx) const
 
std::vector< StationValue * >::reference operator[] (size_t idx)
 
std::vector< StationValue * >::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
 
- Protected Attributes inherited from dballe::memdb::ValueStorage< StationValue >
std::vector< StationValue * > values
 
std::vector< size_t > empty_slots
 

Additional Inherited Members

- Public Types inherited from dballe::memdb::ValueStorage< StationValue >
typedef StationValue value_type
 
- Protected Member Functions inherited from dballe::memdb::ValueStorage< StationValue >
size_t value_add (StationValue *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.
 

Detailed Description

Storage and index for station information.

Member Function Documentation

bool dballe::memdb::StationValues::remove ( const Station station,
wreport::Varcode  code 
)

Remove a value.

Returns true if found and removed, false if it was not found.


The documentation for this class was generated from the following file: