summaryrefslogtreecommitdiffstats
path: root/develop/group___h5.html
blob: d0b982a08285001dcef8da368fc1415a576d1b3f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.10.0"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>HDF5: Library General (H5)</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript" src="cookie.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
  $(function() { init_search(); });
/* @license-end */
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="hdf5doxy.css" rel="stylesheet" type="text/css">
<!-- <link href="hdf5doxy.css" rel="stylesheet" type="text/css"/>
 -->
<script type="text/javascript" src="hdf5_navtree_hacks.js"></script>
</head>
<body>
<div style="background:#FFDDDD;font-size:120%;text-align:center;margin:0;padding:5px">Please, help us to better serve our user community by answering the following short survey:  <a href="https://www.hdfgroup.org/website-survey/">https://www.hdfgroup.org/website-survey/</a></div>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="HDFG-logo.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname"><a href="https://www.hdfgroup.org">HDF5</a>
   &#160;<span id="projectnumber">1.15.0.68e8c0e</span>
   </div>
   <div id="projectbrief">API Reference</div>
  </td>
   <td>        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <span id="MSearchSelect"                onmouseover="return searchBox.OnSearchSelectShow()"                onmouseout="return searchBox.OnSearchSelectHide()">&#160;</span>
          <input type="text" id="MSearchField" value="" placeholder="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.svg" alt=""/></a>
          </span>
        </div>
</td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.10.0 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @license-end */
</script>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function(){initNavTree('group___h5.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>

<div class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle"><div class="title">Library General (H5)</div></div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<p>Use the functions in this module to manage the life cycle of HDF5 library instances.</p>
<table class="doxtable">
<tr>
<th>Create</th><th>Read </th></tr>
<tr valign="top">
<td><div class="fragment"><div class="line"><span class="lineno">   23</span>    {</div>
<div class="line"><span class="lineno">   24</span>        <span class="comment">// an HDF5 library instance is automatically initialized as</span></div>
<div class="line"><span class="lineno">   25</span>        <span class="comment">// part of the first HDF5 API call, but there&#39;s no harm in</span></div>
<div class="line"><span class="lineno">   26</span>        <span class="comment">// calling H5open().</span></div>
<div class="line"><span class="lineno">   27</span>        <span class="keywordflow">if</span> (<a class="code hl_function" href="#ga27fa33dc262dda95c5aa8df533837480">H5open</a>() &lt; 0) {</div>
<div class="line"><span class="lineno">   28</span>            ret_val = EXIT_FAILURE;</div>
<div class="line"><span class="lineno">   29</span>        }</div>
<div class="line"><span class="lineno">   30</span>    }</div>
</div><!-- fragment -->  </td><td><div class="fragment"><div class="line"><span class="lineno">   34</span>    {</div>
<div class="line"><span class="lineno">   35</span>        __label__ fail_read;</div>
<div class="line"><span class="lineno">   36</span>        <span class="keywordtype">unsigned</span> majnum, minnum, relnum;</div>
<div class="line"><span class="lineno">   37</span>        <a class="code hl_typedef" href="_h5public_8h.html#ad470b00eccd2115c707c02de5fa1120d">hbool_t</a>  flag;</div>
<div class="line"><span class="lineno">   38</span> </div>
<div class="line"><span class="lineno">   39</span>        <span class="comment">// retrieve the library version</span></div>
<div class="line"><span class="lineno">   40</span>        <span class="keywordflow">if</span> (<a class="code hl_function" href="#gaf87da966fdf896ec7bca794e21d4ab0a">H5get_libversion</a>(&amp;majnum, &amp;minnum, &amp;relnum) &lt; 0) {</div>
<div class="line"><span class="lineno">   41</span>            ret_val = EXIT_FAILURE;</div>
<div class="line"><span class="lineno">   42</span>            <span class="keywordflow">goto</span> fail_read;</div>
<div class="line"><span class="lineno">   43</span>        }</div>
<div class="line"><span class="lineno">   44</span>        <span class="comment">// is this a thread-safe library build?</span></div>
<div class="line"><span class="lineno">   45</span>        <span class="keywordflow">if</span> (<a class="code hl_function" href="#ga70bfde4acd009cdd7bcd2f54c594e28a">H5is_library_threadsafe</a>(&amp;flag) &lt; 0) {</div>
<div class="line"><span class="lineno">   46</span>            ret_val = EXIT_FAILURE;</div>
<div class="line"><span class="lineno">   47</span>            <span class="keywordflow">goto</span> fail_read;</div>
<div class="line"><span class="lineno">   48</span>        }</div>
<div class="line"><span class="lineno">   49</span> </div>
<div class="line"><span class="lineno">   50</span>        printf(<span class="stringliteral">&quot;Welcome to HDF5 %d.%d.%d\n&quot;</span>, majnum, minnum, relnum);</div>
<div class="line"><span class="lineno">   51</span>        printf(<span class="stringliteral">&quot;Thread-safety %s\n&quot;</span>, (flag &gt; 0) ? <span class="stringliteral">&quot;enabled&quot;</span> : <span class="stringliteral">&quot;disabled&quot;</span>);</div>
<div class="line"><span class="lineno">   52</span> </div>
<div class="line"><span class="lineno">   53</span>fail_read:;</div>
<div class="line"><span class="lineno">   54</span>    }</div>
</div><!-- fragment -->  </td></tr>
<tr>
<th>Update</th><th>Delete </th></tr>
<tr valign="top">
<td><div class="fragment"><div class="line"><span class="lineno">   58</span>    {</div>
<div class="line"><span class="lineno">   59</span>        <span class="comment">// update the library instance free list limits</span></div>
<div class="line"><span class="lineno">   60</span>        <span class="keywordflow">if</span> (<a class="code hl_function" href="#gaa3f78b24b8a1ff4168db2b7ddca21545">H5set_free_list_limits</a>(512 * 1024, 32 * 1024, 2048 * 1024, 128 * 1024, 8192 * 1024, 512 * 1024) &lt;</div>
<div class="line"><span class="lineno">   61</span>            0) {</div>
<div class="line"><span class="lineno">   62</span>            ret_val = EXIT_FAILURE;</div>
<div class="line"><span class="lineno">   63</span>        }</div>
<div class="line"><span class="lineno">   64</span>    }</div>
</div><!-- fragment -->  </td><td><div class="fragment"><div class="line"><span class="lineno">   10</span><span class="keywordtype">void</span></div>
<div class="line"><span class="lineno">   11</span>closing_shop(<span class="keywordtype">void</span> *ctx)</div>
<div class="line"><span class="lineno">   12</span>{</div>
<div class="line"><span class="lineno">   13</span>    printf(<span class="stringliteral">&quot;GoodBye, Cruel World!\n&quot;</span>);</div>
<div class="line"><span class="lineno">   14</span>}</div>
</div><!-- fragment --> <div class="fragment"><div class="line"><span class="lineno">   68</span>    {</div>
<div class="line"><span class="lineno">   69</span><span class="preprocessor">#if H5_VERSION_GE(1, 13, 0)</span></div>
<div class="line"><span class="lineno">   70</span>        <span class="comment">// install a finalization routine</span></div>
<div class="line"><span class="lineno">   71</span>        <span class="keywordflow">if</span> (<a class="code hl_function" href="#gade62a3e6b75bed52234d9e8432c27fb2">H5atclose</a>(&amp;closing_shop, NULL) &lt; 0) {</div>
<div class="line"><span class="lineno">   72</span>            ret_val = EXIT_FAILURE;</div>
<div class="line"><span class="lineno">   73</span>        }</div>
<div class="line"><span class="lineno">   74</span><span class="preprocessor">#endif</span></div>
<div class="line"><span class="lineno">   75</span>        <span class="comment">// close shop</span></div>
<div class="line"><span class="lineno">   76</span>        <span class="keywordflow">if</span> (<a class="code hl_function" href="#ga8a9fe81dcf66972ed75ea481e7750574">H5close</a>() &lt; 0) {</div>
<div class="line"><span class="lineno">   77</span>            ret_val = EXIT_FAILURE;</div>
<div class="line"><span class="lineno">   78</span>        }</div>
<div class="line"><span class="lineno">   79</span>    }</div>
</div><!-- fragment -->   </td></tr>
</table>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="func-members" name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ga27fa33dc262dda95c5aa8df533837480" id="r_ga27fa33dc262dda95c5aa8df533837480"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ga27fa33dc262dda95c5aa8df533837480">H5open</a> (void)</td></tr>
<tr class="memdesc:ga27fa33dc262dda95c5aa8df533837480"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes the HDF5 library.  <br /></td></tr>
<tr class="separator:ga27fa33dc262dda95c5aa8df533837480"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gade62a3e6b75bed52234d9e8432c27fb2" id="r_gade62a3e6b75bed52234d9e8432c27fb2"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#gade62a3e6b75bed52234d9e8432c27fb2">H5atclose</a> (<a class="el" href="_h5public_8h.html#a05a43aeba55b736316e74e3a26cbb254">H5_atclose_func_t</a> func, void *ctx)</td></tr>
<tr class="memdesc:gade62a3e6b75bed52234d9e8432c27fb2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Registers a callback for the library to invoke when it's closing.  <br /></td></tr>
<tr class="separator:gade62a3e6b75bed52234d9e8432c27fb2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga8a9fe81dcf66972ed75ea481e7750574" id="r_ga8a9fe81dcf66972ed75ea481e7750574"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ga8a9fe81dcf66972ed75ea481e7750574">H5close</a> (void)</td></tr>
<tr class="memdesc:ga8a9fe81dcf66972ed75ea481e7750574"><td class="mdescLeft">&#160;</td><td class="mdescRight">Flushes all data to disk, closes all open objects, and releases memory.  <br /></td></tr>
<tr class="separator:ga8a9fe81dcf66972ed75ea481e7750574"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga7f80eb63b5e78812b9d0d50ac46764e8" id="r_ga7f80eb63b5e78812b9d0d50ac46764e8"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ga7f80eb63b5e78812b9d0d50ac46764e8">H5dont_atexit</a> (void)</td></tr>
<tr class="memdesc:ga7f80eb63b5e78812b9d0d50ac46764e8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Instructs library not to install atexit() cleanup routine.  <br /></td></tr>
<tr class="separator:ga7f80eb63b5e78812b9d0d50ac46764e8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gae511943bcb837a52a012a3a5dd7b90ef" id="r_gae511943bcb837a52a012a3a5dd7b90ef"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#gae511943bcb837a52a012a3a5dd7b90ef">H5garbage_collect</a> (void)</td></tr>
<tr class="memdesc:gae511943bcb837a52a012a3a5dd7b90ef"><td class="mdescLeft">&#160;</td><td class="mdescRight">Garbage collects on all free-lists of all types.  <br /></td></tr>
<tr class="separator:gae511943bcb837a52a012a3a5dd7b90ef"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaa3f78b24b8a1ff4168db2b7ddca21545" id="r_gaa3f78b24b8a1ff4168db2b7ddca21545"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#gaa3f78b24b8a1ff4168db2b7ddca21545">H5set_free_list_limits</a> (int reg_global_lim, int reg_list_lim, int arr_global_lim, int arr_list_lim, int blk_global_lim, int blk_list_lim)</td></tr>
<tr class="memdesc:gaa3f78b24b8a1ff4168db2b7ddca21545"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets free-list size limits.  <br /></td></tr>
<tr class="separator:gaa3f78b24b8a1ff4168db2b7ddca21545"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga2310d963a6f48ec12fda8c0c8bbefbbb" id="r_ga2310d963a6f48ec12fda8c0c8bbefbbb"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ga2310d963a6f48ec12fda8c0c8bbefbbb">H5get_free_list_sizes</a> (size_t *reg_size, size_t *arr_size, size_t *blk_size, size_t *fac_size)</td></tr>
<tr class="memdesc:ga2310d963a6f48ec12fda8c0c8bbefbbb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the current size of the free lists used to manage memory.  <br /></td></tr>
<tr class="separator:ga2310d963a6f48ec12fda8c0c8bbefbbb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaf87da966fdf896ec7bca794e21d4ab0a" id="r_gaf87da966fdf896ec7bca794e21d4ab0a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#gaf87da966fdf896ec7bca794e21d4ab0a">H5get_libversion</a> (unsigned *majnum, unsigned *minnum, unsigned *relnum)</td></tr>
<tr class="memdesc:gaf87da966fdf896ec7bca794e21d4ab0a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the HDF library release number.  <br /></td></tr>
<tr class="separator:gaf87da966fdf896ec7bca794e21d4ab0a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga93525482e1168344f4c92470f99d88be" id="r_ga93525482e1168344f4c92470f99d88be"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ga93525482e1168344f4c92470f99d88be">H5check_version</a> (unsigned majnum, unsigned minnum, unsigned relnum)</td></tr>
<tr class="memdesc:ga93525482e1168344f4c92470f99d88be"><td class="mdescLeft">&#160;</td><td class="mdescRight">Verifies that HDF5 library versions are consistent.  <br /></td></tr>
<tr class="separator:ga93525482e1168344f4c92470f99d88be"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac2fdfe0e7a1012b796bdeafbed9ab970" id="r_gac2fdfe0e7a1012b796bdeafbed9ab970"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#gac2fdfe0e7a1012b796bdeafbed9ab970">H5is_library_terminating</a> (<a class="el" href="_h5public_8h.html#ad470b00eccd2115c707c02de5fa1120d">hbool_t</a> *is_terminating)</td></tr>
<tr class="memdesc:gac2fdfe0e7a1012b796bdeafbed9ab970"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks whether the HDF5 library is closing.  <br /></td></tr>
<tr class="separator:gac2fdfe0e7a1012b796bdeafbed9ab970"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga70bfde4acd009cdd7bcd2f54c594e28a" id="r_ga70bfde4acd009cdd7bcd2f54c594e28a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ga70bfde4acd009cdd7bcd2f54c594e28a">H5is_library_threadsafe</a> (<a class="el" href="_h5public_8h.html#ad470b00eccd2115c707c02de5fa1120d">hbool_t</a> *is_ts)</td></tr>
<tr class="memdesc:ga70bfde4acd009cdd7bcd2f54c594e28a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Determines whether the HDF5 library was built with the thread-safety feature enabled.  <br /></td></tr>
<tr class="separator:ga70bfde4acd009cdd7bcd2f54c594e28a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga71872bf6445cba956da86d4762b662cf" id="r_ga71872bf6445cba956da86d4762b662cf"><td class="memItemLeft" align="right" valign="top"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ga71872bf6445cba956da86d4762b662cf">H5free_memory</a> (void *mem)</td></tr>
<tr class="memdesc:ga71872bf6445cba956da86d4762b662cf"><td class="mdescLeft">&#160;</td><td class="mdescRight">Frees memory allocated by the HDF5 library.  <br /></td></tr>
<tr class="separator:ga71872bf6445cba956da86d4762b662cf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga7459a8634b40225f3f6d81eb08acf399" id="r_ga7459a8634b40225f3f6d81eb08acf399"><td class="memItemLeft" align="right" valign="top">void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ga7459a8634b40225f3f6d81eb08acf399">H5allocate_memory</a> (size_t size, <a class="el" href="_h5public_8h.html#ad470b00eccd2115c707c02de5fa1120d">hbool_t</a> clear)</td></tr>
<tr class="memdesc:ga7459a8634b40225f3f6d81eb08acf399"><td class="mdescLeft">&#160;</td><td class="mdescRight">Allocates memory that will be freed later internally.  <br /></td></tr>
<tr class="separator:ga7459a8634b40225f3f6d81eb08acf399"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gab8024266aca102414ba2960e27ddb7c2" id="r_gab8024266aca102414ba2960e27ddb7c2"><td class="memItemLeft" align="right" valign="top">void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#gab8024266aca102414ba2960e27ddb7c2">H5resize_memory</a> (void *mem, size_t size)</td></tr>
<tr class="memdesc:gab8024266aca102414ba2960e27ddb7c2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Resizes and, if required, re-allocates memory that will later be freed internally by the HDF5 library.  <br /></td></tr>
<tr class="separator:gab8024266aca102414ba2960e27ddb7c2"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Function Documentation</h2>
<a id="ga7459a8634b40225f3f6d81eb08acf399" name="ga7459a8634b40225f3f6d81eb08acf399"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga7459a8634b40225f3f6d81eb08acf399">&#9670;&#160;</a></span>H5allocate_memory()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void * H5allocate_memory </td>
          <td>(</td>
          <td class="paramtype">size_t</td>          <td class="paramname"><span class="paramname"><em>size</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="_h5public_8h.html#ad470b00eccd2115c707c02de5fa1120d">hbool_t</a></td>          <td class="paramname"><span class="paramname"><em>clear</em></span>&#160;)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Allocates memory that will be freed later internally. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">size</td><td>The size in bytes of the buffer to be allocated </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">clear</td><td>Flag whether the new buffer is to be initialized with 0</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>On success, returns pointer to newly allocated buffer or returns NULL if size is 0 (zero).<br  />
 Returns NULL on failure.</dd></dl>
<p><a class="el" href="#ga7459a8634b40225f3f6d81eb08acf399" title="Allocates memory that will be freed later internally.">H5allocate_memory()</a> allocates a memory buffer of size bytes that will later be freed internally by the HDF5 library.</p>
<p>The boolean <code>clear</code> parameter specifies whether the buffer should be initialized. If clear is <code>true</code>, all bits in the buffer are to be set to 0 (zero); if clear is <code>false</code>, the buffer will not be initialized.</p>
<p>This function is intended to have the semantics of malloc() and calloc(). However, unlike malloc() and calloc(), which allow for a "special" pointer to be returned instead of NULL, this function always returns NULL on failure or when size is set to 0 (zero).</p>
<dl class="section note"><dt>Note</dt><dd>At this time, the only intended use for this function is to allocate memory that will be returned to the library as a data buffer from a third-party filter.</dd></dl>
<dl class="section attention"><dt>Attention</dt><dd>To avoid heap corruption, allocated memory should be freed using the same library that initially allocated it. In most cases, the HDF5 API uses resources that are allocated and freed either entirely by the user or entirely by the library, so this is not a problem. In rare cases, however, HDF5 API calls will free the memory that the user allocated. This function allows the user to safely allocate this memory.<br  />
 It is particularly important to use this function to allocate memory in Microsoft Windows environments. In Windows, the C standard library is implemented in dynamic link libraries (DLLs) known as the C run-time (CRT). Each version of Visual Studio comes with multiple versions of the CRT DLLs (debug, release, et cetera) and allocating and freeing memory across DLL boundaries can cause resource leaks and subtle bugs due to heap corruption.<br  />
 Even when using this function, it is best where possible to ensure that all components of a C application are built with the same version of Visual Studio and configuration (Debug or Release), and thus linked against the same CRT.<br  />
 Use this function only to allocate memory inside third-party HDF5 filters. It will generally not be safe to use this function to allocate memory for any other purpose.</dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="#ga71872bf6445cba956da86d4762b662cf" title="Frees memory allocated by the HDF5 library.">H5free_memory()</a>, <a class="el" href="#gab8024266aca102414ba2960e27ddb7c2" title="Resizes and, if required, re-allocates memory that will later be freed internally by the HDF5 library...">H5resize_memory()</a></dd></dl>
<dl class="section since"><dt>Since</dt><dd>1.8.15 </dd></dl>

</div>
</div>
<a id="gade62a3e6b75bed52234d9e8432c27fb2" name="gade62a3e6b75bed52234d9e8432c27fb2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gade62a3e6b75bed52234d9e8432c27fb2">&#9670;&#160;</a></span>H5atclose()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5atclose </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="_h5public_8h.html#a05a43aeba55b736316e74e3a26cbb254">H5_atclose_func_t</a></td>          <td class="paramname"><span class="paramname"><em>func</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *</td>          <td class="paramname"><span class="paramname"><em>ctx</em></span>&#160;)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Registers a callback for the library to invoke when it's closing. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">func</td><td>The function pointer to invoke </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">ctx</td><td>Context to pass to <code>func</code> when invoked </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#gade62a3e6b75bed52234d9e8432c27fb2" title="Registers a callback for the library to invoke when it&#39;s closing.">H5atclose()</a> registers a callback that the HDF5 library will invoke when closing. The full capabilities of the HDF5 library are available to callbacks invoked through this mechanism, and library shutdown will only begin in earnest when all callbacks have been invoked and have returned.</p>
<p>Registered callbacks are invoked in LIFO order, similar to the Standard C 'atexit' routine. For example, if 'func1' is registered, then 'func2', when the library is closing 'func2', will be invoked first, then 'func1'.</p>
<p>The <code>ctx</code> pointer will be passed to <code>func</code> when it's invoked. NULL is allowed for <code>ctx</code>.</p>
<p>If the HDF5 library is initialized and closed more than once, the <code>func</code> callback must be registered within each open/close cycle.</p>
<dl class="section since"><dt>Since</dt><dd>1.14.0 </dd></dl>

</div>
</div>
<a id="ga93525482e1168344f4c92470f99d88be" name="ga93525482e1168344f4c92470f99d88be"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga93525482e1168344f4c92470f99d88be">&#9670;&#160;</a></span>H5check_version()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5check_version </td>
          <td>(</td>
          <td class="paramtype">unsigned</td>          <td class="paramname"><span class="paramname"><em>majnum</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned</td>          <td class="paramname"><span class="paramname"><em>minnum</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned</td>          <td class="paramname"><span class="paramname"><em>relnum</em></span>&#160;)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Verifies that HDF5 library versions are consistent. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">majnum</td><td>HDF5 library major version number </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">minnum</td><td>HDF5 library minor version number </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">relnum</td><td>HDF5 library release number </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#ga93525482e1168344f4c92470f99d88be" title="Verifies that HDF5 library versions are consistent.">H5check_version()</a> verifies that the version of the HDF5 library with which an application was compiled, as indicated by the passed parameters, matches the version of the HDF5 library against which the application is currently linked.</p>
<p><code>majnum</code> is the major version number of the HDF library with which the application was compiled, <code>minnum</code> is the minor version number, and <code>relnum</code> is the release number. Consider the following example:</p>
<p>An official HDF5 release is labelled as follows: HDF5 Release <code>&lt;majnum&gt;.&lt;minnum&gt;.&lt;relnum&gt;</code><br  />
 For example, in HDF5 Release 1.8.5: </p><ul>
<li>1 is the major version number, <code>majnum</code>. </li>
<li>8 is the minor version number, <code>minnum</code>. </li>
<li>5 is the release number, <code>relnum</code>.</li>
</ul>
<p>As stated above, <a class="el" href="#ga93525482e1168344f4c92470f99d88be" title="Verifies that HDF5 library versions are consistent.">H5check_version()</a> first verifies that the version of the HDF5 library with which an application was compiled matches the version of the HDF5 library against which the application is currently linked. If this check fails, <a class="el" href="#ga93525482e1168344f4c92470f99d88be" title="Verifies that HDF5 library versions are consistent.">H5check_version()</a> causes the application to abort (by means of a standard C abort() call) and prints information that is usually useful for debugging. This precaution is taken to avoid the risks of data corruption or segmentation faults.</p>
<p>The most common cause of this failure is that an application was compiled with one version of HDF5 and is dynamically linked with a different version different version.</p>
<p>If the above test passes, <a class="el" href="#ga93525482e1168344f4c92470f99d88be" title="Verifies that HDF5 library versions are consistent.">H5check_version()</a> proceeds to verify the consistency of additional library version information. This is designed to catch source code inconsistencies that do not normally cause failures; if this check reveals an inconsistency, an informational warning is printed but the application is allowed to run.</p>
<dl class="section since"><dt>Since</dt><dd>1.0.0 </dd></dl>

</div>
</div>
<a id="ga8a9fe81dcf66972ed75ea481e7750574" name="ga8a9fe81dcf66972ed75ea481e7750574"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga8a9fe81dcf66972ed75ea481e7750574">&#9670;&#160;</a></span>H5close()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5close </td>
          <td>(</td>
          <td class="paramtype">void</td>          <td class="paramname"><span class="paramname"></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Flushes all data to disk, closes all open objects, and releases memory. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#ga8a9fe81dcf66972ed75ea481e7750574" title="Flushes all data to disk, closes all open objects, and releases memory.">H5close()</a> flushes all data to disk, closes all open HDF5 objects, and cleans up all memory used by the HDF5 library. This function is generally called when the application calls exit(), but may be called earlier in the event of an emergency shutdown or out of a desire to free all resources used by the HDF5 library.</p>
<dl class="section since"><dt>Since</dt><dd>1.0.0 </dd></dl>

</div>
</div>
<a id="ga7f80eb63b5e78812b9d0d50ac46764e8" name="ga7f80eb63b5e78812b9d0d50ac46764e8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga7f80eb63b5e78812b9d0d50ac46764e8">&#9670;&#160;</a></span>H5dont_atexit()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5dont_atexit </td>
          <td>(</td>
          <td class="paramtype">void</td>          <td class="paramname"><span class="paramname"></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Instructs library not to install atexit() cleanup routine. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#ga7f80eb63b5e78812b9d0d50ac46764e8" title="Instructs library not to install atexit() cleanup routine.">H5dont_atexit()</a> indicates to the library that an atexit() cleanup routine should not be installed. The major purpose for using this function is in situations where the library is dynamically linked into an application and is un-linked from the application before exit() gets called. In those situations, a routine installed with atexit() would jump to a routine that was no longer in memory, causing errors.</p>
<dl class="section attention"><dt>Attention</dt><dd>In order to be effective, this routine <em>must</em> be called before any other HDF5 function calls, and must be called each time the library is loaded/linked into the application (the first time and after it's been unloaded).</dd></dl>
<dl class="section since"><dt>Since</dt><dd>1.0.0 </dd></dl>

</div>
</div>
<a id="ga71872bf6445cba956da86d4762b662cf" name="ga71872bf6445cba956da86d4762b662cf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga71872bf6445cba956da86d4762b662cf">&#9670;&#160;</a></span>H5free_memory()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5free_memory </td>
          <td>(</td>
          <td class="paramtype">void *</td>          <td class="paramname"><span class="paramname"><em>mem</em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Frees memory allocated by the HDF5 library. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">mem</td><td>Buffer to be freed. Can be NULL </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#ga71872bf6445cba956da86d4762b662cf" title="Frees memory allocated by the HDF5 library.">H5free_memory()</a> frees the memory that has been allocated by the caller with <a class="el" href="#ga7459a8634b40225f3f6d81eb08acf399" title="Allocates memory that will be freed later internally.">H5allocate_memory()</a> or by the HDF5 library on behalf of the caller.</p>
<p><a class="el" href="group___c_o_m_p_e_n_u_m.html#ga64d1d807464d2011192f28115580fb66" title="Retrieves the name of a compound or enumeration datatype member.">H5Tget_member_name()</a> provides an example of memory allocation on behalf of the caller: The function returns a buffer containing the name of a compound datatype member. It is the caller's responsibility to eventually free that buffer with <a class="el" href="#ga71872bf6445cba956da86d4762b662cf" title="Frees memory allocated by the HDF5 library.">H5free_memory()</a>.</p>
<dl class="section attention"><dt>Attention</dt><dd>It is especially important to use this function to free memory allocated by the library on Windows. The C standard library is implemented in dynamic link libraries (DLLs) known as the C run-time (CRT). Each version of Visual Studio comes with two CRT DLLs (debug and release) and allocating and freeing across DLL boundaries can cause resource leaks and subtle bugs due to heap corruption.<br  />
 Only use this function to free memory allocated by the HDF5 Library. It will generally not be safe to use this function to free memory allocated by any other means.<br  />
 Even when using this function, it is still best to ensure that all components of a C application are built with the same version of Visual Studio and build (debug or release) and thus linked against the same CRT.</dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="#ga7459a8634b40225f3f6d81eb08acf399" title="Allocates memory that will be freed later internally.">H5allocate_memory()</a>, <a class="el" href="#gab8024266aca102414ba2960e27ddb7c2" title="Resizes and, if required, re-allocates memory that will later be freed internally by the HDF5 library...">H5resize_memory()</a></dd></dl>
<dl class="section since"><dt>Since</dt><dd>1.8.13 </dd></dl>

</div>
</div>
<a id="gae511943bcb837a52a012a3a5dd7b90ef" name="gae511943bcb837a52a012a3a5dd7b90ef"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gae511943bcb837a52a012a3a5dd7b90ef">&#9670;&#160;</a></span>H5garbage_collect()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5garbage_collect </td>
          <td>(</td>
          <td class="paramtype">void</td>          <td class="paramname"><span class="paramname"></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Garbage collects on all free-lists of all types. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#gae511943bcb837a52a012a3a5dd7b90ef" title="Garbage collects on all free-lists of all types.">H5garbage_collect()</a> walks through all garbage collection routines of the library, freeing any unused memory.</p>
<p>It is not required that <a class="el" href="#gae511943bcb837a52a012a3a5dd7b90ef" title="Garbage collects on all free-lists of all types.">H5garbage_collect()</a> be called at any particular time; it is only necessary for certain situations where the application has performed actions that cause the library to allocate many objects. The application should call <a class="el" href="#gae511943bcb837a52a012a3a5dd7b90ef" title="Garbage collects on all free-lists of all types.">H5garbage_collect()</a> if it eventually releases those objects and wants to reduce the memory used by the library from the peak usage required.</p>
<dl class="section note"><dt>Note</dt><dd>The library automatically garbage collects all the free lists when the application ends.</dd></dl>
<dl class="section since"><dt>Since</dt><dd>1.4.0 </dd></dl>

</div>
</div>
<a id="ga2310d963a6f48ec12fda8c0c8bbefbbb" name="ga2310d963a6f48ec12fda8c0c8bbefbbb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga2310d963a6f48ec12fda8c0c8bbefbbb">&#9670;&#160;</a></span>H5get_free_list_sizes()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5get_free_list_sizes </td>
          <td>(</td>
          <td class="paramtype">size_t *</td>          <td class="paramname"><span class="paramname"><em>reg_size</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t *</td>          <td class="paramname"><span class="paramname"><em>arr_size</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t *</td>          <td class="paramname"><span class="paramname"><em>blk_size</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t *</td>          <td class="paramname"><span class="paramname"><em>fac_size</em></span>&#160;)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Gets the current size of the free lists used to manage memory. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[out]</td><td class="paramname">reg_size</td><td>The current size of all "regular" free list memory used </td></tr>
    <tr><td class="paramdir">[out]</td><td class="paramname">arr_size</td><td>The current size of all "array" free list memory used </td></tr>
    <tr><td class="paramdir">[out]</td><td class="paramname">blk_size</td><td>The current size of all "block" free list memory used </td></tr>
    <tr><td class="paramdir">[out]</td><td class="paramname">fac_size</td><td>The current size of all "factory" free list memory used </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#ga2310d963a6f48ec12fda8c0c8bbefbbb" title="Gets the current size of the free lists used to manage memory.">H5get_free_list_sizes()</a> obtains the current size of the different kinds of free lists that the library uses to manage memory. The free list sizes can be set with <a class="el" href="#gaa3f78b24b8a1ff4168db2b7ddca21545" title="Sets free-list size limits.">H5set_free_list_limits()</a> and garbage collected with <a class="el" href="#gae511943bcb837a52a012a3a5dd7b90ef" title="Garbage collects on all free-lists of all types.">H5garbage_collect()</a>. These lists are global for the entire library.</p>
<dl class="section since"><dt>Since</dt><dd>1.10.7 </dd></dl>

</div>
</div>
<a id="gaf87da966fdf896ec7bca794e21d4ab0a" name="gaf87da966fdf896ec7bca794e21d4ab0a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaf87da966fdf896ec7bca794e21d4ab0a">&#9670;&#160;</a></span>H5get_libversion()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5get_libversion </td>
          <td>(</td>
          <td class="paramtype">unsigned *</td>          <td class="paramname"><span class="paramname"><em>majnum</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned *</td>          <td class="paramname"><span class="paramname"><em>minnum</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned *</td>          <td class="paramname"><span class="paramname"><em>relnum</em></span>&#160;)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns the HDF library release number. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[out]</td><td class="paramname">majnum</td><td>The major version number of the library </td></tr>
    <tr><td class="paramdir">[out]</td><td class="paramname">minnum</td><td>The minor version number of the library </td></tr>
    <tr><td class="paramdir">[out]</td><td class="paramname">relnum</td><td>The release version number of the library </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#gaf87da966fdf896ec7bca794e21d4ab0a" title="Returns the HDF library release number.">H5get_libversion()</a> retrieves the major, minor, and release numbers of the version of the HDF5 library which is linked to the application.</p>
<dl class="section since"><dt>Since</dt><dd>1.0.0 </dd></dl>

</div>
</div>
<a id="gac2fdfe0e7a1012b796bdeafbed9ab970" name="gac2fdfe0e7a1012b796bdeafbed9ab970"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gac2fdfe0e7a1012b796bdeafbed9ab970">&#9670;&#160;</a></span>H5is_library_terminating()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5is_library_terminating </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="_h5public_8h.html#ad470b00eccd2115c707c02de5fa1120d">hbool_t</a> *</td>          <td class="paramname"><span class="paramname"><em>is_terminating</em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks whether the HDF5 library is closing. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[out]</td><td class="paramname">is_terminating</td><td>Flag indicating whether library is shutting down </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#gac2fdfe0e7a1012b796bdeafbed9ab970" title="Checks whether the HDF5 library is closing.">H5is_library_terminating()</a> queries whether the HDF5 library is in the process of shutting down. The <code>is_terminating</code> flag will only be set to true after shutdown starts, it will be false before the library has been initialized, while the library is initialized, and after it has been closed. The value of <code>is_terminating</code> is undefined if this routine fails.</p>
<dl class="section since"><dt>Since</dt><dd>1.14.0 </dd></dl>

</div>
</div>
<a id="ga70bfde4acd009cdd7bcd2f54c594e28a" name="ga70bfde4acd009cdd7bcd2f54c594e28a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga70bfde4acd009cdd7bcd2f54c594e28a">&#9670;&#160;</a></span>H5is_library_threadsafe()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5is_library_threadsafe </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="_h5public_8h.html#ad470b00eccd2115c707c02de5fa1120d">hbool_t</a> *</td>          <td class="paramname"><span class="paramname"><em>is_ts</em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Determines whether the HDF5 library was built with the thread-safety feature enabled. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[out]</td><td class="paramname">is_ts</td><td>Boolean value indicating whether the library was built with thread-safety enabled </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p>The HDF5 library, although not internally multi-threaded, can be built with a thread-safety feature enabled that protects internal data structures with a mutex. In certain circumstances, it may be useful to determine, at run-time, whether the linked HDF5 library was built with the thread-safety feature enabled.</p>
<dl class="section since"><dt>Since</dt><dd>1.10.0 </dd></dl>

</div>
</div>
<a id="ga27fa33dc262dda95c5aa8df533837480" name="ga27fa33dc262dda95c5aa8df533837480"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga27fa33dc262dda95c5aa8df533837480">&#9670;&#160;</a></span>H5open()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5open </td>
          <td>(</td>
          <td class="paramtype">void</td>          <td class="paramname"><span class="paramname"></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Initializes the HDF5 library. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#ga27fa33dc262dda95c5aa8df533837480" title="Initializes the HDF5 library.">H5open()</a> initializes the HDF5 library.</p>
<p>When the HDF5 library is used in a C application, the library is automatically initialized when the first HDf5 function call is issued. If one finds that an HDF5 library function is failing inexplicably, <a class="el" href="#ga27fa33dc262dda95c5aa8df533837480" title="Initializes the HDF5 library.">H5open()</a> can be called first. It is safe to call <a class="el" href="#ga27fa33dc262dda95c5aa8df533837480" title="Initializes the HDF5 library.">H5open()</a> before an application issues any other function calls to the HDF5 library, as there are no damaging side effects in calling it more than once.</p>
<dl class="section since"><dt>Since</dt><dd>1.0.0 </dd></dl>

</div>
</div>
<a id="gab8024266aca102414ba2960e27ddb7c2" name="gab8024266aca102414ba2960e27ddb7c2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gab8024266aca102414ba2960e27ddb7c2">&#9670;&#160;</a></span>H5resize_memory()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void * H5resize_memory </td>
          <td>(</td>
          <td class="paramtype">void *</td>          <td class="paramname"><span class="paramname"><em>mem</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t</td>          <td class="paramname"><span class="paramname"><em>size</em></span>&#160;)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Resizes and, if required, re-allocates memory that will later be freed internally by the HDF5 library. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">mem</td><td>Pointer to a buffer to be resized. May be NULL </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">size</td><td>New size of the buffer, in bytes</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>On success, returns pointer to resized or reallocated buffer or returns NULL if size is 0 (zero).<br  />
 Returns NULL on failure.</dd></dl>
<p><a class="el" href="#gab8024266aca102414ba2960e27ddb7c2" title="Resizes and, if required, re-allocates memory that will later be freed internally by the HDF5 library...">H5resize_memory()</a> takes a pointer to an existing buffer and resizes the buffer to match the value in <code>size</code>. If necessary, the buffer is reallocated. If <code>size</code> is 0, the buffer is released.</p>
<p>The input buffer must either be NULL or have been allocated by <a class="el" href="#ga7459a8634b40225f3f6d81eb08acf399" title="Allocates memory that will be freed later internally.">H5allocate_memory()</a> since the input buffer may be freed by the library.</p>
<p>For certain behaviors, the pointer <code>mem</code> may be passed in as NULL.</p>
<p>This function is intended to have the semantics of realloc():</p>
<table class="doxtable">
<tr>
<td><code>H5resize_memory(buffer, size)</code> </td><td>Resizes buffer. Returns pointer to resized buffer. </td></tr>
<tr>
<td><code>H5resize_memory(NULL, size)</code> </td><td>Allocates memory using HDF5 Library allocator. Returns pointer to new buffer </td></tr>
<tr>
<td><code>H5resize_memory(buffer, 0)</code> </td><td>Frees memory using HDF5 Library allocator. Returns NULL. </td></tr>
<tr>
<td><code>H5resize_memory(NULL, 0)</code> </td><td>Returns NULL (undefined in C standard). </td></tr>
</table>
<p>Unlike realloc(), which allows for a "special pointer to be returned instead of NULL, this function always returns NULL on failure or when size is 0 (zero).</p>
<dl class="section note"><dt>Note</dt><dd>At this time, the only intended use for this function is to resize or reallocate memory that will be returned to the library (and eventually to the user) as a data buffer from a third-party HDF5 filter.</dd></dl>
<dl class="section attention"><dt>Attention</dt><dd>To avoid heap corruption, allocated memory should be freed using the same library that initially allocated it. In most cases, the HDF5 API uses resources that are allocated and freed either entirely by the user or entirely by the library, so this is not a problem. In rare cases, however, HDF5 API calls will free memory that the user allocated. This function allows the user to safely allocate this memory.<br  />
 It is particularly important to use this function to resize memory on Microsoft Windows systems. In Windows, the C standard library is implemented in dynamic link libraries (DLLs) known as the C run-time (CRT). Each version of Visual Studio comes with multiple versions of the CRT DLLs (debug, release, et cetera) and allocating and freeing memory across DLL boundaries can cause resource leaks and subtle bugs due to heap corruption.<br  />
 Even when using this function, it is still best to ensure that all components of a C application are built with the same version of Visual Studio and the same configuration (Debug or Release), and thus linked against the same CRT.<br  />
 Only use this function to resize memory inside third-party HDF5 filters. It will generally not be safe to use this function to resize memory for any other purpose.</dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="#ga7459a8634b40225f3f6d81eb08acf399" title="Allocates memory that will be freed later internally.">H5allocate_memory()</a>, <a class="el" href="#ga71872bf6445cba956da86d4762b662cf" title="Frees memory allocated by the HDF5 library.">H5free_memory()</a></dd></dl>
<dl class="section since"><dt>Since</dt><dd>1.8.15 </dd></dl>

</div>
</div>
<a id="gaa3f78b24b8a1ff4168db2b7ddca21545" name="gaa3f78b24b8a1ff4168db2b7ddca21545"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaa3f78b24b8a1ff4168db2b7ddca21545">&#9670;&#160;</a></span>H5set_free_list_limits()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_h5public_8h.html#a3b079ecf932a5c599499cf7e298af160">herr_t</a> H5set_free_list_limits </td>
          <td>(</td>
          <td class="paramtype">int</td>          <td class="paramname"><span class="paramname"><em>reg_global_lim</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int</td>          <td class="paramname"><span class="paramname"><em>reg_list_lim</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int</td>          <td class="paramname"><span class="paramname"><em>arr_global_lim</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int</td>          <td class="paramname"><span class="paramname"><em>arr_list_lim</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int</td>          <td class="paramname"><span class="paramname"><em>blk_global_lim</em>, </span></td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int</td>          <td class="paramname"><span class="paramname"><em>blk_list_lim</em></span>&#160;)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Sets free-list size limits. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">reg_global_lim</td><td>The cumulative limit, in bytes, on memory used for all regular free lists (Default: 1MB) </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">reg_list_lim</td><td>The limit, in bytes, on memory used for each regular free list (Default: 64KB) </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">arr_global_lim</td><td>The cumulative limit, in bytes, on memory used for all array free lists (Default: 4MB) </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">arr_list_lim</td><td>The limit, in bytes, on memory used for each array free list (Default: 256KB) </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">blk_global_lim</td><td>The cumulative limit, in bytes, on memory used for all block free lists and, separately, for all factory free lists (Default: 16MB) </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">blk_list_lim</td><td>The limit, in bytes, on memory used for each block or factory free list (Default: 1MB) </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns a non-negative value if successful; otherwise, returns a negative value.</dd></dl>
<p><a class="el" href="#gaa3f78b24b8a1ff4168db2b7ddca21545" title="Sets free-list size limits.">H5set_free_list_limits()</a> sets size limits on all types of free lists. The HDF5 library uses free lists internally to manage memory. The types of free lists used are as follows: </p><ul>
<li>Regular free lists manage memory for single internal data structures. </li>
<li>Array free lists manage memory for arrays of internal data structures. </li>
<li>Block free lists manage memory for arbitrarily-sized blocks of bytes. </li>
<li>Factory free lists manage memory for fixed-size blocks of bytes.</li>
</ul>
<p>The parameters specify global and per-list limits; for example, <code>reg_global_limit</code> and <code>reg_list_limit</code> limit the accumulated size of all regular free lists and the size of each individual regular free list, respectively. Therefore, if an application sets a 1Mb limit on each of the global lists, up to 4Mb of total storage might be allocated, 1Mb for each of the regular, array, block, and factory type lists.</p>
<p>The settings specified for block free lists are duplicated for factory free lists. Therefore, increasing the global limit on block free lists by x bytes will increase the potential free list memory usage by 2x bytes.</p>
<p>Using a value of -1 for a limit means that no limit is set for the specified type of free list.</p>
<dl class="section version"><dt>Version</dt><dd>1.8.3 Function changed in this release to set factory free list memory limits.</dd></dl>
<dl class="section since"><dt>Since</dt><dd>1.4.0 </dd></dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.10.0 </li>
  </ul>
</div>
</body>
</html>