summaryrefslogtreecommitdiffstats
path: root/tools/h5dump.c
diff options
context:
space:
mode:
authorPatrick Lu <ptlu@hawkwind.ncsa.uiuc.edu>1999-12-03 19:26:25 (GMT)
committerPatrick Lu <ptlu@hawkwind.ncsa.uiuc.edu>1999-12-03 19:26:25 (GMT)
commit78cd5541bf5fbc420e2d2ed09b98e3b976493e7a (patch)
tree536710db1f9ad0cda97e21195447f7dd4b94be37 /tools/h5dump.c
parent9b2b532898bdd17a52192f1a5e2e659ed8601fac (diff)
downloadhdf5-78cd5541bf5fbc420e2d2ed09b98e3b976493e7a.zip
hdf5-78cd5541bf5fbc420e2d2ed09b98e3b976493e7a.tar.gz
hdf5-78cd5541bf5fbc420e2d2ed09b98e3b976493e7a.tar.bz2
[svn-r1851] updated the output for the dumper so that it prints out compound types
with out the square braces. also the formatting for the compound types in the dataset part section has been corrected. still need to update the expected outputs so there will be some errors until I get that all checked in...
Diffstat (limited to 'tools/h5dump.c')
-rw-r--r--tools/h5dump.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/tools/h5dump.c b/tools/h5dump.c
index 7248b3e..c1cf511 100644
--- a/tools/h5dump.c
+++ b/tools/h5dump.c
@@ -285,18 +285,24 @@ H5G_stat_t statbuf;
nmembers = H5Tget_nmembers(type);
for (i = 0; i < nmembers; i++) {
-
fname = H5Tget_member_name(type, i);
mtype = H5Tget_member_type(type, i);
ndims = H5Tget_member_dims(type, i, dims, perm);
- if (H5Tget_class(mtype) != H5T_STRING)
+ if (H5Tget_class(mtype) != H5T_STRING)/* && (H5Tget_class(mtype) != H5T_COMPOUND))*/
indentation (indent+COL);
-
+ if (H5Tget_class(mtype) == H5T_COMPOUND) {
+ indent += COL;
+ printf("{\n");
+ }
print_datatype(mtype);
-
+ if (H5Tget_class(mtype) == H5T_COMPOUND) {
+ indent -= COL;
+ indentation (indent+COL);
+ printf("}");
+ }
printf (" \"%s\"", fname);
if (ndims != 1 || dims[0] != 1) {
@@ -316,14 +322,14 @@ H5G_stat_t statbuf;
break;
case H5T_ENUM:
printf("H5T_ENUM\n");
- indentation(indent + 3);
+ indentation(indent + COL);
printf("{ ");
super = H5Tget_super(type);
print_datatype(super);
printf(";");
print_enum(type);
printf("\n");
- indentation (indent + 3);
+ indentation (indent + COL);
printf("}\n");
break;
default: