![]() |
HDF5
1.8.23
C-API Reference
|
Currently, there are only two creation properties that you can use to control the creation of HDF5 attributes and links. The first creation property, the choice of a character encoding, applies to both attributes and links. The second creation property applies to links only, and advises the library to automatically create missing intermediate groups when creating new objects.
Functions | |
herr_t | H5Pget_create_intermediate_group (hid_t plist_id, unsigned *crt_intmd) |
Determines whether property is set to enable creating missing intermediate groups. More... | |
herr_t | H5Pset_create_intermediate_group (hid_t plist_id, unsigned crt_intmd) |
Specifies in property list whether to create missing intermediate groups. More... | |
herr_t | H5Pget_char_encoding (hid_t plist_id, H5T_cset_t *encoding) |
Retrieves the character encoding used to create a link or attribute name. More... | |
herr_t | H5Pset_char_encoding (hid_t plist_id, H5T_cset_t encoding) |
Sets the character encoding used to encode link and attribute names. More... | |
herr_t H5Pget_char_encoding | ( | hid_t | plist_id, |
H5T_cset_t * | encoding | ||
) |
Retrieves the character encoding used to create a link or attribute name.
[in] | plist_id | Link creation or attribute creation property list identifier |
[out] | encoding | String encoding character set |
H5Pget_char_encoding() retrieves the character encoding used to encode link or attribute names that are created with the property list plist_id
.
Valid values for encoding
are defined in H5Tpublic.h and include the following:
H5T_CSET_ASCII | US ASCII |
H5T_CSET_UTF8 | UTF-8 Unicode encoding |
Determines whether property is set to enable creating missing intermediate groups.
[in] | plist_id | Link creation property list identifier |
[out] | crt_intmd | Flag specifying whether to create intermediate groups upon creation of an object |
H5Pget_create_intermediate_group() determines whether the link creation property list plist_id
is set to allow functions that create objects in groups different from the current working group to create intermediate groups that may be missing in the path of a new or moved object.
Functions that create objects in or move objects to a group other than the current working group make use of this property. H5Gcreate_anon() and H5Lmove() are examples of such functions.
If crt_intmd
is positive, missing intermediate groups will be created; if crt_intmd
is non-positive, missing intermediate groups will not be created.
herr_t H5Pset_char_encoding | ( | hid_t | plist_id, |
H5T_cset_t | encoding | ||
) |
Sets the character encoding used to encode link and attribute names.
[in] | plist_id | Link creation or attribute creation property list identifier |
[in] | encoding | String encoding character set |
H5Pset_char_encoding() sets the character encoding used for the names of links (which provide the names by which objects are referenced) or attributes created with the property list plist_id
.
Valid values for encoding include the following:
H5T_CSET_ASCII | US ASCII |
H5T_CSET_UTF8 | UTF-8 Unicode encoding |
For example, if the character set for the property list plist_id
is set to H5T_CSET_UTF8, link names pointing to objects created with the link creation property list plist_id
will be encoded using the UTF-8 character set. Similarly, names of attributes created with the attribute creation property list plist_id
will be encoded as UTF-8.
ASCII and UTF-8 Unicode are the only currently supported character encodings. Extended ASCII encodings (for example, ISO 8859) are not supported. This encoding policy is not enforced by the HDF5 library. Using encodings other than ASCII and UTF-8 can lead to compatibility and usability problems.
Specifies in property list whether to create missing intermediate groups.
[in] | plist_id | Link creation property list identifier |
[in] | crt_intmd | Flag specifying whether to create intermediate groups upon the creation of an object |
H5Pset_create_intermediate_group()