[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problem with C++ set_cur function



> Organization: .
> Keywords: 199501191700.AA07783

Hi Phil,

> Thanks very much for those patches to the C++ netcdf interface.  I have been 
> able to use it successfully on a DecStation 5000 with g++ and on a pc/dos 
> with Watcom C++ v10.0a.  There are two minor changes that are needed for the 
> watcom compiler.  First, in netcdf.hh, the #include "netcdf.h" needs to be 
> enclosed in
> extern "C" {
> #include "netcdf.h"
> }
> 
> Second, on line 335 and 336 the OpenMode and CreateMode need to be prefixed 
> with class scopre resolution NcOldFile:: and NcNewFile::, respectively. 
>  Similarly, on line 376 and 377.

Thanks, I've incorporated those patches into the sources and will include
them with the next patch or release, whichever comes first.

> Other than these two trivial changes, I am able to use the C++ interface to 
> the netcdf library.  What future plans are there for a C++ netcdf library? 

To rewrite it based on experience and feedback with the experimental
version.  I'm not sure when this will happen, but I hope to be able to work
on it in the next couple of months.  I'm interested in any feedback you can
provide on improving the class design.  I was somewhat of a novice when I
originally designed the C++ interface, and I still need more C++ experience.

>  Is there any particular reason why the 2.3 generalized hyperslab access 
> interfaces and record I/O interfaces were left out of the C++ class library? 
>  (Other than having too much work to do and too little time!  :-) )

That's the only reason.  Certainly the next release should include support
for these netCDF features.

> P.S.  Several months ago, I found a subtle problem with the PC version of 
> xdrposix.c where the global variable _fmode was used instead of directly 
> masking the fmode used the open statement.  Rich Signell said he was going 
> to send you the fix.  Did you get this?  If not, it is a simple fix (and it 
> is required for the mexcdf matlab interface to netcdf).
> 
> line 529 of xdrposix.c:
> #ifdef DOS_FS
>      fmode |= O_BINARY
> #endif

It doesn't look like we got this fix from Rich Signell, but I've passed it
on to Glenn Davis to incorporate in the next release and included it in our
list of known problems (with workarounds) that we're putting together for
our netCDF Web page.  Thanks for sending it.

______________________________________________________________________________

Russ Rew                                                UCAR Unidata Program
address@hidden                                          P.O. Box 3000
http://www.unidata.ucar.edu/                          Boulder, CO 80307-3000
______________________________________________________________________________