RAVE
cartesian_cf_io.h File Reference

Adaptor for cartesian CF convention files. More...

#include "rave_object.h"
#include "cartesian.h"
#include "cartesianvolume.h"
#include "netcdf.h"

Go to the source code of this file.

Typedefs

typedef struct _CartesianCfIO_t CartesianCfIO_t
 Defines the cf conventions h5 adaptor for cartesian products.
 

Functions

int CartesianCfIO_setDeflateLevel (CartesianCfIO_t *self, int level)
 Sets the level of compression.
 
int CartesianCfIO_getDeflateLevel (CartesianCfIO_t *self)
 Returns the level of compression.
 
RaveCoreObjectCartesianCfIO_read (CartesianCfIO_t *self, const char *filename)
 Reads a netcdf file store in CF convention and sets the data in the resulting object.
 
int CartesianCfIO_write (CartesianCfIO_t *self, const char *filename, RaveCoreObject *obj)
 Writes a netcdf file in CF convention format.
 

Variables

RaveCoreObjectType CartesianCfIO_TYPE
 Type definition to use when creating a rave object.
 

Detailed Description

Adaptor for cartesian CF convention files.

This object supports RAVE_OBJECT_CLONE.

Author
Anders Henja (Swedish Meteorological and Hydrological Institute, SMHI)
Date
2017-11-24

Typedef Documentation

◆ CartesianCfIO_t

Defines the cf conventions h5 adaptor for cartesian products.

Function Documentation

◆ CartesianCfIO_getDeflateLevel()

int CartesianCfIO_getDeflateLevel ( CartesianCfIO_t * self)

Returns the level of compression.

Parameters
[in]self- self
Returns
level of compression where 0 means no compression and 9 is highest compression

◆ CartesianCfIO_read()

RaveCoreObject * CartesianCfIO_read ( CartesianCfIO_t * self,
const char * filename )

Reads a netcdf file store in CF convention and sets the data in the resulting object.

Parameters
[in]self- self
[in]constchar* - the netcdf filename
Returns
the read object on success otherwise NULL

◆ CartesianCfIO_setDeflateLevel()

int CartesianCfIO_setDeflateLevel ( CartesianCfIO_t * self,
int level )

Sets the level of compression.

0 which is default means no compression. 1-9 is the level of compression where 1 is lowest level and 9 is highest.

Parameters
[in]self- self
[in]level- level of compression
Returns
1 if level was within 0 - 9 otherwise false

◆ CartesianCfIO_write()

int CartesianCfIO_write ( CartesianCfIO_t * self,
const char * filename,
RaveCoreObject * obj )

Writes a netcdf file in CF convention format.

Parameters
[in]self- self
[in]constchar* - the netcdf filename
[in]obj- the object to be written
Returns
1 on success otherwise 0

Variable Documentation

◆ CartesianCfIO_TYPE

RaveCoreObjectType CartesianCfIO_TYPE
extern

Type definition to use when creating a rave object.