MeteoIODoc 20241221.207bde49
mio::ncFiles Class Reference

#include <NetCDFIO.h>

Public Types

enum  Mode { READ , WRITE }
 

Public Member Functions

 ncFiles (const std::string &filename, const Mode &mode, const Config &cfg, const std::string &schema_name, const bool &i_debug=false)
 
 ncFiles (const ncFiles &c)
 
ncFilesoperator= (const ncFiles &c)
 
 ~ncFiles ()
 
std::pair< Date, DategetDateRange () const
 
std::set< size_t > getParams () const
 
std::vector< DategetTimestamps () const
 
Grid2DObject read2DGrid (const size_t &param, const Date &date)
 
Grid2DObject read2DGrid (const std::string &varname)
 
std::vector< double > readPointsIn2DGrid (const size_t &param, const Date &date, const std::vector< std::pair< size_t, size_t > > &Pts)
 
void write2DGrid (const Grid2DObject &grid_in, ncpp::nc_variable &var, const Date &date)
 
void write2DGrid (const Grid2DObject &grid_in, size_t param, std::string param_name, const Date &date)
 
void writeMeteo (const std::vector< std::vector< MeteoData > > &vecMeteo, const size_t &station_idx=IOUtils::npos)
 
std::vector< StationDatareadStationData ()
 
std::vector< std::vector< MeteoData > > readMeteoData (const Date &dateStart, const Date &dateEnd)
 
bool hasDimension (const size_t &dim) const
 

Member Enumeration Documentation

◆ Mode

Enumerator
READ 
WRITE 

Constructor & Destructor Documentation

◆ ncFiles() [1/2]

mio::ncFiles::ncFiles ( const std::string &  filename,
const Mode mode,
const Config cfg,
const std::string &  schema_name,
const bool &  i_debug = false 
)

◆ ncFiles() [2/2]

mio::ncFiles::ncFiles ( const ncFiles c)

◆ ~ncFiles()

mio::ncFiles::~ncFiles ( )

Member Function Documentation

◆ getDateRange()

std::pair< Date, Date > mio::ncFiles::getDateRange ( ) const

◆ getParams()

std::set< size_t > mio::ncFiles::getParams ( ) const

◆ getTimestamps()

std::vector< Date > mio::ncFiles::getTimestamps ( ) const

◆ hasDimension()

bool mio::ncFiles::hasDimension ( const size_t &  dim) const

◆ operator=()

ncFiles & mio::ncFiles::operator= ( const ncFiles c)

◆ read2DGrid() [1/2]

Grid2DObject mio::ncFiles::read2DGrid ( const size_t &  param,
const Date date 
)

◆ read2DGrid() [2/2]

Grid2DObject mio::ncFiles::read2DGrid ( const std::string &  varname)

◆ readMeteoData()

std::vector< std::vector< MeteoData > > mio::ncFiles::readMeteoData ( const Date dateStart,
const Date dateEnd 
)

◆ readPointsIn2DGrid()

std::vector< double > mio::ncFiles::readPointsIn2DGrid ( const size_t &  param,
const Date date,
const std::vector< std::pair< size_t, size_t > > &  Pts 
)

◆ readStationData()

std::vector< StationData > mio::ncFiles::readStationData ( )

◆ write2DGrid() [1/2]

void mio::ncFiles::write2DGrid ( const Grid2DObject grid_in,
ncpp::nc_variable &  var,
const Date date 
)

◆ write2DGrid() [2/2]

void mio::ncFiles::write2DGrid ( const Grid2DObject grid_in,
size_t  param,
std::string  param_name,
const Date date 
)

◆ writeMeteo()

void mio::ncFiles::writeMeteo ( const std::vector< std::vector< MeteoData > > &  vecMeteo,
const size_t &  station_idx = IOUtils::npos 
)

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