Page tree

 

JAVA

FORTRAN

C++

C

 

Link

H5S_SET_EXTENT_SIMPLE

Sets or resets the size of an existing dataspace.

Procedure:

H5S_SET_EXTENT_SIMPLE ( space_id, rank, current_size, maximum_size )

Signature:

herr_t H5Sset_extent_simple(
        hid_t space_id,
        int rank,
        const hsize_t *current_size,
        const hsize_t *maximum_size
    )

Fortran90 Interface: h5sset_extent_simple_f
    
SUBROUTINE h5sset_extent_simple_f(space_id, rank, current_size,
                                  maximum_size, hdferr) 
  IMPLICIT NONE
  INTEGER(HID_T), INTENT(IN) :: space_id     ! Dataspace identifier 
  INTEGER, INTENT(IN) :: rank                ! Dataspace rank 
  INTEGER(HSIZE_T), DIMENSION(rank), INTENT(IN) :: current_size 
                                             ! Array with the new sizes
                                             ! of dimensions 
  INTEGER(HSIZE_T), DIMENSION(rank), INTENT(IN) ::  
                                             ! Array with the new maximum
                                             ! sizes of dimensions 
  INTEGER, INTENT(OUT) :: hdferr             ! Error code
                                             ! 0 on success and -1 on failure
END SUBROUTINE h5sset_extent_simple_f

Parameters:
hid_t space_idIN: Dataspace identifier.
int rankIN: Rank, or dimensionality, of the dataspace.
const hsize_t *current_size    IN: Array containing current size of dataspace.
const hsize_t *maximum_sizeIN: Array containing maximum size of dataspace.

Description:

H5Sset_extent_simple sets or resets the size of an existing dataspace.

rank is the dimensionality, or number of dimensions, of the dataspace.

current_size is an array of size rank which contains the new size of each dimension in the dataspace. maximum_size is an array of size rank which contains the maximum size of each dimension in the dataspace.

Any previous extent is removed from the dataspace, the dataspace type is set to H5S_SIMPLE, and the extent is set as specified.

Note that a dataset must be chunked if current_size does not equal maximum_size.

Returns:

Returns a non-negative value if successful; otherwise returns a negative value.

Example:

examples / h5_attribute.c [105:106]  1.10/master  HDFFV/hdf5
   aid1 = H5Screate(H5S_SIMPLE);
   ret  = H5Sset_extent_simple(aid1, ARANK, adim, NULL);

Coming Soon!

History:

None

--- Last Modified: December 04, 2017 | 08:07 AM