H5Fget_obj_ids(
hid_t file_id,
unsigned int types,
size_t max_objs,
hid_t *obj_id_list
)file_id and
the type of objects to be identified, types,
H5Fget_obj_ids returns the list of identifiers
for all open HDF5 objects fitting the specified criteria.
To retrieve identifiers for open objects in all HDF5 application
files that are currently open, pass the value
H5F_OBJ_ALL in file_id.
The types of object identifiers to be retrieved are specified
in types using the codes listed for the same
parameter in H5Fget_obj_count.
To retrieve identifiers for all open objects, pass a negative value
for max_objs.
To retrieve a count of open objects, use the
H5Fget_obj_count function. This count can be used to
set the max_objs parameter.
hid_t file_id |
IN: Identifier of a currently-open HDF5 file or
H5F_OBJ_ALL for all currently-open HDF5 files. |
unsigned int types |
IN: Type of object for which identifiers are to be returned. |
size_t max_objs |
IN: Maximum number of object identifiers to place into
obj_id_list. |
hid_t *obj_id_list |
OUT: Pointer to the returned list of open object identifiers. |
obj_id_list if successful;
otherwise returns a negative value.
SUBROUTINE h5fget_obj_ids_f(file_id, obj_type, max_objs, obj_ids, hdferr, num_objs)
IMPLICIT NONE
INTEGER(HID_T), INTENT(IN) :: file_id ! File identifier
INTEGER, INTENT(IN) :: obj_type ! Object types, possible values are:
! H5F_OBJ_FILE_F
! H5F_OBJ_GROUP_F
! H5F_OBJ_DATASET_F
! H5F_OBJ_DATATYPE_F
! H5F_OBJ_ALL_F
INTEGER(SIZE_T), INTENT(IN) :: max_objs ! Maximum number of object
! identifiers to retrieve
INTEGER(HID_T), DIMENSION(*), INTENT(OUT) :: obj_ids
! Array of requested object
! identifiers
INTEGER, INTENT(OUT) :: hdferr ! Error code
! 0 on success and -1 on failure
INTEGER(SIZE_T), INTENT(OUT), OPTIONAL :: num_objs
! number of open objects of the specified type
END SUBROUTINE h5fget_obj_ids_f
| Release | Change |
| 1.6.0 | C function introduced in this release. |
| 1.6.8 & 1.8.2 |
C function return type changed to ssize_t
and max_objs parameter datatype changed to
size_t. |