FiberBundleHDF5  FiberHDF5 Documentation, Revision 2026
High-Performance Fiber Bundle Data Model for Scientific Visualization
Loading...
Searching...
No Matches
F5X.h
Go to the documentation of this file.
1/*
2 $Id: F5X.h,v 1.26 2008/02/22 23:51:25 werner Exp $
3*/
4
5#ifndef __F5_F5X_H
6#define __F5_F5X_H "Extensions to the HDF5 API"
7
8#include "hdf5inc.h"
9
10#include "F5WinDLLApi.h"
11
12#ifdef __cplusplus
13extern "C"
14{
15#endif
16
17/** \defgroup extensions Useful extension of the HDF5 API.
18 These extensions are of general use, not only in conjunction
19 with the fiber bundle concept,
20 but they just happen to sit here in this library.
21 */
22/** @{ */
23
24/** Open some URL for reading data (read-only).
25 Note that this function may well invoke the streaming HDF5
26 driver when a valid socket descriptor is given.
27 Such might well be created by a call to F5connect().
28 Note that the socket needs to be closed explicitely.
29 */
30F5_API hid_t F5open(const char *filename, int socket );
31
32/**
33 Open a socket connection to the specified host and port.
34 The URL must be of the form:
35 @code
36 HDF5://myhost.com:6666/T=0.000000/
37 @endcode
38 */
39F5_API int F5connect(const char*url);
40
41F5_API int F5listen(const char *service);
42
43/**
44 A forwarding call to the platformspecific
45 system call to close a socket.
46 */
47F5_API void F5closesocket(int socket);
48
49/** Calling windows socket init on windows */
51
52/** Calling windows socket cleanup on windows */
54
55/**
56 Create a group using utf8 encoding for the link name
57 and making use of the estimated group entry and name
58 length properties for optimization.
59 If these values are negative, no such hints will be set.
60 */
61F5_API hid_t F5Gcreate(hid_t loc_id, const char *name,
62 int est_num_entries, int est_name_len );
63
64
65/** Open some file for appending data. */
66F5_API hid_t F5append(const char *filename );
67
68/** Open some group if it exists, otherwise create one. */
69F5_API hid_t F5Gappend(hid_t loc_id, const char *name);
70
71/** Open or create a group, if created then with estimated hints
72 about its number of entries and estimated length of its member names.
73*/
74F5_API hid_t F5Gappend_hinted_creation(hid_t loc_id, const char *name,
75 int est_num_entries, int est_name_len );
76
77F5_API hid_t F5Gappend_external(hid_t loc_id, const char *name,
78 const char *target_file_name,
79 const char *target_obj_name,
80 const char *prefix );
81
82
83/** Open some dataset if it exists, otherwise create one. */
84F5_API hid_t F5Dappend(hid_t loc_id, const char *name, hid_t type_id, hid_t space_id, hid_t create_plist_id );
85
86/** Create a new dataset, possibly deleting an old one if such exists. */
87F5_API hid_t F5Dcreate(hid_t loc_id, const char *name, hid_t type_id, hid_t space_id, hid_t create_plist_id );
88
89/** Open a group */
90F5_API int F5Gopen(hid_t location, const char*name);
91
92/** Check if a group exists. */
93F5_API int F5Gexist(hid_t location, const char*name);
94
95/** Try to open an HDF5 group, silently return -1 if it does not exist. */
96F5_API hid_t F5Gtry_to_open(hid_t location, const char*name);
97
98/** Check if a dataset exists. */
99F5_API int F5Dexist(hid_t location, const char*name);
100
101F5_API hid_t F5Dtry_to_open(hid_t location, const char*name);
102
103/** Close an object regardless of its type.
104
105 Use this function to close any HDF5-Object,
106 if you do not know the type of the object.
107 This is especially usefull after a call to H5Rdereference().
108
109 @remark Normally you shouldn't use this function,
110 because you should know the objects you are creating.
111
112 @remark The function doesn't work for properties, supported are
113 only the following types:
114 - H5I_FILE
115 - H5I_GROUP
116 - H5I_DATATYPE
117 - H5I_DATASPACE
118 - H5I_DATASET
119 - H5I_ATTR
120
121 @param ret_type_id
122 A pointer to a storage to take the type of the given object.
123 See H5Iget_type() for a list of types.
124
125 @param obj_id
126 The ID of the object to be closed.
127
128 @return Error Code of the closing function.
129 (A non-negative value if successful; otherwise a negative value.)
130
131 @todo Better Error Value than "-1".
132
133 @note Could/should rename this to F5Dclose(), to denote it as
134 a function to close F5 dataset ID's, which can be HDF5
135 groups or datasets.
136 */
137F5_API herr_t F5Xclose(hid_t obj_id /*, H5I_type_t *pret_type_id*/);
138
139/**
140 Call H5Cclose with a debug message when F5_VERBOSITY is larger then 110
141 */
142F5_API herr_t _F5Gclose(hid_t id, const char*filename, int lineno);
143
144#define H5Gclose(x) _F5Gclose(x, __FILE__, __LINE__)
145
146/** @} */
147
148#ifdef __cplusplus
149} /* extern "C" */
150#endif
151
152#endif /* __F5_F5X_H */
153
name
Definition F5P.c:82
#define F5_API
Definition F5WinDLLApi.h:11
F5_API herr_t _F5Gclose(hid_t id, const char *filename, int lineno)
Definition F5private.c:342
F5_API hid_t F5Dappend(hid_t loc_id, const char *name, hid_t type_id, hid_t space_id, hid_t create_plist_id)
Definition F5X.c:239
F5_API hid_t F5Gcreate(hid_t loc_id, const char *name, int est_num_entries, int est_name_len)
Definition F5X.c:65
F5_API hid_t F5Gappend_external(hid_t loc_id, const char *name, const char *target_file_name, const char *target_obj_name, const char *prefix)
Definition F5X.c:136
F5_API int F5listen(const char *service)
Definition F5X.c:621
F5_API void F5socket_init()
Definition F5X.c:390
F5_API hid_t F5append(const char *filename)
Definition F5X.c:225
F5_API hid_t F5open(const char *filename, int socket)
Definition F5X.c:589
F5_API void F5socket_cleanup()
Definition F5X.c:408
F5_API void F5closesocket(int socket)
Definition F5X.c:582
F5_API int F5Gexist(hid_t location, const char *name)
Definition F5X.c:307
F5_API hid_t F5Dcreate(hid_t loc_id, const char *name, hid_t type_id, hid_t space_id, hid_t create_plist_id)
Definition F5X.c:278
F5_API int F5Dexist(hid_t location, const char *name)
Definition F5X.c:321
F5_API int F5connect(const char *url)
Definition F5X.c:415
F5_API hid_t F5Dtry_to_open(hid_t location, const char *name)
Definition F5X.c:335
F5_API hid_t F5Gtry_to_open(hid_t location, const char *name)
Definition F5X.c:297
F5_API int F5Gopen(hid_t location, const char *name)
F5_API herr_t F5Xclose(hid_t obj_id)
Definition F5X.c:347
F5_API hid_t F5Gappend(hid_t loc_id, const char *name)
Definition F5X.c:59
F5_API hid_t F5Gappend_hinted_creation(hid_t loc_id, const char *name, int est_num_entries, int est_name_len)
Definition F5X.c:87