MBDyn-1.7.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups
NcFile Class Reference

#include <netcdfcpp.h>

Collaboration diagram for NcFile:

Public Types

enum  FileMode { ReadOnly, Write, Replace, New }
 
enum  FileFormat {
  Classic, Offset64Bits, Netcdf4, Netcdf4Classic,
  BadFormat
}
 
enum  FillMode { Fill = 0, NoFill = 0x100, Bad }
 

Public Member Functions

virtual ~NcFile (void)
 
 NcFile (const char *path, FileMode=ReadOnly, size_t *bufrsizeptr=NULL, size_t initialsize=0, FileFormat=Classic)
 
NcBool is_valid (void) const
 
int num_dims (void) const
 
int num_vars (void) const
 
int num_atts (void) const
 
NcDimget_dim (NcToken) const
 
NcVarget_var (NcToken) const
 
NcAttget_att (NcToken) const
 
NcDimget_dim (int) const
 
NcVarget_var (int) const
 
NcAttget_att (int) const
 
NcDimrec_dim (void) const
 
virtual NcDimadd_dim (NcToken dimname, long dimsize)
 
virtual NcDimadd_dim (NcToken dimname)
 
virtual NcVaradd_var (NcToken varname, NcType type, const NcDim *dim0=0, const NcDim *dim1=0, const NcDim *dim2=0, const NcDim *dim3=0, const NcDim *dim4=0)
 
virtual NcVaradd_var (NcToken varname, NcType type, int ndims, const NcDim **dims)
 
NcBool add_att (NcToken attname, char)
 
NcBool add_att (NcToken attname, ncbyte)
 
NcBool add_att (NcToken attname, short)
 
NcBool add_att (NcToken attname, long)
 
NcBool add_att (NcToken attname, int)
 
NcBool add_att (NcToken attname, float)
 
NcBool add_att (NcToken attname, double)
 
NcBool add_att (NcToken attname, const char *)
 
NcBool add_att (NcToken attname, int, const char *)
 
NcBool add_att (NcToken attname, int, const ncbyte *)
 
NcBool add_att (NcToken attname, int, const short *)
 
NcBool add_att (NcToken attname, int, const long *)
 
NcBool add_att (NcToken attname, int, const int *)
 
NcBool add_att (NcToken attname, int, const float *)
 
NcBool add_att (NcToken attname, int, const double *)
 
NcBool set_fill (FillMode=Fill)
 
FillMode get_fill (void) const
 
FileFormat get_format (void) const
 
NcBool sync (void)
 
NcBool close (void)
 
NcBool abort (void)
 
NcBool define_mode (void)
 
NcBool data_mode (void)
 
int id (void) const
 

Protected Attributes

int the_id
 
int in_define_mode
 
FillMode the_fill_mode
 
NcDim ** dimensions
 
NcVar ** variables
 
NcVarglobalv
 

Detailed Description

Definition at line 27 of file netcdfcpp.h.

Member Enumeration Documentation

Enumerator
Classic 
Offset64Bits 
Netcdf4 
Netcdf4Classic 
BadFormat 

Definition at line 40 of file netcdfcpp.h.

40  {
41  Classic, // netCDF classic format (i.e. version 1 format)
42  Offset64Bits, // netCDF 64-bit offset format
43  Netcdf4, // netCDF-4 using HDF5 format
44  Netcdf4Classic, // netCDF-4 using HDF5 format using only netCDF-3 calls
45  BadFormat
46  };
Enumerator
ReadOnly 
Write 
Replace 
New 

Definition at line 33 of file netcdfcpp.h.

33  {
34  ReadOnly, // file exists, open read-only
35  Write, // file exists, open for writing
36  Replace, // create new file, even if already exists
37  New // create new file, fail if already exists
38  };
Enumerator
Fill 
NoFill 
Bad 

Definition at line 98 of file netcdfcpp.h.

