WSL/SLF GitLab Repository

Commit 33d58293 authored by Mathias Bavay's avatar Mathias Bavay
Browse files

very minor code cleanup, some comments were wrong and have been fixed, a wrong...

very minor code cleanup, some comments were wrong and have been fixed, a wrong debug message has been fixed (in toString())
parent 633ff3ac
......@@ -206,7 +206,7 @@ void Config::parseFile(const std::string& filename)
}
std::reverse(import_after.begin(), import_after.end());
while(!import_after.empty()) {
while (!import_after.empty()) {
const string file_name = import_after.back();
addFile(file_name);
import_after.pop_back();
......
......@@ -207,7 +207,7 @@ class IOManager {
void add_to_points_cache(const Date& i_date, const METEO_SET& vecMeteo);
/**
* @brief Clear the point cache. All resampled values are dismissed, will need to be recalculated.
* @brief Clear the all cache. All raw, filtered and resampled values are dismissed, will need to be re-read and/or recalculated.
*/
void clear_cache();
......
......@@ -318,7 +318,7 @@ const std::string TimeSeriesManager::toString() const {
os << dataGenerator.toString();
os << "RawBuffer:\n" << raw_buffer.toString();
os << "Filteredcache:\n" << raw_buffer.toString();
os << "Filteredcache:\n" << filtered_cache.toString();
//display point_cache
size_t count=0;
......
......@@ -135,7 +135,7 @@ class TimeSeriesManager {
* @brief Clear the point cache. All resampled values are dismissed, will need to be recalculated.
*/
void clear_cache();
private:
void setDfltBufferProperties();
void fill_filtered_cache();
......
......@@ -38,9 +38,7 @@ namespace mio {
class AnetzData{
public:
AnetzData()
: nrOfAnetzStations(3), nrOfCoefficients(3), coeffs(3, IOUtils::nodata), anetzstations(3, "")
{
}
: nrOfAnetzStations(3), nrOfCoefficients(3), coeffs(3, IOUtils::nodata), anetzstations(3, "") {}
AnetzData(const size_t& nr_anetz,
const std::string& i_anetz1, const std::string& i_anetz2, const std::string& i_anetz3,
......
......@@ -337,8 +337,7 @@ void SMETIO::copy_data(const smet::SMETReader& myreader,
size_t current_index = 0; //index to vec_data
double previous_ts = IOUtils::nodata;
for (size_t ii = 0; ii<nr_of_lines; ii++){
vecMeteo.push_back(md);
MeteoData& tmp_md = vecMeteo.back();
MeteoData tmp_md(md);
if (timestamp_present)
IOUtils::convertString(tmp_md.date, timestamps[ii], current_timezone);
......@@ -390,6 +389,7 @@ void SMETIO::copy_data(const smet::SMETReader& myreader,
}
previous_ts = tmp_md.date.getJulian();
vecMeteo.push_back(tmp_md);
}
}
......
......@@ -255,7 +255,7 @@ size_t SMETCommon::readLineToVec(const std::string& line_in, std::vector<std::st
iss >> std::skipws >> tmp_string;
if (!tmp_string.empty()) {
vec_string.push_back(tmp_string);
vec_string.push_back( tmp_string );
}
tmp_string.clear();
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment