Closes the specified dataset

Procedure:

H5D_CLOSE(dataset_id)

Signature:

<pre><code class="language-c">herr_t H5Dclose
(
    hid_t dataset_id
)</code></pre>

<pre><code class="language-fortran">SUBROUTINE h5dclose_f(dset_id, hdferr)
  IMPLICIT NONE
  INTEGER(HID_T), INTENT(IN) :: dset_id ! Dataset identifier  
  INTEGER, INTENT(OUT) :: hdferr        ! Error code  
                                        ! 0 on success and -1 on failure
END SUBROUTINE h5dclose_f</code></pre>

Parameters:
hid_t dataset_id    IN: Identifier of the dataset to close access to

Description:

H5D_CLOSE ends access to a dataset specified by dataset_id and releases resources used by it. Further use of the dataset identifier is illegal in calls to the dataset API.

Returns:

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

Example: