summaryrefslogtreecommitdiffstats
path: root/tools/lib/h5tools_utils.h
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2005-08-25 20:16:40 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2005-08-25 20:16:40 (GMT)
commita4329aaa478d76dc954216b86c74539861aedf38 (patch)
tree0d005e1ba2c3c78450187bd74c146a0d329032c6 /tools/lib/h5tools_utils.h
parentab6656c52c8186fc9bca911f7dfb4df967b26817 (diff)
downloadhdf5-a4329aaa478d76dc954216b86c74539861aedf38.zip
hdf5-a4329aaa478d76dc954216b86c74539861aedf38.tar.gz
hdf5-a4329aaa478d76dc954216b86c74539861aedf38.tar.bz2
[svn-r11297] Purpose:
Code cleanup & speedup Description: Refactor h5dump & related code to be considerably cleaner & faster for files with large #'s of objects. Platforms tested: FreeBS 4.11 (sleipnir) Linux 2.4
Diffstat (limited to 'tools/lib/h5tools_utils.h')
-rw-r--r--tools/lib/h5tools_utils.h29
1 files changed, 11 insertions, 18 deletions
diff --git a/tools/lib/h5tools_utils.h b/tools/lib/h5tools_utils.h
index 6398e10..72cc4d2 100644
--- a/tools/lib/h5tools_utils.h
+++ b/tools/lib/h5tools_utils.h
@@ -81,27 +81,23 @@ extern int get_option(int argc, const char **argv, const char *opt,
typedef struct obj_t {
haddr_t objno;
char *objname;
- int displayed;
- int recorded;
- int objflag;
+ hbool_t displayed; /* Flag to indicate that the object has been displayed */
+ hbool_t recorded; /* Flag for named datatypes to indicate they were found in the group hierarchy */
} obj_t;
/*struct for the tables that the find_objs function uses*/
typedef struct table_t {
- int size;
- int nobjs;
+ size_t size;
+ size_t nobjs;
obj_t *objs;
} table_t;
/*this struct stores the information that is passed to the find_objs function*/
typedef struct find_objs_t {
- size_t prefix_len;
char *prefix;
- unsigned int threshold; /* should be 0 or 1 */
table_t *group_table;
table_t *type_table;
table_t *dset_table;
- int status;
} find_objs_t;
extern int nCols; /*max number of columns for outputting */
@@ -111,16 +107,13 @@ extern void indentation(int);
extern void print_version(const char *progname);
extern void error_msg(const char *progname, const char *fmt, ...);
extern void warn_msg(const char *progname, const char *fmt, ...);
-extern void free_table(table_t **table);
-extern void dump_table(char *name, table_t *table);
-extern int get_table_idx(table_t *table, haddr_t objno);
-extern int get_tableflag(table_t*, int);
-extern int set_tableflag(table_t*, int);
-extern char *get_objectname(table_t*, int);
-extern herr_t find_objs(hid_t group, const char *name, void *op_data);
-extern int search_obj(table_t *temp, haddr_t objno);
-extern void init_table(table_t **tbl);
-extern void init_prefix(char **temp, size_t);
+extern void free_table(table_t *table);
+#ifdef H5DUMP_DEBUG
+extern void dump_tables(find_objs_t *info)
+#endif /* H5DUMP_DEBUG */
+extern herr_t init_objs(hid_t fid, find_objs_t *info, table_t **group_table,
+ table_t **dset_table, table_t **type_table);
+extern obj_t *search_obj(table_t *temp, haddr_t objno);
#ifndef H5_HAVE_TMPFILE
extern FILE * tmpfile(void);
#endif