|
H5CPP
v1.14.0
Modern C++ templates for HDF5 serial and parallel I/O
|
|
Open an existing HDF5 file at path. RAII-managed h5::fd_t returned.
Opens an existing HDF5 container at path. The flags argument controls the access mode (read-only vs read-write); fapl selects the file driver and tunes access-level behaviour.
Parameters
| Name | Type | Description |
|---|---|---|
path | const std::string& | OS file system path to an existing HDF5 container. |
flags | unsigned | H5F_ACC_RDONLY (read-only) or H5F_ACC_RDWR (read-write). |
fapl | const h5::fapl_t& | File-access property list. Defaults to h5::default_fapl. |
Returns — h5::fd_t RAII handle.
Throws
| Exception | When |
|---|---|
h5::error::io::file::open | File does not exist, permission denied, magic-byte mismatch, unsupported on-disk format. |
h5::error::property_list::misc | Invalid fapl was supplied. |
Example