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 files COPYING and Copyright.html. COPYING can be found at the root * |
---|
9 | * of the source code distribution tree; Copyright.html can be found at the * |
---|
10 | * root level of an installed copy of the electronic HDF5 document set and * |
---|
11 | * is linked from the top-level documents page. It can also be found at * |
---|
12 | * http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have * |
---|
13 | * access to either file, you may request a copy from help@hdfgroup.org. * |
---|
14 | * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ |
---|
15 | |
---|
16 | /* |
---|
17 | * This file contains public declarations for the H5D module. |
---|
18 | */ |
---|
19 | #ifndef _H5Dpublic_H |
---|
20 | #define _H5Dpublic_H |
---|
21 | |
---|
22 | /* System headers needed by this file */ |
---|
23 | |
---|
24 | /* Public headers needed by this file */ |
---|
25 | #include "H5public.h" |
---|
26 | #include "H5Ipublic.h" |
---|
27 | |
---|
28 | /*****************/ |
---|
29 | /* Public Macros */ |
---|
30 | /*****************/ |
---|
31 | |
---|
32 | /*******************/ |
---|
33 | /* Public Typedefs */ |
---|
34 | /*******************/ |
---|
35 | |
---|
36 | /* Values for the H5D_LAYOUT property */ |
---|
37 | typedef enum H5D_layout_t { |
---|
38 | H5D_LAYOUT_ERROR = -1, |
---|
39 | |
---|
40 | H5D_COMPACT = 0, /*raw data is very small */ |
---|
41 | H5D_CONTIGUOUS = 1, /*the default */ |
---|
42 | H5D_CHUNKED = 2, /*slow and fancy */ |
---|
43 | H5D_NLAYOUTS = 3 /*this one must be last! */ |
---|
44 | } H5D_layout_t; |
---|
45 | |
---|
46 | /* Values for the space allocation time property */ |
---|
47 | typedef enum H5D_alloc_time_t { |
---|
48 | H5D_ALLOC_TIME_ERROR = -1, |
---|
49 | H5D_ALLOC_TIME_DEFAULT = 0, |
---|
50 | H5D_ALLOC_TIME_EARLY = 1, |
---|
51 | H5D_ALLOC_TIME_LATE = 2, |
---|
52 | H5D_ALLOC_TIME_INCR = 3 |
---|
53 | } H5D_alloc_time_t; |
---|
54 | |
---|
55 | /* Values for the status of space allocation */ |
---|
56 | typedef enum H5D_space_status_t { |
---|
57 | H5D_SPACE_STATUS_ERROR = -1, |
---|
58 | H5D_SPACE_STATUS_NOT_ALLOCATED = 0, |
---|
59 | H5D_SPACE_STATUS_PART_ALLOCATED = 1, |
---|
60 | H5D_SPACE_STATUS_ALLOCATED = 2 |
---|
61 | } H5D_space_status_t; |
---|
62 | |
---|
63 | /* Values for time of writing fill value property */ |
---|
64 | typedef enum H5D_fill_time_t { |
---|
65 | H5D_FILL_TIME_ERROR = -1, |
---|
66 | H5D_FILL_TIME_ALLOC = 0, |
---|
67 | H5D_FILL_TIME_NEVER = 1, |
---|
68 | H5D_FILL_TIME_IFSET = 2 |
---|
69 | } H5D_fill_time_t; |
---|
70 | |
---|
71 | /* Values for fill value status */ |
---|
72 | typedef enum H5D_fill_value_t { |
---|
73 | H5D_FILL_VALUE_ERROR =-1, |
---|
74 | H5D_FILL_VALUE_UNDEFINED =0, |
---|
75 | H5D_FILL_VALUE_DEFAULT =1, |
---|
76 | H5D_FILL_VALUE_USER_DEFINED =2 |
---|
77 | } H5D_fill_value_t; |
---|
78 | |
---|
79 | /********************/ |
---|
80 | /* Public Variables */ |
---|
81 | /********************/ |
---|
82 | |
---|
83 | /*********************/ |
---|
84 | /* Public Prototypes */ |
---|
85 | /*********************/ |
---|
86 | #ifdef __cplusplus |
---|
87 | extern "C" { |
---|
88 | #endif |
---|
89 | |
---|
90 | /* Define the operator function pointer for H5Diterate() */ |
---|
91 | typedef herr_t (*H5D_operator_t)(void *elem, hid_t type_id, unsigned ndim, |
---|
92 | const hsize_t *point, void *operator_data); |
---|
93 | |
---|
94 | H5_DLL hid_t H5Dcreate2(hid_t loc_id, const char *name, hid_t type_id, |
---|
95 | hid_t space_id, hid_t lcpl_id, hid_t dcpl_id, hid_t dapl_id); |
---|
96 | H5_DLL hid_t H5Dcreate_anon(hid_t file_id, hid_t type_id, hid_t space_id, |
---|
97 | hid_t plist_id, hid_t dapl_id); |
---|
98 | H5_DLL hid_t H5Dopen2(hid_t file_id, const char *name, hid_t dapl_id); |
---|
99 | H5_DLL herr_t H5Dclose(hid_t dset_id); |
---|
100 | H5_DLL hid_t H5Dget_space(hid_t dset_id); |
---|
101 | H5_DLL herr_t H5Dget_space_status(hid_t dset_id, H5D_space_status_t *allocation); |
---|
102 | H5_DLL hid_t H5Dget_type(hid_t dset_id); |
---|
103 | H5_DLL hid_t H5Dget_create_plist(hid_t dset_id); |
---|
104 | H5_DLL hsize_t H5Dget_storage_size(hid_t dset_id); |
---|
105 | H5_DLL haddr_t H5Dget_offset(hid_t dset_id); |
---|
106 | H5_DLL herr_t H5Dread(hid_t dset_id, hid_t mem_type_id, hid_t mem_space_id, |
---|
107 | hid_t file_space_id, hid_t plist_id, void *buf/*out*/); |
---|
108 | H5_DLL herr_t H5Dwrite(hid_t dset_id, hid_t mem_type_id, hid_t mem_space_id, |
---|
109 | hid_t file_space_id, hid_t plist_id, const void *buf); |
---|
110 | H5_DLL herr_t H5Diterate(void *buf, hid_t type_id, hid_t space_id, |
---|
111 | H5D_operator_t op, void *operator_data); |
---|
112 | H5_DLL herr_t H5Dvlen_reclaim(hid_t type_id, hid_t space_id, hid_t plist_id, void *buf); |
---|
113 | H5_DLL herr_t H5Dvlen_get_buf_size(hid_t dataset_id, hid_t type_id, hid_t space_id, hsize_t *size); |
---|
114 | H5_DLL herr_t H5Dfill(const void *fill, hid_t fill_type, void *buf, |
---|
115 | hid_t buf_type, hid_t space); |
---|
116 | H5_DLL herr_t H5Dset_extent(hid_t dset_id, const hsize_t size[]); |
---|
117 | H5_DLL herr_t H5Ddebug(hid_t dset_id); |
---|
118 | |
---|
119 | /* Symbols defined for compatibility with previous versions of the HDF5 API. |
---|
120 | * |
---|
121 | * Use of these symbols is deprecated. |
---|
122 | */ |
---|
123 | #ifndef H5_NO_DEPRECATED_SYMBOLS |
---|
124 | |
---|
125 | /* Macros */ |
---|
126 | |
---|
127 | |
---|
128 | /* Typedefs */ |
---|
129 | |
---|
130 | |
---|
131 | /* Function prototypes */ |
---|
132 | H5_DLL hid_t H5Dcreate1(hid_t file_id, const char *name, hid_t type_id, |
---|
133 | hid_t space_id, hid_t dcpl_id); |
---|
134 | H5_DLL hid_t H5Dopen1(hid_t file_id, const char *name); |
---|
135 | H5_DLL herr_t H5Dextend(hid_t dset_id, const hsize_t size[]); |
---|
136 | |
---|
137 | #endif /* H5_NO_DEPRECATED_SYMBOLS */ |
---|
138 | |
---|
139 | #ifdef __cplusplus |
---|
140 | } |
---|
141 | #endif |
---|
142 | #endif /* _H5Dpublic_H */ |
---|
143 | |
---|