MISR Toolkit  1.5.1
H5Gpkg.h
Go to the documentation of this file.
1 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
2  * Copyright by The HDF Group. *
3  * Copyright by the Board of Trustees of the University of Illinois. *
4  * All rights reserved. *
5  * *
6  * This file is part of HDF5. The full HDF5 copyright notice, including *
7  * terms governing use, modification, and redistribution, is contained in *
8  * the COPYING file, which can be found at the root of the source code *
9  * distribution tree, or in https://support.hdfgroup.org/ftp/HDF5/releases. *
10  * If you do not have access to either file, you may request a copy from *
11  * help@hdfgroup.org. *
12  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
13 
14 /*
15  * Programmer: Robb Matzke <matzke@llnl.gov>
16  * Thursday, September 18, 1997
17  *
18  * Purpose: This file contains declarations which are visible
19  * only within the H5G package. Source files outside the
20  * H5G package should include H5Gprivate.h instead.
21  */
22 #ifndef H5G_PACKAGE
23 #error "Do not include this file outside the H5G package!"
24 #endif
25 
26 #ifndef _H5Gpkg_H
27 #define _H5Gpkg_H
28 
29 /* Get package's private header */
30 #include "H5Gprivate.h"
31 
32 /* Other private headers needed by this file */
33 #include "H5B2private.h" /* v2 B-trees */
34 #include "H5FLprivate.h" /* Free Lists */
35 #include "H5HFprivate.h" /* Fractal heaps */
36 #include "H5HLprivate.h" /* Local Heaps */
37 #include "H5Oprivate.h" /* Object headers */
38 #include "H5SLprivate.h" /* Skip lists */
39 
40 /**************************/
41 /* Package Private Macros */
42 /**************************/
43 
44 /* Standard length of fractal heap ID for link */
45 #define H5G_DENSE_FHEAP_ID_LEN 7
46 
47 /* Size of a symbol table node on disk */
48 #define H5G_NODE_SIZE(f) ( \
49  /* General metadata fields */ \
50  H5_SIZEOF_MAGIC \
51  + 1 /* Version */ \
52  + 1 /* Reserved */ \
53  + 2 /* Number of symbols */ \
54  \
55  /* Entries */ \
56  + ((2 * H5F_SYM_LEAF_K(f)) * H5G_SIZEOF_ENTRY(f)) \
57  )
58 
59 
60 /****************************/
61 /* Package Private Typedefs */
62 /****************************/
63 
64 /*
65  * Various types of object header information can be cached in a symbol
66  * table entry (it's normal home is the object header to which the entry
67  * points). This datatype determines what (if anything) is cached in the
68  * symbol table entry.
69  */
70 typedef enum H5G_cache_type_t {
71  H5G_CACHED_ERROR = -1, /*force enum to be signed */
72  H5G_NOTHING_CACHED = 0, /*nothing is cached, must be 0 */
73  H5G_CACHED_STAB = 1, /*symbol table, `stab' */
74  H5G_CACHED_SLINK = 2, /*symbolic link */
75 
76  H5G_NCACHED /*THIS MUST BE LAST */
78 
79 /*
80  * A symbol table entry caches these parameters from object header
81  * messages... The values are entered into the symbol table when an object
82  * header is created (by hand) and are extracted from the symbol table with a
83  * callback function registered in H5O_init_interface(). Be sure to update
84  * H5G_ent_decode(), H5G_ent_encode(), and H5G__ent_debug() as well.
85  */
86 typedef union H5G_cache_t {
87  struct {
88  haddr_t btree_addr; /*file address of symbol table B-tree*/
89  haddr_t heap_addr; /*file address of stab name heap */
90  } stab;
91 
92  struct {
93  size_t lval_offset; /*link value offset */
94  } slink;
95 } H5G_cache_t;
96 
97 /*
98  * A symbol table entry. The two important fields are `name_off' and
99  * `header'. The remaining fields are used for caching information that
100  * also appears in the object header to which this symbol table entry
101  * points.
102  */
103 struct H5G_entry_t {
104  H5G_cache_type_t type; /*type of information cached */
105  H5G_cache_t cache; /*cached data from object header */
106  size_t name_off; /*offset of name within name heap */
107  haddr_t header; /*file address of object header */
108 };
109 
110 /*
111  * A symbol table node is a collection of symbol table entries. It can
112  * be thought of as the lowest level of the B-link tree that points to
113  * a collection of symbol table entries that belong to a specific symbol
114  * table or group.
115  */
116 typedef struct H5G_node_t {
117  H5AC_info_t cache_info; /* Information for H5AC cache functions, _must_ be */
118  /* first field in structure */
119  size_t node_size; /* Size of node on disk */
120  unsigned nsyms; /* Number of symbols */
121  H5G_entry_t *entry; /* Array of symbol table entries */
122 } H5G_node_t;
123 
124 /*
125  * Shared information for all open group objects
126  */
127 struct H5G_shared_t {
128  int fo_count; /* open file object count */
129  hbool_t mounted; /* Group is mount point */
130 };
131 
132 /*
133  * A group handle passed around through layers of the library within and
134  * above the H5G layer.
135  */
136 struct H5G_t {
137  H5G_shared_t *shared; /* Shared file object data */
138  H5O_loc_t oloc; /* Object location for group */
139  H5G_name_t path; /* Group hierarchy path */
140 };
141 
142 /* Link iteration operator for internal library callbacks */
143 typedef herr_t (*H5G_lib_iterate_t)(const H5O_link_t *lnk, void *op_data);
144 
145 /* Data structure to hold table of links for a group */
146 typedef struct {
147  size_t nlinks; /* # of links in table */
148  H5O_link_t *lnks; /* Pointer to array of links */
150 
151 /*
152  * Common data exchange structure for symbol table nodes. This structure is
153  * passed through the B-link tree layer to the methods for the objects
154  * to which the B-link tree points.
155  *
156  * It's also used for B-tree iterators which require no additional info.
157  *
158  */
159 typedef struct H5G_bt_common_t {
160  /* downward */
161  const char *name; /*points to temporary memory */
162  H5HL_t *heap; /*symbol table heap */
164 
165 /*
166  * Data exchange structure for symbol table nodes. This structure is
167  * passed through the B-link tree layer to the insert method for entries.
168  */
169 typedef struct H5G_bt_ins_t {
170  /* downward */
171  H5G_bt_common_t common; /* Common info for B-tree user data (must be first) */
172  const H5O_link_t *lnk; /* Link to insert into table */
173  H5O_type_t obj_type; /* Type of object being inserted */
174  const void *crt_info; /* Creation info for object being inserted */
175 } H5G_bt_ins_t;
176 
177 /*
178  * Data exchange structure for symbol table nodes. This structure is
179  * passed through the B-link tree layer to the remove method for entries.
180  */
181 typedef struct H5G_bt_rm_t {
182  /* downward */
183  H5G_bt_common_t common; /* Common info for B-tree user data (must be first) */
184  H5RS_str_t *grp_full_path_r; /* Full path of group where link is removed */
185 } H5G_bt_rm_t;
186 
187 /* Typedef for B-tree 'find' operation */
188 typedef herr_t (*H5G_bt_find_op_t)(const H5G_entry_t *ent/*in*/, void *operator_data/*in,out*/);
189 
190 /*
191  * Data exchange structure for symbol table nodes. This structure is
192  * passed through the B-link tree layer to the 'find' method for entries.
193  */
194 typedef struct H5G_bt_lkp_t {
195  /* downward */
196  H5G_bt_common_t common; /* Common info for B-tree user data (must be first) */
197  H5G_bt_find_op_t op; /* Operator to call when correct entry is found */
198  void *op_data; /* Data to pass to operator */
199 
200  /* upward */
201 } H5G_bt_lkp_t;
202 
203 /*
204  * Data exchange structure to pass through the B-tree layer for the
205  * H5B_iterate function.
206  */
207 typedef struct H5G_bt_it_it_t {
208  /* downward */
209  H5HL_t *heap; /*symbol table heap */
210  hsize_t skip; /*initial entries to skip */
211  H5G_lib_iterate_t op; /*iteration operator */
212  void *op_data; /*user-defined operator data */
213 
214  /* upward */
215  hsize_t *final_ent; /*final entry looked at */
217 
218 /* Data passed through B-tree iteration for copying copy symbol table content */
219 typedef struct H5G_bt_it_cpy_t {
220  const H5O_loc_t *src_oloc; /* Source object location */
221  haddr_t src_heap_addr; /* Heap address of the source symbol table */
222  H5F_t *dst_file; /* File of destination group */
223  const H5O_stab_t *dst_stab; /* Symbol table message for destination group */
224  H5O_copy_t *cpy_info; /* Information for copy operation */
226 
227 /* Common information for "by index" lookups in symbol tables */
228 typedef struct H5G_bt_it_idx_common_t {
229  /* downward */
230  hsize_t idx; /* Index of group member to be queried */
231  hsize_t num_objs; /* The number of objects having been traversed */
232  H5G_bt_find_op_t op; /* Operator to call when correct entry is found */
234 
235 /* Data passed through B-tree iteration for building a table of the links */
236 typedef struct H5G_bt_it_bt_t {
237  /* downward */
238  size_t alloc_nlinks; /* Number of links allocated in table */
239  H5HL_t *heap; /* Symbol table heap */
240 
241  /* upward */
242  H5G_link_table_t *ltable; /* Link table to add information to */
244 
245 /* Typedefs for "new format" groups */
246 /* (fractal heap & v2 B-tree info) */
247 
248 /* Typedef for native 'name' field index records in the v2 B-tree */
249 /* (Keep 'id' field first so generic record handling in callbacks works) */
250 typedef struct H5G_dense_bt2_name_rec_t {
251  uint8_t id[H5G_DENSE_FHEAP_ID_LEN]; /* Heap ID for link */
252  uint32_t hash; /* Hash of 'name' field value */
254 
255 /* Typedef for native 'creation order' field index records in the v2 B-tree */
256 /* (Keep 'id' field first so generic record handling in callbacks works) */
258  uint8_t id[H5G_DENSE_FHEAP_ID_LEN]; /* Heap ID for link */
259  int64_t corder; /* 'creation order' field value */
261 
262 /*
263  * Common data exchange structure for dense link storage. This structure is
264  * passed through the v2 B-tree layer to the methods for the objects
265  * to which the v2 B-tree points.
266  */
267 typedef struct H5G_bt2_ud_common_t {
268  /* downward */
269  H5F_t *f; /* Pointer to file that fractal heap is in */
270  hid_t dxpl_id; /* DXPL for operation */
271  H5HF_t *fheap; /* Fractal heap handle */
272  const char *name; /* Name of link to compare */
273  uint32_t name_hash; /* Hash of name of link to compare */
274  int64_t corder; /* Creation order value of link to compare */
275  H5B2_found_t found_op; /* Callback when correct link is found */
276  void *found_op_data; /* Callback data when correct link is found */
278 
279 /*
280  * Data exchange structure for dense link storage. This structure is
281  * passed through the v2 B-tree layer when inserting links.
282  */
283 typedef struct H5G_bt2_ud_ins_t {
284  /* downward */
285  H5G_bt2_ud_common_t common; /* Common info for B-tree user data (must be first) */
286  uint8_t id[H5G_DENSE_FHEAP_ID_LEN]; /* Heap ID of link to insert */
288 
289 /* Typedef for group creation operation */
290 typedef struct H5G_obj_create_t{
291  hid_t gcpl_id; /* Group creation property list */
292  H5G_cache_type_t cache_type; /* Type of symbol table entry cache */
293  H5G_cache_t cache; /* Cached data for symbol table entry */
295 
296 /* Callback information for copying groups */
297 typedef struct H5G_copy_file_ud_t {
298  H5O_copy_file_ud_common_t common; /* Shared information (must be first) */
299  H5G_cache_type_t cache_type; /* Type of symbol table entry cache */
300  H5G_cache_t cache; /* Cached data for symbol table entry */
302 
303 
304 /*****************************/
305 /* Package Private Variables */
306 /*****************************/
307 
308 /*
309  * This is the class identifier to give to the B-tree functions.
310  */
311 H5_DLLVAR H5B_class_t H5B_SNODE[1];
312 
313 /* The cache subclass */
314 H5_DLLVAR const H5AC_class_t H5AC_SNODE[1];
315 
316 /* The v2 B-tree class for indexing 'name' field on links */
317 H5_DLLVAR const H5B2_class_t H5G_BT2_NAME[1];
318 
319 /* The v2 B-tree class for indexing 'creation order' field on links */
320 H5_DLLVAR const H5B2_class_t H5G_BT2_CORDER[1];
321 
322 /* Free list for managing H5G_t structs */
324 
325 /* Free list for managing H5G_shared_t structs */
327 
328 /******************************/
329 /* Package Private Prototypes */
330 /******************************/
331 
332 /*
333  * General group routines
334  */
335 H5_DLL H5G_t *H5G__create(H5F_t *file, H5G_obj_create_t *gcrt_info,
336  hid_t dxpl_id);
337 H5_DLL H5G_t *H5G__create_named(const H5G_loc_t *loc, const char *name,
338  hid_t lcpl_id, hid_t gcpl_id, hid_t gapl_id, hid_t dxpl_id);
339 H5_DLL H5G_t *H5G__open_name(const H5G_loc_t *loc, const char *name,
340  hid_t gapl_id, hid_t dxpl_id);
341 
342 /*
343  * Group hierarchy traversal routines
344  */
345 H5_DLL herr_t H5G__traverse_special(const H5G_loc_t *grp_loc,
346  const H5O_link_t *lnk, unsigned target, size_t *nlinks, hbool_t last_comp,
347  H5G_loc_t *obj_loc, hbool_t *obj_exists, hid_t lapl_id, hid_t dxpl_id);
348 
349 /*
350  * Utility functions
351  */
352 H5_DLL herr_t H5G__init(void);
354 H5_DLL const char *H5G__component(const char *name, size_t *size_p);
355 
356 /*
357  * Functions that understand symbol tables but not names. The
358  * functions that understand names are exported to the rest of
359  * the library and appear in H5Gprivate.h.
360  */
361 H5_DLL herr_t H5G__stab_create(H5O_loc_t *grp_oloc, hid_t dxpl_id,
362  const H5O_ginfo_t *ginfo, H5O_stab_t *stab);
363 H5_DLL herr_t H5G__stab_create_components(H5F_t *f, H5O_stab_t *stab, size_t size_hint, hid_t dxpl_id);
364 H5_DLL herr_t H5G__stab_insert(const H5O_loc_t *grp_oloc, const char *name,
365  H5O_link_t *obj_lnk, H5O_type_t obj_type, const void *crt_info,
366  hid_t dxpl_id);
367 H5_DLL herr_t H5G__stab_insert_real(H5F_t *f, const H5O_stab_t *stab,
368  const char *name, H5O_link_t *obj_lnk, H5O_type_t obj_type,
369  const void *crt_info, hid_t dxpl_id);
370 H5_DLL herr_t H5G__stab_delete(H5F_t *f, hid_t dxpl_id, const H5O_stab_t *stab);
371 H5_DLL herr_t H5G__stab_iterate(const H5O_loc_t *oloc, hid_t dxpl_id, H5_iter_order_t order,
372  hsize_t skip, hsize_t *last_lnk, H5G_lib_iterate_t op, void *op_data);
373 H5_DLL herr_t H5G__stab_count(struct H5O_loc_t *oloc, hsize_t *num_objs, hid_t dxpl_id);
374 H5_DLL herr_t H5G__stab_bh_size(H5F_t *f, hid_t dxpl_id, const H5O_stab_t *stab,
375  H5_ih_info_t *bh_info);
377  hsize_t n, char* name, size_t size, hid_t dxpl_id);
378 H5_DLL herr_t H5G__stab_remove(const H5O_loc_t *oloc, hid_t dxpl_id,
379  H5RS_str_t *grp_full_path_r, const char *name);
380 H5_DLL herr_t H5G__stab_remove_by_idx(const H5O_loc_t *oloc, hid_t dxpl_id,
381  H5RS_str_t *grp_full_path_r, H5_iter_order_t order, hsize_t n);
382 H5_DLL herr_t H5G__stab_lookup(const H5O_loc_t *grp_oloc, const char *name,
383  H5O_link_t *lnk, hid_t dxpl_id);
384 H5_DLL herr_t H5G__stab_lookup_by_idx(const H5O_loc_t *grp_oloc, H5_iter_order_t order,
385  hsize_t n, H5O_link_t *lnk, hid_t dxpl_id);
386 #ifndef H5_STRICT_FORMAT_CHECKS
387 H5_DLL herr_t H5G__stab_valid(H5O_loc_t *grp_oloc, hid_t dxpl_id,
388  H5O_stab_t *alt_stab);
389 #endif /* H5_STRICT_FORMAT_CHECKS */
390 #ifndef H5_NO_DEPRECATED_SYMBOLS
392  hid_t dxpl_id);
393 #endif /* H5_NO_DEPRECATED_SYMBOLS */
394 
395 
396 /*
397  * Functions that understand symbol table entries.
398  */
399 H5_DLL void H5G__ent_copy(H5G_entry_t *dst, const H5G_entry_t *src,
400  H5_copy_depth_t depth);
402 H5_DLL herr_t H5G__ent_decode_vec(const H5F_t *f, const uint8_t **pp,
403  const uint8_t *p_end, H5G_entry_t *ent, unsigned n);
404 H5_DLL herr_t H5G__ent_encode_vec(const H5F_t *f, uint8_t **pp,
405  const H5G_entry_t *ent, unsigned n);
406 H5_DLL herr_t H5G__ent_convert(H5F_t *f, hid_t dxpl_id, H5HL_t *heap,
407  const char *name, const H5O_link_t *lnk, H5O_type_t obj_type,
408  const void *crt_info, H5G_entry_t *ent);
409 H5_DLL herr_t H5G__ent_debug(const H5G_entry_t *ent, FILE * stream, int indent,
410  int fwidth, const H5HL_t *heap);
411 
412 /* Functions that understand symbol table nodes */
414 H5_DLL int H5G__node_iterate(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr,
415  const void *_rt_key, void *_udata);
416 H5_DLL int H5G__node_sumup(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr,
417  const void *_rt_key, void *_udata);
418 H5_DLL int H5G__node_by_idx(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr,
419  const void *_rt_key, void *_udata);
420 H5_DLL int H5G__node_copy(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr,
421  const void *_rt_key, void *_udata);
422 H5_DLL int H5G__node_build_table(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr,
423  const void *_rt_key, void *_udata);
424 H5_DLL herr_t H5G__node_iterate_size(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr,
425  const void *_rt_key, void *_udata);
427 
428 /* Functions that understand links in groups */
429 H5_DLL herr_t H5G__ent_to_link(H5O_link_t *lnk, const H5HL_t *heap,
430  const H5G_entry_t *ent, const char *name);
431 H5_DLL herr_t H5G__link_to_loc(const H5G_loc_t *grp_loc, const H5O_link_t *lnk,
432  H5G_loc_t *obj_loc);
436  hsize_t skip, hsize_t *last_lnk, const H5G_lib_iterate_t op, void *op_data);
439  H5RS_str_t *grp_full_path_r, const H5O_link_t *lnk);
440 
441 /* Functions that understand "compact" link storage */
442 H5_DLL herr_t H5G__compact_insert(const H5O_loc_t *grp_oloc, H5O_link_t *obj_lnk,
443  hid_t dxpl_id);
444 H5_DLL ssize_t H5G__compact_get_name_by_idx(const H5O_loc_t *oloc, hid_t dxpl_id,
445  const H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order,
446  hsize_t idx, char *name, size_t size);
447 H5_DLL herr_t H5G__compact_remove(const H5O_loc_t *oloc, hid_t dxpl_id,
448  H5RS_str_t *grp_full_path_r, const char *name);
449 H5_DLL herr_t H5G__compact_remove_by_idx(const H5O_loc_t *oloc, hid_t dxpl_id,
450  const H5O_linfo_t *linfo, H5RS_str_t *grp_full_path_r, H5_index_t idx_type,
452 H5_DLL herr_t H5G__compact_iterate(const H5O_loc_t *oloc, hid_t dxpl_id,
453  const H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order,
454  hsize_t skip, hsize_t *last_lnk, H5G_lib_iterate_t op, void *op_data);
455 H5_DLL htri_t H5G__compact_lookup(const H5O_loc_t *grp_oloc, const char *name,
456  H5O_link_t *lnk, hid_t dxpl_id);
457 H5_DLL herr_t H5G__compact_lookup_by_idx(const H5O_loc_t *oloc, hid_t dxpl_id,
458  const H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order,
459  hsize_t n, H5O_link_t *lnk);
460 #ifndef H5_NO_DEPRECATED_SYMBOLS
461 H5_DLL H5G_obj_t H5G__compact_get_type_by_idx(H5O_loc_t *oloc, hid_t dxpl_id,
462  const H5O_linfo_t *linfo, hsize_t idx);
463 #endif /* H5_NO_DEPRECATED_SYMBOLS */
464 
465 /* Functions that understand "dense" link storage */
466 H5_DLL herr_t H5G__dense_build_table(H5F_t *f, hid_t dxpl_id, const H5O_linfo_t *linfo,
467  H5_index_t idx_type, H5_iter_order_t order, H5G_link_table_t *ltable);
468 H5_DLL herr_t H5G__dense_create(H5F_t *f, hid_t dxpl_id, H5O_linfo_t *linfo,
469  const H5O_pline_t *pline);
471  const H5O_linfo_t *linfo, const H5O_link_t *lnk);
473  const H5O_linfo_t *linfo, const char *name, H5O_link_t *lnk);
475  const H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order,
476  hsize_t n, H5O_link_t *lnk);
477 H5_DLL herr_t H5G__dense_iterate(H5F_t *f, hid_t dxpl_id, const H5O_linfo_t *linfo,
478  H5_index_t idx_type, H5_iter_order_t order, hsize_t skip, hsize_t *last_lnk,
479  H5G_lib_iterate_t op, void *op_data);
481  H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order, hsize_t n,
482  char *name, size_t size);
483 H5_DLL herr_t H5G__dense_remove(H5F_t *f, hid_t dxpl_id, const H5O_linfo_t *linfo,
484  H5RS_str_t *grp_full_path_r, const char *name);
486  const H5O_linfo_t *linfo, H5RS_str_t *grp_full_path_r, H5_index_t idx_type,
488 H5_DLL herr_t H5G__dense_delete(H5F_t *f, hid_t dxpl_id, H5O_linfo_t *linfo,
489  hbool_t adj_link);
490 #ifndef H5_NO_DEPRECATED_SYMBOLS
492  H5O_linfo_t *linfo, hsize_t idx);
493 #endif /* H5_NO_DEPRECATED_SYMBOLS */
494 
495 /* Functions that understand group objects */
497  H5G_obj_create_t *gcrt_info, H5O_loc_t *oloc/*out*/);
499  const H5O_ginfo_t *ginfo, const H5O_linfo_t *linfo,
500  const H5O_pline_t *pline, H5G_obj_create_t *gcrt_info,
501  H5O_loc_t *oloc/*out*/);
502 H5_DLL htri_t H5G__obj_get_linfo(const H5O_loc_t *grp_oloc, H5O_linfo_t *linfo,
503  hid_t dxpl_id);
504 H5_DLL herr_t H5G__obj_iterate(const H5O_loc_t *grp_oloc,
505  H5_index_t idx_type, H5_iter_order_t order, hsize_t skip, hsize_t *last_lnk,
506  H5G_lib_iterate_t op, void *op_data, hid_t dxpl_id);
507 H5_DLL herr_t H5G__obj_info(H5O_loc_t *oloc, H5G_info_t *grp_info, hid_t dxpl_id);
508 H5_DLL htri_t H5G__obj_lookup(const H5O_loc_t *grp_oloc, const char *name,
509  H5O_link_t *lnk, hid_t dxpl_id);
510 
511 /*
512  * These functions operate on group hierarchy names.
513  */
514 H5_DLL herr_t H5G__name_init(H5G_name_t *name, const char *path);
515 
516 /*
517  * These functions operate on group "locations"
518  */
519 H5_DLL herr_t H5G__loc_copy(H5G_loc_t *dst, const H5G_loc_t *src, H5_copy_depth_t depth);
520 H5_DLL herr_t H5G__loc_insert(H5G_loc_t *grp_loc, const char *name,
521  H5G_loc_t *obj_loc, H5O_type_t obj_type, const void *crt_info, hid_t dxpl_id);
522 
523 /* Testing functions */
524 #ifdef H5G_TESTING
525 H5_DLL htri_t H5G__is_empty_test(hid_t gid);
526 H5_DLL htri_t H5G__has_links_test(hid_t gid, unsigned *nmsgs);
527 H5_DLL htri_t H5G__has_stab_test(hid_t gid);
528 H5_DLL htri_t H5G__is_new_dense_test(hid_t gid);
529 H5_DLL herr_t H5G__new_dense_info_test(hid_t gid, hsize_t *name_count, hsize_t *corder_count);
530 H5_DLL herr_t H5G__lheap_size_test(hid_t gid, size_t *lheap_size);
531 H5_DLL herr_t H5G__user_path_test(hid_t obj_id, char *user_path, size_t *user_path_len, unsigned *user_path_hidden);
532 H5_DLL herr_t H5G__verify_cached_stab_test(H5O_loc_t *grp_oloc, H5G_entry_t *ent);
533 H5_DLL herr_t H5G__verify_cached_stabs_test(hid_t gid);
534 #endif /* H5G_TESTING */
535 
536 #endif /* _H5Gpkg_H */
537 
H5O_copy_file_ud_common_t common
Definition: H5Gpkg.h:298
hbool_t mounted
Definition: H5Gpkg.h:129
H5HL_t * heap
Definition: H5Gpkg.h:209
H5_DLL herr_t H5G__stab_iterate(const H5O_loc_t *oloc, hid_t dxpl_id, H5_iter_order_t order, hsize_t skip, hsize_t *last_lnk, H5G_lib_iterate_t op, void *op_data)
H5_DLLVAR const H5B2_class_t H5G_BT2_CORDER[1]
Definition: H5Gpkg.h:320
H5G_cache_type_t type
Definition: H5Gpkg.h:104
H5G_bt_common_t common
Definition: H5Gpkg.h:171
unsigned int hbool_t
Definition: H5public.h:142
#define H5G_DENSE_FHEAP_ID_LEN
Definition: H5Gpkg.h:45
H5_DLL herr_t H5G__compact_remove_by_idx(const H5O_loc_t *oloc, hid_t dxpl_id, const H5O_linfo_t *linfo, H5RS_str_t *grp_full_path_r, H5_index_t idx_type, H5_iter_order_t order, hsize_t n)
H5_DLLVAR H5B_class_t H5B_SNODE[1]
Definition: H5Gpkg.h:311
struct H5G_bt2_ud_common_t H5G_bt2_ud_common_t
struct H5G_bt_rm_t H5G_bt_rm_t
haddr_t src_heap_addr
Definition: H5Gpkg.h:221
hsize_t skip
Definition: H5Gpkg.h:210
HDFFCLIBAPI intf * idx
H5_DLL herr_t H5G__obj_create(H5F_t *f, hid_t dxpl_id, H5G_obj_create_t *gcrt_info, H5O_loc_t *oloc)
Definition: H5Gpkg.h:136
H5_DLL herr_t H5G__dense_iterate(H5F_t *f, hid_t dxpl_id, const H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order, hsize_t skip, hsize_t *last_lnk, H5G_lib_iterate_t op, void *op_data)
H5G_entry_t * entry
Definition: H5Gpkg.h:121
H5_DLL herr_t H5G__stab_lookup_by_idx(const H5O_loc_t *grp_oloc, H5_iter_order_t order, hsize_t n, H5O_link_t *lnk, hid_t dxpl_id)
H5AC_info_t cache_info
Definition: H5Gpkg.h:117
haddr_t heap_addr
Definition: H5Gpkg.h:89
H5_DLL htri_t H5G__compact_lookup(const H5O_loc_t *grp_oloc, const char *name, H5O_link_t *lnk, hid_t dxpl_id)
H5_index_t
Definition: H5public.h:305
herr_t(* H5G_bt_find_op_t)(const H5G_entry_t *ent, void *operator_data)
Definition: H5Gpkg.h:188
H5_DLL herr_t H5G__obj_create_real(H5F_t *f, hid_t dxpl_id, const H5O_ginfo_t *ginfo, const H5O_linfo_t *linfo, const H5O_pline_t *pline, H5G_obj_create_t *gcrt_info, H5O_loc_t *oloc)
long long ssize_t
Definition: H5public.h:156
#define H5_DLL
Definition: H5api_adpt.h:256
struct H5G_dense_bt2_corder_rec_t H5G_dense_bt2_corder_rec_t
H5_DLL herr_t H5G__link_release_table(H5G_link_table_t *ltable)
H5_DLL void H5G__ent_copy(H5G_entry_t *dst, const H5G_entry_t *src, H5_copy_depth_t depth)
int herr_t
Definition: H5public.h:124
H5HL_t * heap
Definition: H5Gpkg.h:162
H5G_cache_t cache
Definition: H5Gpkg.h:300
const char * name
Definition: H5Gpkg.h:272
Definition: H5Gpkg.h:103
H5G_cache_t cache
Definition: H5Gpkg.h:105
H5B2_found_t found_op
Definition: H5Gpkg.h:275
hid_t gcpl_id
Definition: H5Gpkg.h:291
H5O_type_t obj_type
Definition: H5Gpkg.h:173
H5_DLL H5G_obj_t H5G__dense_get_type_by_idx(H5F_t *f, hid_t dxpl_id, H5O_linfo_t *linfo, hsize_t idx)
H5_DLL int H5G__node_by_idx(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr, const void *_rt_key, void *_udata)
struct H5G_bt2_ud_ins_t H5G_bt2_ud_ins_t
unsigned long long hsize_t
Definition: H5public.h:169
hsize_t * final_ent
Definition: H5Gpkg.h:215
H5_DLL herr_t H5G__stab_remove_by_idx(const H5O_loc_t *oloc, hid_t dxpl_id, H5RS_str_t *grp_full_path_r, H5_iter_order_t order, hsize_t n)
H5RS_str_t * grp_full_path_r
Definition: H5Gpkg.h:184
H5_DLL herr_t H5G__dense_insert(H5F_t *f, hid_t dxpl_id, const H5O_linfo_t *linfo, const H5O_link_t *lnk)
struct H5G_cache_t::@26 stab
H5O_type_t
Definition: H5Opublic.h:81
H5_DLL herr_t H5G__loc_copy(H5G_loc_t *dst, const H5G_loc_t *src, H5_copy_depth_t depth)
Definition: H5HLpkg.h:84
H5_DLL int H5G__node_iterate(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr, const void *_rt_key, void *_udata)
H5HL_t * heap
Definition: H5Gpkg.h:239
H5_DLL ssize_t H5G__compact_get_name_by_idx(const H5O_loc_t *oloc, hid_t dxpl_id, const H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order, hsize_t idx, char *name, size_t size)
H5_DLL herr_t H5G__node_iterate_size(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr, const void *_rt_key, void *_udata)
H5G_name_t path
Definition: H5Gpkg.h:139
H5_DLL herr_t H5G__link_name_replace(H5F_t *file, hid_t dxpl_id, H5RS_str_t *grp_full_path_r, const H5O_link_t *lnk)
H5F_t * dst_file
Definition: H5Gpkg.h:222
H5G_lib_iterate_t op
Definition: H5Gpkg.h:211
H5_DLL htri_t H5G__dense_lookup(H5F_t *f, hid_t dxpl_id, const H5O_linfo_t *linfo, const char *name, H5O_link_t *lnk)
H5O_copy_t * cpy_info
Definition: H5Gpkg.h:224
size_t alloc_nlinks
Definition: H5Gpkg.h:238
H5_DLL herr_t H5G__stab_insert(const H5O_loc_t *grp_oloc, const char *name, H5O_link_t *obj_lnk, H5O_type_t obj_type, const void *crt_info, hid_t dxpl_id)
H5_DLL htri_t H5G__obj_lookup(const H5O_loc_t *grp_oloc, const char *name, H5O_link_t *lnk, hid_t dxpl_id)
H5_DLL H5G_obj_t H5G__stab_get_type_by_idx(H5O_loc_t *oloc, hsize_t idx, hid_t dxpl_id)
H5_DLLVAR const H5B2_class_t H5G_BT2_NAME[1]
Definition: H5Gpkg.h:317
H5_DLL herr_t H5G__link_to_loc(const H5G_loc_t *grp_loc, const H5O_link_t *lnk, H5G_loc_t *obj_loc)
H5_DLL herr_t H5G__ent_encode_vec(const H5F_t *f, uint8_t **pp, const H5G_entry_t *ent, unsigned n)
H5_DLL herr_t H5G__ent_debug(const H5G_entry_t *ent, FILE *stream, int indent, int fwidth, const H5HL_t *heap)
uint64_t haddr_t
Definition: H5public.h:182
H5_DLL herr_t H5G__dense_remove(H5F_t *f, hid_t dxpl_id, const H5O_linfo_t *linfo, H5RS_str_t *grp_full_path_r, const char *name)
HDFFCLIBAPI _fcd name
H5G_cache_type_t cache_type
Definition: H5Gpkg.h:299
H5_DLL herr_t H5G__stab_create(H5O_loc_t *grp_oloc, hid_t dxpl_id, const H5O_ginfo_t *ginfo, H5O_stab_t *stab)
H5G_bt_find_op_t op
Definition: H5Gpkg.h:197
H5_DLLVAR const H5AC_class_t H5AC_SNODE[1]
Definition: H5Gpkg.h:314
struct H5G_node_t H5G_node_t
void * op_data
Definition: H5Gpkg.h:212
H5O_loc_t oloc
Definition: H5Gpkg.h:138
haddr_t btree_addr
Definition: H5Gpkg.h:88
H5_iter_order_t
Definition: H5public.h:284
H5_DLL herr_t H5G__dense_delete(H5F_t *f, hid_t dxpl_id, H5O_linfo_t *linfo, hbool_t adj_link)
struct H5G_bt_common_t H5G_bt_common_t
HDFFCLIBAPI _fcd intf intf * order
H5_DLL herr_t H5G__obj_iterate(const H5O_loc_t *grp_oloc, H5_index_t idx_type, H5_iter_order_t order, hsize_t skip, hsize_t *last_lnk, H5G_lib_iterate_t op, void *op_data, hid_t dxpl_id)
H5_DLL void H5G__ent_reset(H5G_entry_t *ent)
H5_DLL H5G_t * H5G__open_name(const H5G_loc_t *loc, const char *name, hid_t gapl_id, hid_t dxpl_id)
H5_DLL herr_t H5G__link_sort_table(H5G_link_table_t *ltable, H5_index_t idx_type, H5_iter_order_t order)
struct H5G_obj_create_t H5G_obj_create_t
H5_DLL int H5G__node_copy(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr, const void *_rt_key, void *_udata)
struct H5G_cache_t::@27 slink
H5G_cache_t cache
Definition: H5Gpkg.h:293
H5G_bt2_ud_common_t common
Definition: H5Gpkg.h:285
H5_DLL herr_t H5G__compact_iterate(const H5O_loc_t *oloc, hid_t dxpl_id, const H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order, hsize_t skip, hsize_t *last_lnk, H5G_lib_iterate_t op, void *op_data)
const H5O_link_t * lnk
Definition: H5Gpkg.h:172
size_t lval_offset
Definition: H5Gpkg.h:93
H5_DLL herr_t H5G__stab_create_components(H5F_t *f, H5O_stab_t *stab, size_t size_hint, hid_t dxpl_id)
struct H5G_bt_ins_t H5G_bt_ins_t
HDFFCLIBAPI intf * size
int hid_t
Definition: H5Ipublic.h:54
H5_DLL herr_t H5G__obj_info(H5O_loc_t *oloc, H5G_info_t *grp_info, hid_t dxpl_id)
H5_DLL herr_t H5G__compact_insert(const H5O_loc_t *grp_oloc, H5O_link_t *obj_lnk, hid_t dxpl_id)
H5_DLL herr_t H5G__dense_create(H5F_t *f, hid_t dxpl_id, H5O_linfo_t *linfo, const H5O_pline_t *pline)
H5_DLL herr_t H5G__ent_to_link(H5O_link_t *lnk, const H5HL_t *heap, const H5G_entry_t *ent, const char *name)
HDFFCLIBAPI _fcd _fcd intf * n
H5_DLL herr_t H5G__stab_count(struct H5O_loc_t *oloc, hsize_t *num_objs, hid_t dxpl_id)
struct H5G_bt_it_bt_t H5G_bt_it_bt_t
H5_DLL herr_t H5G__compact_remove(const H5O_loc_t *oloc, hid_t dxpl_id, H5RS_str_t *grp_full_path_r, const char *name)
struct H5G_copy_file_ud_t H5G_copy_file_ud_t
size_t node_size
Definition: H5Gpkg.h:119
H5_DLL herr_t H5G__stab_lookup(const H5O_loc_t *grp_oloc, const char *name, H5O_link_t *lnk, hid_t dxpl_id)
H5_DLL herr_t H5G__term_deprec_interface(void)
H5_DLL ssize_t H5G__stab_get_name_by_idx(const H5O_loc_t *oloc, H5_iter_order_t order, hsize_t n, char *name, size_t size, hid_t dxpl_id)
union H5G_cache_t H5G_cache_t
void * found_op_data
Definition: H5Gpkg.h:276
H5_DLL herr_t H5G__traverse_special(const H5G_loc_t *grp_loc, const H5O_link_t *lnk, unsigned target, size_t *nlinks, hbool_t last_comp, H5G_loc_t *obj_loc, hbool_t *obj_exists, hid_t lapl_id, hid_t dxpl_id)
struct H5G_bt_it_it_t H5G_bt_it_it_t
H5_DLL herr_t H5G__compact_lookup_by_idx(const H5O_loc_t *oloc, hid_t dxpl_id, const H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order, hsize_t n, H5O_link_t *lnk)
H5_DLL herr_t H5G__stab_insert_real(H5F_t *f, const H5O_stab_t *stab, const char *name, H5O_link_t *obj_lnk, H5O_type_t obj_type, const void *crt_info, hid_t dxpl_id)
uint32_t name_hash
Definition: H5Gpkg.h:273
unsigned nsyms
Definition: H5Gpkg.h:120
H5HF_t * fheap
Definition: H5Gpkg.h:271
const H5O_loc_t * src_oloc
Definition: H5Gpkg.h:220
H5_DLL herr_t H5G__link_iterate_table(const H5G_link_table_t *ltable, hsize_t skip, hsize_t *last_lnk, const H5G_lib_iterate_t op, void *op_data)
H5_DLL herr_t H5G__stab_delete(H5F_t *f, hid_t dxpl_id, const H5O_stab_t *stab)
int fo_count
Definition: H5Gpkg.h:128
H5_DLL int H5G__node_build_table(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr, const void *_rt_key, void *_udata)
H5G_bt_find_op_t op
Definition: H5Gpkg.h:232
const void * crt_info
Definition: H5Gpkg.h:174
H5_DLL herr_t H5G__node_init(H5F_t *f)
H5G_bt_common_t common
Definition: H5Gpkg.h:183
H5G_bt_common_t common
Definition: H5Gpkg.h:196
struct H5G_bt_lkp_t H5G_bt_lkp_t
H5_DLL herr_t H5G__init(void)
#define H5_DLLVAR
Definition: H5api_adpt.h:257
H5_DLL herr_t H5G__stab_remove(const H5O_loc_t *oloc, hid_t dxpl_id, H5RS_str_t *grp_full_path_r, const char *name)
struct H5G_bt_it_idx_common_t H5G_bt_it_idx_common_t
const char * name
Definition: H5Gpkg.h:161
H5_DLL herr_t H5G__ent_convert(H5F_t *f, hid_t dxpl_id, H5HL_t *heap, const char *name, const H5O_link_t *lnk, H5O_type_t obj_type, const void *crt_info, H5G_entry_t *ent)
size_t name_off
Definition: H5Gpkg.h:106
H5_DLL herr_t H5G__loc_insert(H5G_loc_t *grp_loc, const char *name, H5G_loc_t *obj_loc, H5O_type_t obj_type, const void *crt_info, hid_t dxpl_id)
int64_t corder
Definition: H5Gpkg.h:274
H5_DLL herr_t H5G__node_free(H5G_node_t *sym)
H5G_obj_t
Definition: H5Gpublic.h:117
H5_DLL H5G_obj_t H5G__compact_get_type_by_idx(H5O_loc_t *oloc, hid_t dxpl_id, const H5O_linfo_t *linfo, hsize_t idx)
H5_DLL herr_t H5G__stab_bh_size(H5F_t *f, hid_t dxpl_id, const H5O_stab_t *stab, H5_ih_info_t *bh_info)
H5_DLL herr_t H5G__stab_valid(H5O_loc_t *grp_oloc, hid_t dxpl_id, H5O_stab_t *alt_stab)
H5_DLL ssize_t H5G__dense_get_name_by_idx(H5F_t *f, hid_t dxpl_id, H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order, hsize_t n, char *name, size_t size)
haddr_t header
Definition: H5Gpkg.h:107
H5FL_EXTERN(H5G_t)
H5_DLL herr_t H5G__dense_lookup_by_idx(H5F_t *f, hid_t dxpl_id, const H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order, hsize_t n, H5O_link_t *lnk)
H5_DLL herr_t H5G__name_init(H5G_name_t *name, const char *path)
int htri_t
Definition: H5public.h:143
H5_DLL int H5G__node_sumup(H5F_t *f, hid_t dxpl_id, const void *_lt_key, haddr_t addr, const void *_rt_key, void *_udata)
void * op_data
Definition: H5Gpkg.h:198
H5G_link_table_t * ltable
Definition: H5Gpkg.h:242
H5_DLL H5G_t * H5G__create_named(const H5G_loc_t *loc, const char *name, hid_t lcpl_id, hid_t gcpl_id, hid_t gapl_id, hid_t dxpl_id)
struct H5G_dense_bt2_name_rec_t H5G_dense_bt2_name_rec_t
H5_DLL herr_t H5G__ent_decode_vec(const H5F_t *f, const uint8_t **pp, const uint8_t *p_end, H5G_entry_t *ent, unsigned n)
herr_t(* H5G_lib_iterate_t)(const H5O_link_t *lnk, void *op_data)
Definition: H5Gpkg.h:143
const H5O_stab_t * dst_stab
Definition: H5Gpkg.h:223
H5G_shared_t * shared
Definition: H5Gpkg.h:137
H5_DLL herr_t H5G__dense_remove_by_idx(H5F_t *f, hid_t dxpl_id, const H5O_linfo_t *linfo, H5RS_str_t *grp_full_path_r, H5_index_t idx_type, H5_iter_order_t order, hsize_t n)
H5_DLL herr_t H5G__dense_build_table(H5F_t *f, hid_t dxpl_id, const H5O_linfo_t *linfo, H5_index_t idx_type, H5_iter_order_t order, H5G_link_table_t *ltable)
H5_DLL htri_t H5G__obj_get_linfo(const H5O_loc_t *grp_oloc, H5O_linfo_t *linfo, hid_t dxpl_id)
H5G_cache_type_t cache_type
Definition: H5Gpkg.h:292
H5_DLL const char * H5G__component(const char *name, size_t *size_p)
struct H5G_bt_it_cpy_t H5G_bt_it_cpy_t
Definition: H5Fpkg.h:255
H5_DLL H5G_t * H5G__create(H5F_t *file, H5G_obj_create_t *gcrt_info, hid_t dxpl_id)
H5G_cache_type_t
Definition: H5Gpkg.h:70

MISR Toolkit - Copyright © 2005 - 2020 Jet Propulsion Laboratory
Generated on Fri Jun 19 2020 22:49:52