16 nullObject = rhs.nullObject;
18 groupId = rhs.groupId;
30 nullObject(nullObject)
35 nullObject(rhs.nullObject),
46 return nullObject == rhs.nullObject;
48 return myName == rhs.myName && groupId == rhs.groupId && varId == rhs.varId;
54 return !(*
this == rhs);
67 ncCheck(nc_inq_atttype(groupId,varId,myName.c_str(),&xtypep),__FILE__,__LINE__);
76 multimap<string,NcType>::iterator iter;
78 for (iter=typeMap.begin(); iter!= typeMap.end();iter++) {
79 if(iter->second.getId() == xtypep)
return iter->second;
89 ncCheck(nc_inq_attlen(groupId, varId, myName.c_str(), &lenp),__FILE__,__LINE__);
99 tmpValues = (
char *) malloc(att_len + 1);
102 ncCheck(nc_get_att(groupId,varId,myName.c_str(),tmpValues),__FILE__,__LINE__);
104 ncCheck(nc_get_att_text(groupId,varId,myName.c_str(),tmpValues),__FILE__,__LINE__);
105 dataValues=string(tmpValues,att_len);
113 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
115 ncCheck(nc_get_att_text(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
123 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
125 ncCheck(nc_get_att_uchar(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
132 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
134 ncCheck(nc_get_att_schar(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
141 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
143 ncCheck(nc_get_att_short(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
150 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
152 ncCheck(nc_get_att_int(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
159 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
161 ncCheck(nc_get_att_long(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
168 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
170 ncCheck(nc_get_att_float(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
177 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
179 ncCheck(nc_get_att_double(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
186 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
188 ncCheck(nc_get_att_ushort(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
195 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
197 ncCheck(nc_get_att_uint(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
204 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
206 ncCheck(nc_get_att_longlong(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
213 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
215 ncCheck(nc_get_att_ulonglong(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
222 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
224 ncCheck(nc_get_att_string(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
229 ncCheck(nc_get_att(groupId,varId,myName.c_str(),dataValues),__FILE__,__LINE__);
Abstract base class represents inherited by ncVarAtt and ncGroupAtt.
bool operator!=(const NcAtt &rhs) const
!= operator
NcAtt & operator=(const NcAtt &rhs)
assignment operator
NcAtt()
Constructor generates a null object.
size_t getAttLength() const
Gets attribute length.
bool operator==(const NcAtt &rhs) const
equivalence operator
NcType getType() const
Returns the attribute type.
void getValues(char *dataValues) const
This is an overloaded member function, provided for convenience. It differs from the above function o...
NcGroup getParentGroup() const
Gets parent group.
Class represents a netCDF group.
@ ParentsAndCurrent
Select from contents of current and parents groups.
Base class inherited by NcOpaque, NcVlen, NcCompound and NcEnum classes.
ncType
List of netCDF types that can be represented.
@ nc_OPAQUE
"NcOpaque type"
@ nc_COMPOUND
"NcCompound type"
void ncCheck(int retCode, const char *file, int line)
Function checks error code and if necessary throws an exception.