41 #include "config_hdf5.h"
43 #include <InternalErr.h>
46 #include <mime_util.h>
95 bool depth_first(hid_t pid,
char *gname, D4Group* par_grp,
const char *fname)
98 ">depth_first() for dmr "
100 <<
" gname: " << gname
101 <<
" fname: " << fname
111 if(H5Gget_info(pid,&g_info) <0) {
113 "h5_dmr handler: counting hdf5 group elements error for ";
115 throw InternalErr(__FILE__, __LINE__, msg);
118 nelems = g_info.nlinks;
120 ssize_t oname_size = 0;
123 for (hsize_t i = 0; i < nelems; i++) {
129 H5Lget_name_by_idx(pid,
".",H5_INDEX_NAME,H5_ITER_NATIVE,i,NULL,
131 if (oname_size <= 0) {
132 string msg =
"h5_dmr handler: Error getting the size of the hdf5 object from the group: ";
134 throw InternalErr(__FILE__, __LINE__, msg);
138 oname.resize((
size_t) oname_size + 1);
140 if (H5Lget_name_by_idx(pid,
".",H5_INDEX_NAME,H5_ITER_NATIVE,i,&oname[0],
141 (
size_t)(oname_size+1), H5P_DEFAULT) < 0){
143 "h5_dmr handler: Error getting the hdf5 object name from the group: ";
145 throw InternalErr(__FILE__, __LINE__, msg);
150 if (H5Lget_info(pid,&oname[0],&linfo,H5P_DEFAULT)<0) {
151 string msg =
"hdf5 link name error from: ";
153 throw InternalErr(__FILE__, __LINE__, msg);
157 if(linfo.type == H5L_TYPE_SOFT) {
159 size_t val_size = linfo.u.val_size;
160 get_softlink(par_grp,pid,&oname[0],slinkindex,val_size);
166 if(linfo.type == H5L_TYPE_EXTERNAL)
172 if (H5Oget_info_by_idx(pid,
".", H5_INDEX_NAME, H5_ITER_NATIVE,
173 i, &oinfo, H5P_DEFAULT)<0) {
174 string msg =
"h5_dmr handler: Error obtaining the info for the object";
175 msg += string(oname.begin(),oname.end());
176 throw InternalErr(__FILE__, __LINE__, msg);
179 H5O_type_t obj_type = oinfo.type;
187 string full_path_name =
188 string(gname) + string(oname.begin(),oname.end()-1) +
"/";
190 BESDEBUG(
"h5",
"=depth_first dmr ():H5G_GROUP " << full_path_name
194 t_fpn.resize(full_path_name.length()+1);
195 copy(full_path_name.begin(),full_path_name.end(),t_fpn.begin());
196 t_fpn[full_path_name.length()] =
'\0';
198 hid_t cgroup = H5Gopen(pid, &t_fpn[0],H5P_DEFAULT);
200 throw InternalErr(__FILE__, __LINE__,
"h5_dmr handler: H5Gopen() failed.");
203 string grp_name = string(oname.begin(),oname.end()-1);
206 string oid = get_hardlink_dmr(cgroup, full_path_name.c_str());
209 D4Group* tem_d4_cgroup =
new D4Group(grp_name);
215 par_grp->add_group_nocopy(tem_d4_cgroup);
219 depth_first(cgroup, &t_fpn[0], tem_d4_cgroup,fname);
230 D4Group* tem_d4_cgroup =
new D4Group(
string(grp_name));
233 D4Attribute *d4_hlinfo =
new D4Attribute(
"HDF5_HARDLINK",attr_str_c);
236 tem_d4_cgroup->attributes()->add_attribute_nocopy(d4_hlinfo);
237 par_grp->add_group_nocopy(tem_d4_cgroup);
241 if (H5Gclose(cgroup) < 0){
242 throw InternalErr(__FILE__, __LINE__,
"Could not close the group.");
247 case H5O_TYPE_DATASET:
251 string full_path_name = string(gname) + string(oname.begin(),oname.end()-1);
264 if((dset_id = H5Dopen(pid,full_path_name.c_str(),H5P_DEFAULT)) <0) {
265 string msg =
"cannot open the HDF5 dataset ";
266 msg += full_path_name;
267 throw InternalErr(__FILE__, __LINE__, msg);
277 if(H5Dclose(dset_id)<0) {
278 string msg =
"cannot close the HDF5 dataset ";
279 msg += full_path_name;
280 throw InternalErr(__FILE__, __LINE__, msg);
285 case H5O_TYPE_NAMED_DATATYPE:
293 BESDEBUG(
"h5",
"<depth_first() for dmr" << endl);
319 bool breadth_first(hid_t pid,
char *gname, D4Group* par_grp,
const char *fname,
bool use_dimscale)
322 ">breadth_first() for dmr "
324 <<
" gname: " << gname
325 <<
" fname: " << fname
334 if(H5Gget_info(pid,&g_info) <0) {
336 "h5_dmr handler: counting hdf5 group elements error for ";
338 throw InternalErr(__FILE__, __LINE__, msg);
341 nelems = g_info.nlinks;
346 for (hsize_t i = 0; i < nelems; i++) {
352 H5Lget_name_by_idx(pid,
".",H5_INDEX_NAME,H5_ITER_NATIVE,i,NULL,
354 if (oname_size <= 0) {
355 string msg =
"h5_dmr handler: Error getting the size of the hdf5 object from the group: ";
357 throw InternalErr(__FILE__, __LINE__, msg);
361 oname.resize((
size_t) oname_size + 1);
363 if (H5Lget_name_by_idx(pid,
".",H5_INDEX_NAME,H5_ITER_NATIVE,i,&oname[0],
364 (
size_t)(oname_size+1), H5P_DEFAULT) < 0){
366 "h5_dmr handler: Error getting the hdf5 object name from the group: ";
368 throw InternalErr(__FILE__, __LINE__, msg);
373 if (H5Lget_info(pid,&oname[0],&linfo,H5P_DEFAULT)<0) {
374 string msg =
"hdf5 link name error from: ";
376 throw InternalErr(__FILE__, __LINE__, msg);
380 if(linfo.type == H5L_TYPE_SOFT) {
384 size_t val_size = linfo.u.val_size;
385 get_softlink(par_grp,pid,&oname[0],slinkindex,val_size);
390 if(linfo.type == H5L_TYPE_EXTERNAL)
396 if (H5Oget_info_by_idx(pid,
".", H5_INDEX_NAME, H5_ITER_NATIVE,
397 i, &oinfo, H5P_DEFAULT)<0) {
398 string msg =
"h5_dmr handler: Error obtaining the info for the object";
399 msg += string(oname.begin(),oname.end());
400 throw InternalErr(__FILE__, __LINE__, msg);
403 H5O_type_t obj_type = oinfo.type;
405 if(H5O_TYPE_DATASET == obj_type) {
408 string full_path_name = string(gname) + string(oname.begin(),oname.end()-1);
415 bool is_pure_dim =
false;
416 get_dataset(pid, full_path_name, &dt_inst,use_dimscale,is_pure_dim);
418 if(
false == is_pure_dim) {
420 if((dset_id = H5Dopen(pid,full_path_name.c_str(),H5P_DEFAULT)) <0) {
421 string msg =
"cannot open the HDF5 dataset ";
422 msg += full_path_name;
423 throw InternalErr(__FILE__, __LINE__, msg);
433 if(H5Dclose(dset_id)<0) {
434 string msg =
"cannot close the HDF5 dataset ";
435 msg += full_path_name;
436 throw InternalErr(__FILE__, __LINE__, msg);
441 D4Dimensions *d4_dims = par_grp->dims();
442 string d4dim_name = string(oname.begin(),oname.end()-1);
443 D4Dimension *d4_dim = d4_dims->find_dim(d4dim_name);
445 d4_dim =
new D4Dimension(d4dim_name,dt_inst.
nelmts);
446 d4_dims->add_dim_nocopy(d4_dim);
448 BESDEBUG(
"h5",
"<h5dmr.cc: pure dimension: dataset name." << d4dim_name << endl);
449 if(H5Tclose(dt_inst.
type)<0) {
450 throw InternalErr(__FILE__, __LINE__,
"Cannot close the HDF5 datatype.");
461 for (hsize_t i = 0; i < nelems; i++) {
467 H5Lget_name_by_idx(pid,
".",H5_INDEX_NAME,H5_ITER_NATIVE,i,NULL,
469 if (oname_size <= 0) {
470 string msg =
"h5_dmr handler: Error getting the size of the hdf5 object from the group: ";
472 throw InternalErr(__FILE__, __LINE__, msg);
476 oname.resize((
size_t) oname_size + 1);
478 if (H5Lget_name_by_idx(pid,
".",H5_INDEX_NAME,H5_ITER_NATIVE,i,&oname[0],
479 (
size_t)(oname_size+1), H5P_DEFAULT) < 0){
481 "h5_dmr handler: Error getting the hdf5 object name from the group: ";
483 throw InternalErr(__FILE__, __LINE__, msg);
488 if (H5Lget_info(pid,&oname[0],&linfo,H5P_DEFAULT)<0) {
489 string msg =
"hdf5 link name error from: ";
491 throw InternalErr(__FILE__, __LINE__, msg);
496 if(linfo.type == H5L_TYPE_SOFT) {
501 if(linfo.type == H5L_TYPE_EXTERNAL)
507 if (H5Oget_info_by_idx(pid,
".", H5_INDEX_NAME, H5_ITER_NATIVE,
508 i, &oinfo, H5P_DEFAULT)<0) {
509 string msg =
"h5_dmr handler: Error obtaining the info for the object in the breadth_first.";
510 throw InternalErr(__FILE__, __LINE__, msg);
513 H5O_type_t obj_type = oinfo.type;
516 if(obj_type == H5O_TYPE_GROUP) {
519 string full_path_name =
520 string(gname) + string(oname.begin(),oname.end()-1) +
"/";
522 BESDEBUG(
"h5",
"=breadth_first dmr ():H5G_GROUP " << full_path_name
526 t_fpn.resize(full_path_name.length()+1);
527 copy(full_path_name.begin(),full_path_name.end(),t_fpn.begin());
528 t_fpn[full_path_name.length()] =
'\0';
530 hid_t cgroup = H5Gopen(pid, &t_fpn[0],H5P_DEFAULT);
532 throw InternalErr(__FILE__, __LINE__,
"h5_dmr handler: H5Gopen() failed.");
535 string grp_name = string(oname.begin(),oname.end()-1);
538 string oid = get_hardlink_dmr(cgroup, full_path_name.c_str());
541 D4Group* tem_d4_cgroup =
new D4Group(grp_name);
544 par_grp->add_group_nocopy(tem_d4_cgroup);
547 breadth_first(cgroup, &t_fpn[0], tem_d4_cgroup,fname,use_dimscale);
558 D4Group* tem_d4_cgroup =
new D4Group(
string(grp_name));
561 D4Attribute *d4_hlinfo =
new D4Attribute(
"HDF5_HARDLINK",attr_str_c);
564 tem_d4_cgroup->attributes()->add_attribute_nocopy(d4_hlinfo);
565 par_grp->add_group_nocopy(tem_d4_cgroup);
568 if (H5Gclose(cgroup) < 0){
569 throw InternalErr(__FILE__, __LINE__,
"Could not close the group.");
574 BESDEBUG(
"h5",
"<breadth_first() " << endl);
595 read_objects( D4Group * d4_grp,
const string &varname,
const string &filename,
const hid_t dset_id)
598 switch (H5Tget_class(dt_inst.
type)) {
606 H5Tclose(dt_inst.
type);
607 throw InternalErr(__FILE__, __LINE__,
"Currently don't support accessing data of Array datatype when array datatype is not inside the compound.");
614 if(H5Tclose(dt_inst.
type)<0) {
615 throw InternalErr(__FILE__, __LINE__,
"Cannot close the HDF5 datatype.");
639 const string & filename,hid_t dset_id)
643 string newvarname = HDF5CFUtil::obtain_string_after_lastslash(varname);
647 BaseType *bt = Get_bt(newvarname, varname,filename, dt_inst.
type,
true);
650 InternalErr(__FILE__, __LINE__,
651 "Unable to convert hdf5 datatype to dods basetype");
655 if (dt_inst.
ndims == 0) {
657 bt->transform_to_dap4(d4_grp,d4_grp);
660 BaseType* new_var = d4_grp->var(bt->name());
665 map_h5_dset_hardlink_to_d4(dset_id,varname,new_var,NULL,1);
681 ar->set_varpath(varname);
685 int dimnames_size = 0;
686 if((
unsigned int)((
int)(dt_inst.dimnames.size())) != dt_inst.dimnames.size())
690 InternalErr(__FILE__, __LINE__,
691 "number of dimensions: overflow");
693 dimnames_size = (
int)(dt_inst.dimnames.size());
697 if(dimnames_size ==dt_inst.
ndims) {
699 for (
int dim_index = 0; dim_index < dt_inst.
ndims; dim_index++) {
700 if(dt_inst.dimnames[dim_index] !=
"")
701 ar->append_dim(dt_inst.
size[dim_index],dt_inst.dimnames[dim_index]);
703 ar->append_dim(dt_inst.
size[dim_index]);
706 dt_inst.dimnames.clear();
710 for (
int dim_index = 0; dim_index < dt_inst.
ndims; dim_index++)
711 ar->append_dim(dt_inst.
size[dim_index]);
715 BaseType* new_var = NULL;
717 new_var = ar->h5dims_transform_to_dap4(d4_grp,dt_inst.dimnames_path);
725 dt_inst.dimnames_path.clear();
731 map_h5_dset_hardlink_to_d4(dset_id,varname,new_var,NULL,1);
734 D4Attribute *test_attr =
new D4Attribute(
"DAP4_test",attr_str_c);
735 test_attr->add_value(
"test_grp_attr");
736 new_var->attributes()->add_attribute_nocopy(test_attr);
739 d4_grp->add_var_nocopy(new_var);
742 BESDEBUG(
"h5",
"<read_objects_base_type(dmr)" << endl);
761 const string & filename,hid_t dset_id)
764 string newvarname = HDF5CFUtil::obtain_string_after_lastslash(varname);
767 Structure *structure = Get_structure(newvarname, varname,filename, dt_inst.
type,
true);
770 BESDEBUG(
"h5",
"=read_objects_structure(): Dimension is "
771 << dt_inst.
ndims << endl);
773 if (dt_inst.
ndims != 0) {
774 BESDEBUG(
"h5",
"=read_objects_structure(): array of size " <<
776 BESDEBUG(
"h5",
"=read_objects_structure(): memory needed = " <<
777 dt_inst.
need << endl);
781 delete structure; structure = 0;
788 ar->set_length((
int) (dt_inst.
nelmts));
789 ar->set_varpath(varname);
792 int dimnames_size = 0;
793 if((
unsigned int)((
int)(dt_inst.dimnames.size())) != dt_inst.dimnames.size())
797 InternalErr(__FILE__, __LINE__,
798 "number of dimensions: overflow");
800 dimnames_size = (
int)(dt_inst.dimnames.size());
803 if(dimnames_size ==dt_inst.
ndims) {
804 for (
int dim_index = 0; dim_index < dt_inst.
ndims; dim_index++) {
805 if(dt_inst.dimnames[dim_index] !=
"")
806 ar->append_dim(dt_inst.
size[dim_index],dt_inst.dimnames[dim_index]);
808 ar->append_dim(dt_inst.
size[dim_index]);
810 dt_inst.dimnames.clear();
813 for (
int dim_index = 0; dim_index < dt_inst.
ndims; dim_index++)
814 ar->append_dim(dt_inst.
size[dim_index]);
819 BaseType* new_var = ar->h5dims_transform_to_dap4(d4_grp,dt_inst.dimnames_path);
820 dt_inst.dimnames_path.clear();
826 map_h5_dset_hardlink_to_d4(dset_id,varname,new_var,NULL,1);
830 d4_grp->add_var_nocopy(new_var);
835 structure->set_is_dap4(
true);
837 map_h5_dset_hardlink_to_d4(dset_id,varname,NULL,structure,2);
839 d4_grp->add_var_nocopy(structure);
868 if (H5Oget_info(h5_objid, &obj_info) <0) {
869 string msg =
"Fail to obtain the HDF5 object info. .";
870 throw InternalErr(__FILE__, __LINE__, msg);
874 int num_attr = obj_info.num_attrs;
876 string msg =
"Fail to get the number of attributes for the HDF5 object. ";
877 throw InternalErr(__FILE__, __LINE__,msg);
881 vector<char>temp_buf;
883 bool ignore_attr =
false;
885 for (
int j = 0; j < num_attr; j++) {
893 attr_id =
get_attr_info(h5_objid, j,
true,&attr_inst, &ignore_attr);
894 if (
true == ignore_attr) {
904 hid_t ty_id = H5Aget_type(attr_id);
907 throw InternalErr(__FILE__, __LINE__,
"Cannot retrieve HDF5 attribute datatype successfully.");
913 D4AttributeType dap4_attr_type = daptype_strrep_to_dap4_attrtype(dap_type);
916 if(attr_null_c == dap4_attr_type) {
919 throw InternalErr(__FILE__, __LINE__,
"unsupported DAP4 attribute type");
922 string attr_name = attr_inst.
name;
923 BESDEBUG(
"h5",
"arttr_name= " << attr_name << endl);
926 D4Attribute *d4_attr =
new D4Attribute(attr_name,dap4_attr_type);
929 if (H5Tis_variable_str(ty_id)) {
930 write_vlen_str_attrs(attr_id,ty_id,&attr_inst,d4_attr,NULL,
true);
935 value.resize(attr_inst.
need +
sizeof(
char));
937 BESDEBUG(
"h5",
"arttr_inst.need=" << attr_inst.
need << endl);
940 hid_t memtype = H5Tget_native_type(ty_id, H5T_DIR_ASCEND);
942 if (H5Aread(attr_id, memtype, (
void *) (&value[0])) < 0) {
944 throw InternalErr(__FILE__, __LINE__,
"unable to read HDF5 attribute data");
949 if (attr_inst.
ndims == 0) {
950 for (
int loc = 0; loc < (
int) attr_inst.
nelmts; loc++) {
951 print_rep =
print_attr(ty_id, loc, &value[0]);
952 if (print_rep.c_str() != NULL) {
953 d4_attr->add_value(print_rep);
961 int elesize = (
int) H5Tget_size(ty_id);
966 throw InternalErr(__FILE__, __LINE__,
"unable to get attibute size");
971 char *tempvalue = &value[0];
975 for( hsize_t temp_index = 0; temp_index < attr_inst.
nelmts; temp_index ++) {
978 if (print_rep.c_str() != NULL) {
980 BESDEBUG(
"h5",
"print_rep= " << print_rep << endl);
982 d4_attr->add_value(print_rep);
983 tempvalue = tempvalue + elesize;
985 "tempvalue= " << tempvalue
986 <<
"elesize=" << elesize
994 throw InternalErr(__FILE__, __LINE__,
"unable to convert attibute value to DAP");
999 if(H5Tclose(ty_id) < 0) {
1002 throw InternalErr(__FILE__, __LINE__,
"unable to close HDF5 type id");
1004 if (H5Aclose(attr_id) < 0) {
1006 throw InternalErr(__FILE__, __LINE__,
"unable to close attibute id");
1010 d4g->attributes()->add_attribute_nocopy(d4_attr);
1012 d4b->attributes()->add_attribute_nocopy(d4_attr);
1013 else if ( 2 == flag)
1014 d4s->attributes()->add_attribute_nocopy(d4_attr);
1018 string msg =
"The add_dap4_attr flag has to be either 0,1 or 2.";
1019 msg+=
"The current flag is "+sflag.str();
1021 throw InternalErr(__FILE__, __LINE__, msg);
1043 void map_h5_dset_hardlink_to_d4(hid_t h5_dsetid,
const string & full_path, BaseType* d4b,Structure * d4s,
int flag) {
1046 string oid = get_hardlink_dmr(h5_dsetid, full_path);
1049 if(
false == oid.empty()) {
1051 D4Attribute *d4_hlinfo =
new D4Attribute(
"HDF5_HARDLINK",attr_str_c);
1055 d4b->attributes()->add_attribute_nocopy(d4_hlinfo);
1056 else if ( 2 == flag)
1057 d4s->attributes()->add_attribute_nocopy(d4_hlinfo);
1076 void get_softlink(D4Group* par_grp, hid_t h5obj_id,
const string & oname,
int index,
size_t val_size)
1078 BESDEBUG(
"h5",
"dap4 >get_softlink():" << oname << endl);
1081 oss << string(
"HDF5_SOFTLINK");
1084 string temp_varname = oss.str();
1087 BESDEBUG(
"h5",
"dap4->get_softlink():" << temp_varname << endl);
1088 D4Attribute *d4_slinfo =
new D4Attribute;
1089 d4_slinfo->set_name(temp_varname);
1092 d4_slinfo->set_type(attr_container_c);
1094 string softlink_name =
"linkname";
1096 D4Attribute *softlink_src =
new D4Attribute(softlink_name,attr_str_c);
1097 softlink_src->add_value(oname);
1099 d4_slinfo->attributes()->add_attribute_nocopy(softlink_src);
1100 string softlink_value_name =
"LINKTARGET";
1103 D4Attribute *softlink_tgt = 0;
1107 buf.resize(val_size + 1);
1110 if (H5Lget_val(h5obj_id, oname.c_str(), (
void*) &buf[0], val_size + 1, H5P_DEFAULT) < 0) {
1111 throw InternalErr(__FILE__, __LINE__,
"unable to get link value");
1113 softlink_tgt =
new D4Attribute(softlink_value_name, attr_str_c);
1114 string link_target_name = string(buf.begin(), buf.end());
1115 softlink_tgt->add_value(link_target_name);
1117 d4_slinfo->attributes()->add_attribute_nocopy(softlink_tgt);
1120 delete softlink_tgt;
1124 par_grp->attributes()->add_attribute_nocopy(d4_slinfo);
1140 string get_hardlink_dmr( hid_t h5obj_id,
const string & oname) {
1142 BESDEBUG(
"h5",
"dap4->get_hardlink_dmr():" << oname << endl);
1145 H5O_info_t obj_info;
1146 if (H5Oget_info(h5obj_id, &obj_info) <0) {
1147 throw InternalErr(__FILE__, __LINE__,
"H5Oget_info() failed.");
1154 if (obj_info.rc >1) {
1157 oss << hex << obj_info.addr;
1158 string objno = oss.str();
1160 BESDEBUG(
"h5",
"dap4->get_hardlink_dmr() objno=" << objno << endl);
A class for handling all types of array in HDF5 for the default option.
This class provides a way to map HDF5 byte to DAP Byte for the default option.
This file includes several helper functions for translating HDF5 to CF-compliant.
A class for mapping HDF5 32-bit float to DAP for the default option.
A class for mapping HDF5 64-bit float to DAP for the default option.
A class for HDF5 signed 16 bit integer type.
This class provides a way to map HDF5 32 bit integer to DAP Int32 for the default option.
This class that translates HDF5 string into DAP string for the default option.
This class converts HDF5 compound type into DAP structure for the default option.
This class provides a way to map unsigned HDF5 16 bit integer to DAP UInt16 for the default option.
This class provides a way to map unsigned HDF5 32 bit integer to DAP UInt32.
This class generates DAP URL type for the default option.
void set_numdim(int ndims)
remembers number of dimensions of this array.
void set_numelm(int nelms)
remembers number of elements in this array.
void set_memneed(size_t need)
remembers memory size needed.
std::string get_name(std::string id)
bool add(std::string id, const std::string name)
void depth_first(hid_t pid, const char *gname, DAS &das)
void read_objects(DAS &das, const string &varname, hid_t oid, int num_attr)
void read_objects_base_type(DDS &dds_table, const string &varname, const string &filename)
void read_objects_structure(DDS &dds_table, const string &varname, const string &filename)
void map_h5_attrs_to_dap4(hid_t oid, D4Group *d4g, BaseType *d4b, Structure *d4s, int flag)
A function that map HDF5 attributes to DAP4.
HDF5PathFinder obj_paths
A variable for remembering visited paths to break cyclic HDF5 groups.
bool breadth_first(hid_t pid, char *gname, D4Group *par_grp, const char *fname, bool use_dimscale)
void get_softlink(D4Group *par_grp, hid_t h5obj_id, const string &oname, int index, size_t val_size)
Data structure and retrieval processing header for the default option.
string print_attr(hid_t type, int loc, void *sm_buf)
string get_dap_type(hid_t type, bool is_dap4)
void get_dataset(hid_t pid, const string &dname, DS_t *dt_inst_ptr)
hid_t get_attr_info(hid_t dset, int index, bool is_dap4, DSattr_t *attr_inst_ptr, bool *ignore_attr_ptr)
The main header of the HDF5 OPeNDAP handler.
const int DODS_NAMELEN
Maximum length of variable or attribute name(default option only).
A structure for DDS generation.
hsize_t nelmts
Number of elements.
hsize_t need
Space needed.
hid_t type
HDF5 data set id.
int size[DODS_MAX_RANK]
Size of each dimension.
int ndims
HDF5 data space id.
A structure for DAS generation.
char name[DODS_NAMELEN]
Name of HDF5 group or dataset.
int ndims
Number of dimensions.
hsize_t nelmts
Number of elements.
hsize_t need
Memory space needed to hold nelmts type.