Base class for DataEditing algorithms.
#include <DataEditingAlgorithms.h>
|
static std::set< std::string > | initStationSet (const std::vector< std::pair< std::string, std::string > > &vecArgs, const std::string &keyword) |
|
◆ EditingBlock()
mio::EditingBlock::EditingBlock |
( |
const std::string & |
i_stationID, |
|
|
const std::vector< std::pair< std::string, std::string > > & |
vecArgs, |
|
|
const std::string & |
name, |
|
|
const Config & |
cfg |
|
) |
| |
◆ ~EditingBlock()
virtual mio::EditingBlock::~EditingBlock |
( |
| ) |
|
|
inlinevirtual |
◆ editTimeSeries() [1/2]
virtual void mio::EditingBlock::editTimeSeries |
( |
STATIONS_SET & |
vecStation | ) |
|
|
inlinevirtual |
◆ editTimeSeries() [2/2]
virtual void mio::EditingBlock::editTimeSeries |
( |
std::vector< METEO_SET > & |
vecMeteo | ) |
|
|
inlinevirtual |
Apply this editing block.
This applies the editing block for its station that has been declared in the constructor on the provided MeteoData timeseries.
- Parameters
-
vecMeteo | MeteoData timeseries for all stations |
Reimplemented in mio::EditingSwap, mio::EditingRename, mio::EditingExclude, mio::EditingKeep, mio::EditingCombine, mio::EditingMerge, mio::EditingAutoMerge, mio::EditingCopy, mio::EditingCreate, mio::EditingMetadata, mio::EditingRegFill, mio::EditingMove, and mio::EditingSplit.
◆ getName()
std::string mio::EditingBlock::getName |
( |
| ) |
const |
|
inlineprotected |
◆ initStationSet()
std::set< std::string > mio::EditingBlock::initStationSet |
( |
const std::vector< std::pair< std::string, std::string > > & |
vecArgs, |
|
|
const std::string & |
keyword |
|
) |
| |
|
staticprotected |
◆ providedIDs()
virtual std::set< std::string > mio::EditingBlock::providedIDs |
( |
| ) |
const |
|
inlinevirtual |
Get the station IDs this editing block provides based on this station.
- Returns
- a set of station IDs it provides
Reimplemented in mio::EditingMetadata.
◆ purgeIDs()
virtual std::set< std::string > mio::EditingBlock::purgeIDs |
( |
| ) |
const |
|
inlinevirtual |
Get the station IDs to purge after using them for this station ID.
- Returns
- a set of station IDs to purge after processing
◆ requiredIDs()
virtual std::set< std::string > mio::EditingBlock::requiredIDs |
( |
| ) |
const |
|
inlinevirtual |
Get the station IDs this editing block depends on for this station.
- Returns
- a set of station IDs it depends on
Reimplemented in mio::EditingMerge.
◆ skipStation()
bool mio::EditingBlock::skipStation |
( |
const std::vector< MeteoData > & |
vecMeteo | ) |
const |
|
protected |
Return true if this station ID should be skipped.
This is based on the comparison between the current station ID and the one this EditingBlock has been configured for as well as the "only" or "exclude" arguments provided by the user in the configuration file. It also checks if the mete timeseries is empty or not.
- Parameters
-
[in] | vecMeteo | timeseries for the station to inquire for |
- Returns
- true (yes, skip this station ID) or false (please, process this station ID)
◆ timeFilterFromStation()
Prepare a station that will be merged in case of time restrictions.
In order to apply time restrictions for merges, the easiest is to filter the "from" stations, one by one, to only contain data within the time restrictions periods. Then any merge type works as intented and the process is not too expensive.
- Note
- this method is only supposed to be called when !time_restrictions.empty()
- Parameters
-
[in] | vecMeteo | timeseries of the station that provides the data on the from side of merge |
- Returns
- timeseries of the "from" station only containing data in the time restrictions periods
◆ toString()
const std::string mio::EditingBlock::toString |
( |
| ) |
const |
◆ block_name
const std::string mio::EditingBlock::block_name |
|
protected |
◆ excluded_stations
const std::set<std::string> mio::EditingBlock::excluded_stations |
|
protected |
◆ kept_stations
const std::set<std::string> mio::EditingBlock::kept_stations |
|
protected |
◆ stationID
const std::string mio::EditingBlock::stationID |
|
protected |
◆ time_restrictions
const std::vector<DateRange> mio::EditingBlock::time_restrictions |
|
protected |
The documentation for this class was generated from the following files: