Page tree

The license could not be verified: License Certificate has expired!

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »









Returns low-lever driver identifier


H5P_GET_DRIVER ( plist_id )


hid_t H5Pget_driver(
                     hid_t plist_id

Fortran90 Interface: h5pget_driver_f
SUBROUTINE h5pget_driver_f(prp_id, driver, hdferr)
  INTEGER(HID_T), INTENT(IN) :: prp_id ! Property list identifier
  INTEGER, INTENT(OUT) :: driver       ! Low-level file driver identifier
  INTEGER, INTENT(OUT) :: hdferr       ! Error code
                                       ! 0 on success and -1 on failure
END SUBROUTINE h5pget_driver_f

Replace this text with the C++ Function Signature

Replace this text with the JAVA Function Signature


hid_t plist_id     IN: File access or data transfer property list identifier.


H5Pget_driver returns the identifier of the low-level file driver associated with the file access property list or data transfer property list plist_id.

Valid driver identifiers distributed with HDF5 are listed and described in the following table.

Supported file drivers in HDF5

Driver Name

Driver Identifier

DescriptionRelated API
POSIXH5FD_SEC2This driver uses POSIX file-system functions like read and write to perform I/O to a single, permanent file on local disk with no system buffering. This driver is POSIX-compliant and is the default file driver for all systems.H5Pset_fapl_sec2
DirectH5FD_DIRECTThis is the H5FD_SEC2 driver except data is written to or read from the file synchronously without being cached by the system.H5Pset_fapl_direct
LogH5FD_LOGThis is the H5FD_SEC2 driver with logging capabilities.H5Pset_fapl_log
WindowsH5FD_WINDOWSThis driver was modified in HDF5-1.8.8 to be a wrapper of the POSIX driver, H5FD_SEC2. This change should not affect user applications.H5Pset_fapl_windows
STDIOH5FD_STDIOThis driver uses functions from the standard C stdio.h to perform I/O to a single, permanent file on local disk with additional system buffering.H5Pset_fapl_stdio
MemoryH5FD_COREWith this driver, an application can work with a file in memory for faster reads and writes. File contents are kept in memory until the file is closed. At closing, the memory version of the file can be written back to disk or abandoned.H5Pset_fapl_core
FamilyH5FD_FAMILYWith this driver, the HDF5 file’s address space is partitioned into pieces and sent to separate storage files using an underlying driver of the user’s choice. This driver is for systems that do not support files larger than 2 gigabytes.H5Pset_fapl_family
MultiH5FD_MULTIWith this driver, data can be stored in multiple files according to the type of the data. I/O might work better if data is stored in separate files based on the type of data. The Split driver is a special case of this driver.H5Pset_fapl_multi
SplitH5FD_SPLITThis file driver splits a file into two parts. One part stores metadata, and the other part stores raw data. This splitting a file into two parts is a limited case of the Multi driver.H5Pset_fapl_split
ParallelH5FD_MPIOThis is the standard HDF5 file driver for parallel file systems. This driver uses the MPI standard for both communication and file I/O.H5Pset_fapl_mpio
Parallel POSIXH5FD_MPIPOSIXThis driver is no longer available. 
StreamH5FD_STREAMThis driver is no longer available. 


This list does not include custom drivers that might be defined and registered by a user.

The returned driver identifier is only valid as long as the file driver remains registered.



Returns a valid low-level driver identifier if successful. Otherwise returns a negative value.


examples / h5_subset.c [32:42]  1.10/master  HDFFV/hdf5
main (void)
    hsize_t     dims[2], dimsm[2];   
    int         data[DIM0][DIM1];           /* data to write */
    int         sdata[DIM0_SUB][DIM1_SUB];  /* subset to write */
    int         rdata[DIM0][DIM1];          /* buffer for read */
    hid_t       file_id, dataset_id;        /* handles */
    hid_t       dataspace_id, memspace_id; 


     USE HDF5 ! This module contains all necessary modules


     CHARACTER(LEN=11), PARAMETER :: filename = "compound.h5" ! File name
     CHARACTER(LEN=8), PARAMETER :: dsetname = "Compound"     ! Dataset name
     INTEGER, PARAMETER :: dimsize = 6 ! Size of the dataset

     INTEGER(HID_T) :: file_id       ! File identifier

c++ / examples / create.cpp [33:43]  1.10/master  HDFFV/hdf5
int main (void)
    * Data initialization.
   int i, j;
   int data[NX][NY];          // buffer for data to write
   for (j = 0; j < NX; j++)
      for (i = 0; i < NY; i++)

public class H5Ex_D_Chunk {
    private static String FILENAME = "H5Ex_D_Chunk.h5";
    private static String DATASETNAME = "DS1";
    private static final int DIM_X = 6;
    private static final int DIM_Y = 8;
    private static final int CHUNK_X = 4;
    private static final int CHUNK_Y = 4;
    private static final int RANK = 2;
    private static final int NDIMS = 2;

Release    C
1.4.0Function introduced in this release.

--- Last Modified: November 16, 2017 | 12:47 PM