netcdf-hdf mailing list is no longer active. The list archives are made available for historical reasons.
Hi Ed, > Quincey Koziol <koziol@xxxxxxxxxxxxx> writes: > > > What I was planning to do was to create empty dataspaces the same way we > > create scalar dataspaces: > > scalar_space_id=H5Screate(H5S_SCALAR); /* Create a scalar dataspace */ > > > > only use a new constant: > > empty_space_id=H5Screate(H5S_EMPTY); /* Create an empty dataspace */ > > > > Additionally, I think it would be a good idea to have two dataspaces > > that > > are created by the library: H5S_SPACE_SCALAR and H5S_SPACE_EMPTY, which > > would > > avoid the need for users to create these dataspaces (as outlined above) and > > could be used directly in creating datasets or attributes: > > > > > > dataset_id=H5Dcreate(fid,"/Dataset",H5T_NATIVE_INT,H5S_SPACE_EMPTY,H5P_DEFAULT); > > > > This would need support in the tools, the FORTRAN & C++ APIs, etc... > > > > Quincey > > > > > Make sure that selections work sensibly: > > > > > > EMPTY AND SPACE = ?? > > > EMPTY OR SPACE = ?? > > > SPACE - EMPTY = SPACE > > > EMPTY - SPACE = ?? > > > > > > etc. > > Hmm, you can't operate between two dataspaces, so these don't make any > > sense. Also, since there are no elements in the dataspace, there is no way > > to perform I/O on an empty dataspace. > > > > Quincey > > Quincey, > > It sounds terrific to me, but don't forget that we also need to use > this space for creating attributes, which currently are more > restrictive than dataspaces. Yes, it'll work for attributes also. Quincey