H5Aget_name
(hid_t attr_id
,
size_t buf_size
,
char *buf
)
H5Aget_name
retrieves the name of an attribute
specified by the identifier, attr_id
. Up to
buf_size
characters are stored in buf followed by
a \0 string terminator. If the name of the attribute is longer
than (buf_size
-1), the string terminator is stored
in the last position of the buffer to properly terminate the string.
If the user only wants to find out the size of this name,
the values 0
and NULL
can be passed in for the parameters bufsize
and
buf
.
hid_t attr_id |
IN: Identifier of the attribute. |
size_t buf_size |
IN: The size of the buffer to store the name in. |
char *buf |
OUT: Buffer to store name in. |
buf_size
, if successful.
Otherwise returns a negative value.
SUBROUTINE h5aget_name_f(attr_id, size, buf, hdferr) IMPLICIT NONE INTEGER(HID_T), INTENT(IN) :: attr_id ! Attribute identifier INTEGER(SIZE_T), INTENT(IN) :: size ! Buffer size CHARACTER(LEN=*), INTENT(INOUT) :: buf ! Buffer to hold attribute name INTEGER, INTENT(OUT) :: hdferr ! Error code: ! name length is successful, ! -1 if fail END SUBROUTINE h5aget_name_f