summaryrefslogtreecommitdiffstats
path: root/tools/src/h5dump/h5dump.h
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2020-07-15 16:20:16 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2020-07-15 16:20:16 (GMT)
commitbac0fc6309aaf777d4b6d093cf027dce3ecfb58c (patch)
tree1b944edb35a01a5bb8bb72445f82afb52317f06e /tools/src/h5dump/h5dump.h
parent900e75544e214a82de3b7fcdbc083ee71d484892 (diff)
downloadhdf5-bac0fc6309aaf777d4b6d093cf027dce3ecfb58c.zip
hdf5-bac0fc6309aaf777d4b6d093cf027dce3ecfb58c.tar.gz
hdf5-bac0fc6309aaf777d4b6d093cf027dce3ecfb58c.tar.bz2
Tools refactor
Move error_stack setup to tools library Add structure for h5dump properties Eliminate duplicated h5diff functions Use properties structure in place of argument lists.
Diffstat (limited to 'tools/src/h5dump/h5dump.h')
-rw-r--r--tools/src/h5dump/h5dump.h39
1 files changed, 21 insertions, 18 deletions
diff --git a/tools/src/h5dump/h5dump.h b/tools/src/h5dump/h5dump.h
index ca1fef6..548af09 100644
--- a/tools/src/h5dump/h5dump.h
+++ b/tools/src/h5dump/h5dump.h
@@ -52,8 +52,8 @@ typedef struct h5dump_table_list_t {
h5dump_table_list_t table_list = {0, 0, NULL};
table_t *group_table = NULL, *dset_table = NULL, *type_table = NULL;
-unsigned dump_indent = 0; /*how far in to indent the line */
+unsigned dump_indent = 0; /* how far in to indent the line */
int unamedtype = 0; /* shared datatype with no name */
hbool_t hit_elink = FALSE; /* whether we have traversed an external link */
size_t prefix_len = 1024;
@@ -61,23 +61,26 @@ char *prefix = NULL;
const char *fp_format = NULL;
/* things to display or which are set via command line parameters */
-int display_all = TRUE;
-int display_oid = FALSE;
-int display_data = TRUE;
-int display_attr_data = TRUE;
-int display_char = FALSE; /*print 1-byte numbers as ASCII */
-int usingdasho = FALSE;
-int display_bb = FALSE; /*superblock */
-int display_dcpl = FALSE; /*dcpl */
-int display_fi = FALSE; /*file index */
-int display_ai = TRUE; /*array index */
-int display_escape = FALSE; /*escape non printable characters */
-int display_region = FALSE; /*print region reference data */
-int disable_compact_subset= FALSE; /* disable compact form of subset notation */
-int display_packed_bits = FALSE; /*print 1-8 byte numbers as packed bits*/
-int include_attrs = TRUE; /* Display attributes */
-int display_vds_first = FALSE; /* vds display to all by default*/
-int vds_gap_size = 0; /* vds skip missing files default is none */
+typedef struct {
+ int display_all;
+ int display_oid;
+ int display_data;
+ int display_attr_data;
+ int display_char; /* print 1-byte numbers as ASCII */
+ int usingdasho;
+ int display_bb; /* superblock */
+ int display_dcpl; /* dcpl */
+ int display_fi; /* file index */
+ int display_ai; /* array index */
+ int display_escape; /* escape non printable characters */
+ int display_region; /* print region reference data */
+ int disable_compact_subset; /* disable compact form of subset notation */
+ int display_packed_bits; /* print 1-8 byte numbers as packed bits */
+ int include_attrs; /* Display attributes */
+ int display_vds_first; /* vds display to all by default */
+ int vds_gap_size; /* vds skip missing files default is none */
+} dump_opt_t;
+dump_opt_t dump_opts = {TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, 0};
#define PACKED_BITS_MAX 8 /* Maximum number of packed-bits to display */
#define PACKED_BITS_SIZE_MAX (8*sizeof(long long)) /* Maximum bits size of integer types of packed-bits */