diff options
Diffstat (limited to 'tools/lib/h5tools.h')
-rw-r--r-- | tools/lib/h5tools.h | 64 |
1 files changed, 33 insertions, 31 deletions
diff --git a/tools/lib/h5tools.h b/tools/lib/h5tools.h index 59cc42f..7229031 100644 --- a/tools/lib/h5tools.h +++ b/tools/lib/h5tools.h @@ -453,10 +453,10 @@ typedef struct h5tool_format_t { /*used to skip the first set of checks for line length*/ int skip_first; - /*flag used to hide or show the file number for obj refs*/ + /*flag used to hide or show the file number for object refs*/ int obj_hidefileno; - /*string used to format the output for the obje refs*/ + /*string used to format the output for the object refs*/ const char *obj_format; /*flag used to hide or show the file number for dataset regions*/ @@ -477,27 +477,6 @@ typedef struct h5tool_format_t { } h5tool_format_t; -typedef struct h5tools_context_t { - size_t cur_column; /*current column for output */ - size_t cur_elmt; /*current element/output line */ - int need_prefix; /*is line prefix needed? */ - unsigned ndims; /*dimensionality */ - hsize_t p_min_idx[H5S_MAX_RANK]; /*min selected index */ - hsize_t p_max_idx[H5S_MAX_RANK]; /*max selected index */ - int prev_multiline; /*was prev datum multiline? */ - size_t prev_prefix_len; /*length of previous prefix */ - int continuation; /*continuation of previous data?*/ - hsize_t size_last_dim; /*the size of the last dimension, - *needed so we can break after each - *row */ - unsigned indent_level; /*the number of times we need some - *extra indentation */ - unsigned default_indent_level; /*this is used when the indent level gets changed */ - hsize_t acc[H5S_MAX_RANK]; /* accumulator position */ - hsize_t pos[H5S_MAX_RANK]; /* matrix position */ - hsize_t sm_pos; /* current stripmine element position */ -} h5tools_context_t; - typedef struct subset_d { hsize_t *data; unsigned int len; @@ -511,6 +490,27 @@ struct subset_t { subset_d block; }; +typedef struct h5tools_context_t { + size_t cur_column; /* current column for output */ + size_t cur_elmt; /* current element/output line */ + int need_prefix; /* is line prefix needed? */ + unsigned ndims; /* dimensionality */ + hsize_t p_min_idx[H5S_MAX_RANK]; /* min selected index */ + hsize_t p_max_idx[H5S_MAX_RANK]; /* max selected index */ + int prev_multiline; /* was prev datum multiline? */ + size_t prev_prefix_len; /* length of previous prefix */ + int continuation; /* continuation of previous data?*/ + hsize_t size_last_dim; /* the size of the last dimension, needed so we can break after each row */ + unsigned indent_level; /* the number of times we need some extra indentation */ + unsigned default_indent_level; /* this is used when the indent level gets changed */ + hsize_t acc[H5S_MAX_RANK]; /* accumulator position */ + hsize_t pos[H5S_MAX_RANK]; /* matrix position */ + hsize_t sm_pos; /* current stripmine element position */ + struct subset_t *sset; /* subsetting parameters */ + int display_index; /* */ + int display_char; /* */ +} h5tools_context_t; + /* The following include, h5tools_str.h, must be after the * above stucts are defined. There is a dependency in the following * include that hasn't been identified yet. */ @@ -542,8 +542,8 @@ H5TOOLS_DLLVAR int data_output; /* data output */ H5TOOLS_DLLVAR int attr_data_output; /* attribute data output */ /* sort parameters */ -H5TOOLS_DLLVAR H5_index_t sort_by; /*sort_by [creation_order | name] */ -H5TOOLS_DLLVAR H5_iter_order_t sort_order; /*sort_order [ascending | descending] */ +H5TOOLS_DLLVAR H5_index_t sort_by; /* sort_by [creation_order | name] */ +H5TOOLS_DLLVAR H5_iter_order_t sort_order; /* sort_order [ascending | descending] */ /* things to display or which are set via command line parameters */ H5TOOLS_DLLVAR int enable_error_stack; /* re-enable error stack; disable=0 enable=1 */ @@ -552,6 +552,8 @@ H5TOOLS_DLLVAR int enable_error_stack; /* re-enable error stack; disable=0 e #define H5_TOOLS_GROUP "GROUP" #define H5_TOOLS_DATASET "DATASET" #define H5_TOOLS_DATATYPE "DATATYPE" +#define H5_TOOLS_ATTRIBUTE "ATTRIBUTE" +#define H5_TOOLS_UNKNOWN "UNKNOWN" /* Definitions of useful routines */ H5TOOLS_DLL void h5tools_init(void); @@ -592,12 +594,12 @@ H5TOOLS_DLL hbool_t h5tools_render_element(FILE *stream, const h5tool_format_t * h5tools_context_t *ctx, h5tools_str_t *buffer, hsize_t *curr_pos, size_t ncols, hsize_t local_elmt_counter, hsize_t elmt_counter); H5TOOLS_DLL hbool_t h5tools_render_region_element(FILE *stream, const h5tool_format_t *info, - h5tools_context_t *ctx/*in,out*/, - h5tools_str_t *buffer/*string into which to render */, - hsize_t *curr_pos/*total data element position*/, - size_t ncols, hsize_t *ptdata, - hsize_t local_elmt_counter/*element counter*/, - hsize_t elmt_counter); + h5tools_context_t *ctx, /*in,out*/ + h5tools_str_t *buffer, /*string into which to render */ + hsize_t *curr_pos, /*total data element position*/ + size_t ncols, hsize_t *ptdata, + hsize_t local_elmt_counter, /*element counter*/ + hsize_t elmt_counter); #ifdef __cplusplus } |