NetCDF4 C++ API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
netcdf::NcDim Class Reference

Represents a netCDF dimension. More...

#include <NetCDF/cpp4/src/NcDim.h>

+ Inheritance diagram for netcdf::NcDim:

Detailed Description

Copyright:
Original C++ API developed by Lynton Appel.
Portions of this software were developed by the Unidata Program at the
University Corporation for Atmospheric Research.
Modifications: Copyright 2013 Colorado State University. All rights reserved.
Organization:
Natural Resource Ecology Laboratory
Colorado State University, Fort Collins, CO 80523 USA
www.nrel.colostate.edu
Project:
IRC <www.nrel.colostate.edu/projects/irc/>
Author
Tom Hilinski tom.h.nosp@m.ilin.nosp@m.ski@c.nosp@m.olos.nosp@m.tate..nosp@m.edu
Date
2013Jan
Examples:
Test_CreateFileNc3.cpp, Test_NcChar.cpp, Test_NcFileMetaCF.cpp, Test_NcString.cpp, and Test_NcVarMetaCF.cpp.

Public Member Functions

 NcDim ()
 
 NcDim (int const useFileID, NcGroup const &grp, int const dimId)
 Id of the NcDim. More...
 
 NcDim (int const useFileID, int const useGroupID, int const useDimID)
 Id of the NcDim. More...
 
 NcDim (const NcDim &ncDim)
 
NcGroup GetParentGroup () const
 
bool IsUnlimited () const
 
size_t Size () const
 
void Rename (std::string const &newName)
 
bool operator< (NcDim const &rhs) const
 
bool operator== (NcDim const &rhs) const
 
bool operator!= (NcDim const &rhs) const
 
- Public Member Functions inherited from netcdf::NcItem
virtual ~NcItem ()=0
 
bool IsNull () const
 
std::string const & GetName () const
 
int GetID () const
 
int GetGroupID () const
 
int GetFileID () const
 
NcItemoperator= (NcItem const &rhs)
 
bool operator== (NcItem const &rhs) const
 
bool operator!= (NcItem const &rhs) const
 
bool operator< (NcItem const &rhs) const
 

Additional Inherited Members

- Public Types inherited from netcdf::NcItem
enum  { idGlobal = NC_GLOBAL }
 
- Static Public Attributes inherited from netcdf::NcItem
static int const nullID = -999
 
- Protected Member Functions inherited from netcdf::NcItem
 NcItem (bool const isNullObject=true)
 
 NcItem (int const useFileID, int const useID, int const useGroupID=NcItem::idGlobal, std::string const useName=std::string())
 
 NcItem (NcItem const &rhs)
 
void Copy (NcItem const &rhs)
 
- Protected Attributes inherited from netcdf::NcItem
bool nullObject
 
int myID
 object ID number More...
 
int groupID
 group ID number (can be unused) More...
 
int fileID
 netCDF file ID number More...
 
std::string myName
 optional name of object More...
 

Constructor & Destructor Documentation

netcdf::NcDim::NcDim ( )
netcdf::NcDim::NcDim ( int const  useFileID,
NcGroup const &  grp,
int const  dimId 
)

Constructor for a dimension . The dimension must already exist in the netCDF file. New netCDF dimension can be added using NcGroup::addNcDim();

Parameters
useFileIDnetCDF file ID number
grpParent NcGroup
netcdf::NcDim::NcDim ( int const  useFileID,
int const  useGroupID,
int const  useDimID 
)
Parameters
useFileIDnetCDF file ID number
useGroupIDParent NcGroup
netcdf::NcDim::NcDim ( const NcDim ncDim)

Member Function Documentation

NcGroup netcdf::NcDim::GetParentGroup ( ) const
bool netcdf::NcDim::IsUnlimited ( ) const
bool netcdf::NcDim::operator!= ( NcDim const &  rhs) const
inline
bool netcdf::NcDim::operator< ( NcDim const &  rhs) const
bool netcdf::NcDim::operator== ( NcDim const &  rhs) const
void netcdf::NcDim::Rename ( std::string const &  newName)
virtual

Implements netcdf::NcItem.

size_t netcdf::NcDim::Size ( ) const

dimension size; for an unlimited dimension, returns the number of records

Examples:
Test_NcChar.cpp.

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