Removes the link to an object from a group
Procedure:
Signature:
herr_t H5Gunlink(hid_t loc_id, const char *name )
SUBROUTINE h5gunlink_f(loc_id, name, hdferr)
IMPLICIT NONE
INTEGER(HID_T), INTENT(IN) :: loc_id ! File or group identifier
CHARACTER(LEN=*), INTENT(IN) :: name ! Name of the object to unlink
INTEGER, INTENT(OUT) :: hdferr ! Error code
! 0 on success and -1 on failure
END SUBROUTINE h5gunlink_f
Parameters:
hid_t loc_id | IN: Identifier of the file or group containing the object |
const char * name | IN: Name of the object to unlink |
Description:
H5G_UNLINK removes the object specified by name
from the group graph and decrements the link count for the object to which name
points. This action eliminates any association between name
and the object to which name
pointed.
Object headers keep track of how many hard links refer to an object; when the link count reaches zero, the object can be removed from the file. Objects which are open are not removed until all identifiers to the object are closed.
If the link count reaches zero, all file space associated with the object will be released, i.e., identified in memory as freespace. If any object identifier is open for the object, the space will not be released until after the object identifier is closed.
Note that space identified as freespace is available for re-use only as long as the file remains open; once a file has been closed, the HDF5 library loses track of freespace. See “Freespace Management” in the HDF5 User's Guide for further details.
Returns:
Returns a non-negative value if successful; otherwise returns a negative value.
Example:
History:
Release | Change |
---|
1.8.0 | Function deprecated in this release. |
--- Last Modified: April 25, 2019 | 11:50 AM