summaryrefslogtreecommitdiffstats
path: root/src/H5VLpublic.h
diff options
context:
space:
mode:
authorM. Scot Breitenfeld <brtnfld@hdfgroup.org>2019-03-07 20:47:38 (GMT)
committerM. Scot Breitenfeld <brtnfld@hdfgroup.org>2019-03-07 20:47:38 (GMT)
commit07fde1e25c51e1c4294248311104ef02dbb7da21 (patch)
treeeeeebf3da31ab3a47716759985c375203cf04976 /src/H5VLpublic.h
parent5a51c3677e25e8426d6cd8532baa46244d645cf9 (diff)
parent8d2a047c25d2bd34c52c8d437802c309a9ae0985 (diff)
downloadhdf5-07fde1e25c51e1c4294248311104ef02dbb7da21.zip
hdf5-07fde1e25c51e1c4294248311104ef02dbb7da21.tar.gz
hdf5-07fde1e25c51e1c4294248311104ef02dbb7da21.tar.bz2
Merge branch 'develop' into H10621
Diffstat (limited to 'src/H5VLpublic.h')
-rw-r--r--src/H5VLpublic.h73
1 files changed, 45 insertions, 28 deletions
diff --git a/src/H5VLpublic.h b/src/H5VLpublic.h
index 2b055e7..f8f5423 100644
--- a/src/H5VLpublic.h
+++ b/src/H5VLpublic.h
@@ -22,6 +22,7 @@
#include "H5Apublic.h" /* Attributes */
#include "H5ESpublic.h" /* Event Stack */
#include "H5Fpublic.h" /* Files */
+#include "H5Ipublic.h" /* IDs */
#include "H5Lpublic.h" /* Links */
#include "H5Opublic.h" /* Objects */
#include "H5Rpublic.h" /* References */
@@ -115,7 +116,7 @@ typedef enum H5VL_file_get_t {
H5VL_FILE_GET_INTENT, /* file intent */
H5VL_FILE_GET_NAME, /* file name */
H5VL_FILE_GET_OBJ_COUNT, /* object count in file */
- H5VL_FILE_GET_OBJ_IDS /* object ids in file */
+ H5VL_FILE_GET_OBJ_IDS /* object ids in file */
} H5VL_file_get_t;
/* types for file SPECIFIC callback */
@@ -124,8 +125,7 @@ typedef enum H5VL_file_specific_t {
H5VL_FILE_REOPEN, /* Reopen the file */
H5VL_FILE_MOUNT, /* Mount a file */
H5VL_FILE_UNMOUNT, /* Unmount a file */
- H5VL_FILE_IS_ACCESSIBLE, /* Check if a file is accessible */
- H5VL_FILE_CACHE_VOL_CONN /* Cache VOL connector ID & info */
+ H5VL_FILE_IS_ACCESSIBLE /* Check if a file is accessible */
} H5VL_file_specific_t;
/* types for group GET callback */
@@ -236,6 +236,25 @@ typedef struct H5VL_loc_params_t {
} loc_data;
} H5VL_loc_params_t;
+/* VOL connector info fields & callbacks */
+typedef struct H5VL_info_class_t {
+ size_t size; /* Size of the VOL info */
+ void * (*copy)(const void *info); /* Callback to create a copy of the VOL info */
+ herr_t (*cmp)(int *cmp_value, const void *info1, const void *info2); /* Callback to compare VOL info */
+ herr_t (*free)(void *info); /* Callback to release a VOL info */
+ herr_t (*to_str)(const void *info, char **str); /* Callback to serialize connector's info into a string */
+ herr_t (*from_str)(const char *str, void **info); /* Callback to deserialize a string into connector's info */
+} H5VL_info_class_t;
+
+/* VOL object wrap / retrieval callbacks */
+/* (These only need to be implemented by "pass through" VOL connectors) */
+typedef struct H5VL_wrap_class_t {
+ void * (*get_object)(const void *obj); /* Callback to retrieve underlying object */
+ herr_t (*get_wrap_ctx)(const void *obj, void **wrap_ctx); /* Callback to retrieve the object wrapping context for the connector */
+ void * (*wrap_object)(void *obj, H5I_type_t obj_type, void *wrap_ctx); /* Callback to wrap a library object */
+ herr_t (*free_wrap_ctx)(void *wrap_ctx); /* Callback to release the object wrapping context for the connector */
+} H5VL_wrap_class_t;
+
/* H5A routines */
typedef struct H5VL_attr_class_t {
void *(*create)(void *obj, const H5VL_loc_params_t *loc_params, const char *attr_name,
@@ -370,34 +389,29 @@ typedef int H5VL_class_value_t;
/* Class information for each VOL connector */
typedef struct H5VL_class_t {
- unsigned int version; /* VOL connector class struct version # */
- H5VL_class_value_t value; /* Value to identify connector */
- const char *name; /* Connector name (MUST be unique!) */
- unsigned cap_flags; /* Capability flags for connector */
- herr_t (*initialize)(hid_t vipl_id); /* Connector initialization callback */
- herr_t (*terminate)(void); /* Connector termination callback */
- size_t info_size; /* Size of the VOL info */
- void * (*info_copy)(const void *info); /* Callback to create a copy of the VOL info */
- herr_t (*info_cmp)(int *cmp_value, const void *info1, const void *info2); /* Callback to compare VOL info */
- herr_t (*info_free)(void *info); /* Callback to release the VOL info copy */
- herr_t (*info_to_str)(const void *info, char **str); /* Callback to serialize connector's info into a string */
- herr_t (*str_to_info)(const char *str, void **info); /* Callback to deserialize a string into connector's info */
- void * (*get_object)(const void *obj); /* Callback to retrieve underlying object */
- herr_t (*get_wrap_ctx)(const void *obj, void **wrap_ctx); /* Callback to retrieve the object wrapping context for the connector */
- void* (*wrap_object)(void *obj, void *wrap_ctx); /* Callback to wrap a library object */
- herr_t (*free_wrap_ctx)(void *wrap_ctx); /* Callback to release the object wrapping context for the connector */
+ /* Overall connector fields & callbacks */
+ unsigned int version; /* VOL connector class struct version # */
+ H5VL_class_value_t value; /* Value to identify connector */
+ const char *name; /* Connector name (MUST be unique!) */
+ unsigned cap_flags; /* Capability flags for connector */
+ herr_t (*initialize)(hid_t vipl_id); /* Connector initialization callback */
+ herr_t (*terminate)(void); /* Connector termination callback */
+
+ /* VOL framework */
+ H5VL_info_class_t info_cls; /* VOL info fields & callbacks */
+ H5VL_wrap_class_t wrap_cls; /* VOL object wrap / retrieval callbacks */
/* Data Model */
- H5VL_attr_class_t attr_cls; /* attribute class callbacks */
- H5VL_dataset_class_t dataset_cls; /* dataset class callbacks */
- H5VL_datatype_class_t datatype_cls; /* datatype class callbacks */
- H5VL_file_class_t file_cls; /* file class callbacks */
- H5VL_group_class_t group_cls; /* group class callbacks */
- H5VL_link_class_t link_cls; /* link class callbacks */
- H5VL_object_class_t object_cls; /* object class callbacks */
+ H5VL_attr_class_t attr_cls; /* Attribute (H5A*) class callbacks */
+ H5VL_dataset_class_t dataset_cls; /* Dataset (H5D*) class callbacks */
+ H5VL_datatype_class_t datatype_cls; /* Datatype (H5T*) class callbacks */
+ H5VL_file_class_t file_cls; /* File (H5F*) class callbacks */
+ H5VL_group_class_t group_cls; /* Group (H5G*) class callbacks */
+ H5VL_link_class_t link_cls; /* Link (H5L*) class callbacks */
+ H5VL_object_class_t object_cls; /* Object (H5O*) class callbacks */
/* Services */
- H5VL_request_class_t request_cls; /* asynchronous request class callbacks */
+ H5VL_request_class_t request_cls; /* Asynchronous request class callbacks */
/* Catch-all */
herr_t (*optional)(void *obj, hid_t dxpl_id, void **req, va_list arguments); /* Optional callback */
@@ -434,6 +448,8 @@ H5_DLL herr_t H5VLunregister_connector(hid_t connector_id);
/* Helper routines for VOL connector authors */
H5_DLL herr_t H5VLcmp_connector_cls(int *cmp, hid_t connector_id1, hid_t connector_id2);
+H5_DLL hid_t H5VLwrap_register(void *obj, H5I_type_t type);
+H5_DLL void *H5VLobject(hid_t obj_id);
/* Public wrappers for generic callbacks */
@@ -449,7 +465,8 @@ H5_DLL herr_t H5VLconnector_info_to_str(const void *info, hid_t connector_id, ch
H5_DLL herr_t H5VLconnector_str_to_info(const char *str, hid_t connector_id, void **info);
H5_DLL void *H5VLget_object(void *obj, hid_t connector_id);
H5_DLL herr_t H5VLget_wrap_ctx(void *obj, hid_t connector_id, void **wrap_ctx);
-H5_DLL void *H5VLwrap_object(void *obj, hid_t connector_id, void *wrap_ctx);
+H5_DLL void *H5VLwrap_object(void *obj, H5I_type_t obj_type, hid_t connector_id,
+ void *wrap_ctx);
H5_DLL herr_t H5VLfree_wrap_ctx(void *wrap_ctx, hid_t connector_id);
/* Public wrappers for attribute callbacks */
Tcl is a high-level, general-purpose, interpreted, dynamic programming language. It was designed with the goal of being very simple but powerful.
summaryrefslogtreecommitdiffstats
path: root/mac/tclMacMath.h
blob: 7ec3257cf6b23cf40434bf58dd2223a3eb7c0443 (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
/*
 * tclMacMath.h --
 *
 *	This file is necessary because of Metrowerks CodeWarrior Pro 1
 *	on the Macintosh. With 8-byte doubles turned on, the definitions of
 *	sin, cos, acos, etc., are screwed up.  They are fine as long as
 *	they are used as function calls, but if the function pointers
 *	are passed around and used, they will crash hard on the 68K.
 *
 * Copyright (c) 1997 Sun Microsystems, Inc.
 *
 * See the file "license.terms" for information on usage and redistribution
 * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
 *
 * SCCS: @(#) tclMacMath.h 1.2 97/07/28 11:04:02
 */

#ifndef _TCLMACMATH
#define _TCLMACMATH

#include <math.h>

#if defined(__MWERKS__) && !defined(__POWERPC__)
#if __option(IEEEdoubles)

#   ifdef cos
#	undef cos
#	define cos cosd
#   endif

#   ifdef sin
#	undef sin
#	define sin sind
#   endif

#   ifdef tan
#	undef tan
#	define tan tand
#   endif

#   ifdef acos
#	undef acos
#	define acos acosd
#   endif

#   ifdef asin
#	undef asin
#	define asin asind
#   endif

#   ifdef atan
#	undef atan
#	define atan atand
#   endif

#   ifdef cosh
#	undef cosh
#	define cosh coshd
#   endif

#   ifdef sinh
#	undef sinh
#	define sinh sinhd
#   endif

#   ifdef tanh
#	undef tanh
#	define tanh tanhd
#   endif

#   ifdef exp
#	undef exp
#	define exp expd
#   endif

#   ifdef ldexp
#	undef ldexp
#	define ldexp ldexpd
#   endif

#   ifdef log
#	undef log
#	define log logd
#   endif

#   ifdef log10
#	undef log10
#	define log10 log10d
#   endif

#   ifdef fabs
#	undef fabs
#	define fabs fabsd
#   endif

#   ifdef sqrt
#	undef sqrt
#	define sqrt sqrtd
#   endif

#   ifdef fmod
#	undef fmod
#	define fmod fmodd
#   endif

#   ifdef atan2
#	undef atan2
#	define atan2 atan2d
#   endif

#   ifdef frexp
#	undef frexp
#	define frexp frexpd
#   endif

#   ifdef modf
#	undef modf
#	define modf modfd
#   endif

#   ifdef pow
#	undef pow
#	define pow powd
#   endif

#   ifdef ceil
#	undef ceil
#	define ceil ceild
#   endif

#   ifdef floor
#	undef floor
#	define floor floord
#   endif
#endif
#endif

#if (defined(THINK_C) || defined(__MWERKS__))
#pragma export on
double		hypotd(double x, double y);
#define hypot hypotd
#pragma export reset
#endif

#endif /* _TCLMACMATH */