98  {
99  Fill = NC_FILL, // prefill (default)
100  NoFill = NC_NOFILL, // don't prefill
101  Bad
102  };

Constructor & Destructor Documentation

virtual NcFile::~NcFile ( void  )
virtual
NcFile::NcFile ( const char *  path,
FileMode  = ReadOnly,
size_t *  bufrsizeptr = NULL,
size_t  initialsize = 0,
FileFormat  = Classic 
)

Member Function Documentation

NcBool NcFile::abort ( void  )
NcBool NcFile::add_att ( NcToken  attname,
char   
)
NcBool NcFile::add_att ( NcToken  attname,
ncbyte   
)
NcBool NcFile::add_att ( NcToken  attname,
short   
)
NcBool NcFile::add_att ( NcToken  attname,
long   
)
NcBool NcFile::add_att ( NcToken  attname,
int   
)
NcBool NcFile::add_att ( NcToken  attname,
float   
)
NcBool NcFile::add_att ( NcToken  attname,
double   
)
NcBool NcFile::add_att ( NcToken  attname,
const char *   
)
NcBool NcFile::add_att ( NcToken  attname,
int  ,
const char *   
)
NcBool NcFile::add_att ( NcToken  attname,
int  ,
const ncbyte *   
)
NcBool NcFile::add_att ( NcToken  attname,
int  ,
const short *   
)
NcBool NcFile::add_att ( NcToken  attname,
int  ,
const long *   
)
NcBool NcFile::add_att ( NcToken  attname,
int  ,
const int  
)
NcBool NcFile::add_att ( NcToken  attname,
int  ,
const float *   
)
NcBool NcFile::add_att ( NcToken  attname,
int  ,
const double *   
)
virtual NcDim* NcFile::add_dim ( NcToken  dimname,
long  dimsize 
)
virtual
virtual NcDim* NcFile::add_dim ( NcToken  dimname)
virtual
virtual NcVar* NcFile::add_var ( NcToken  varname,
NcType  type,
const NcDim dim0 = 0,
const NcDim dim1 = 0,
const NcDim dim2 = 0,
const NcDim dim3 = 0,
const NcDim dim4 = 0 
)
virtual
virtual NcVar* NcFile::add_var ( NcToken  varname,
NcType  type,
int  ndims,
const NcDim **  dims 
)
virtual
NcBool NcFile::close ( void  )
NcBool NcFile::data_mode ( void  )
NcBool NcFile::define_mode ( void  )
NcAtt* NcFile::get_att ( NcToken  ) const
NcAtt* NcFile::get_att ( int  ) const
NcDim* NcFile::get_dim ( NcToken  ) const
NcDim* NcFile::get_dim ( int  ) const
FillMode NcFile::get_fill ( void  ) const
FileFormat NcFile::get_format ( void  ) const
NcVar* NcFile::get_var ( NcToken  ) const
NcVar* NcFile::get_var ( int  ) const
int NcFile::id ( void  ) const
NcBool NcFile::is_valid ( void  ) const
int NcFile::num_atts ( void  ) const
int NcFile::num_dims ( void  ) const
int NcFile::num_vars ( void  ) const
NcDim* NcFile::rec_dim ( void  ) const
NcBool NcFile::set_fill ( FillMode  = Fill)
NcBool NcFile::sync ( void  )

Member Data Documentation

NcDim** NcFile::dimensions
protected

Definition at line 121 of file netcdfcpp.h.

NcVar* NcFile::globalv
protected

Definition at line 123 of file netcdfcpp.h.

int NcFile::in_define_mode
protected

Definition at line 119 of file netcdfcpp.h.

FillMode NcFile::the_fill_mode
protected

Definition at line 120 of file netcdfcpp.h.

int NcFile::the_id
protected

Definition at line 118 of file netcdfcpp.h.

NcVar** NcFile::variables
protected

Definition at line 122 of file netcdfcpp.h.


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