[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
netcdf c++ classes
- Subject: netcdf c++ classes
- Date: Wed, 02 Nov 1994 10:42:32 -0700
Hi Dan,
I'm just starting to look over the changes you sent me for the netCDF C++
interface, and have a couple of questions about changes to ncvalues.hh.
1. In the statement
#define ncBad_int ncBad_short
I think this should be
#define ncBad_int ncBad_long
instead, because "ncInt" is intended to be synonymous with "ncLong"
rather than with "ncShort".
2. In ncvalues.hh, you defined a new member function NcVal::invalid(), but
the definition you provided makes it appear that either the name should
be "valid" or the return values should be changed:
int NcVal(TYPE)::invalid( void ) const \
{ \
for(int i=0;i<the_number;i++) \
if (the_values[i] == ncBad_ ## TYPE) return 0; \
return 1; \
} \
As I read it, this returns 0 if a bad (invalid) value was detected in
the block of values and 1 if none of the values was bad. If the return
value is being treated as a boolean, shouldn't this be the other way
around?
--Russ