HighFive 2.10.0
HighFive - Header-only C++ HDF5 interface
Loading...
Searching...
No Matches
Property Lists

Detailed Description

HDF5 is configured through what they call property lists. In HDF5 the process has four steps:

  1. Create a property list. As users we now have an hid_t identifying the property list.
  2. Set properties as desired.
  3. Pass the HID to the HDF5 function to be configured.
  4. Free the property list.

Note that the mental picture is that one creates a settings object, and then passes those settings to a function such as H5Dwrite. In and of themselves the settings don't change the behaviour of HDF5. Rather they need to be used to take affect.

The second aspect is that property lists represent any number of related settings, e.g. there's property lists anything related to creating files and another for accessing files, same for creating and accessing datasets, etc. Settings that affect creating files, must be passed a file creation property list, while settings that affect file access require a file access property list.

In HighFive the PropertyList works similar in that it's a object representing the settings, i.e. internally it's just the property lists HID. Just like in HDF5 one adds the settings to the settings object; and then passes the settings object to the respective method. Example:

// Create an object which contains the setting to
// open files with MPI-IO.
auto fapl = FileAccessProps();
fapl.add(MPIOFileAccess(MPI_COMM_WORLD, MPI_INFO_NULL);

// To open a specific file with MPI-IO, we do:
auto file = File("foo.h5", File::ReadOnly, fapl);

Note that the MPIOFileAccess object by itself doesn't affect the FileAccessProps. Rather it needs to be explicitly added to the fapl (the group of file access related settings), and then the fapl needs to be passed to the constructor of File for the settings to take affect.

This is important to understand when reading properties. Example:

// Obtain the file access property list:
auto fapl = file.getAccessPropertyList()

// Extracts a copy of the collective MPI-IO metadata settings from
// the group of file access related setting, i.e. the `fapl`:
auto mpio_metadata = MPIOCollectiveMetadata(fapl);

if(mpio_metadata.isCollectiveRead()) {
  // something specific if meta data is read collectively.
}

// Careful, this only affects the `mpio_metadata` object, but not the
//  `fapl`, and also not whether `file` uses collective MPI-IO for
// metadata.
mpio_metadata = MPIOCollectiveMetadata(false, false);

Classes

class  HighFive::PropertyListBase
 Base Class for Property lists, providing global default. More...
 
class  HighFive::PropertyList< T >
 HDF5 property Lists. More...
 
class  HighFive::RawPropertyList< T >
 
class  HighFive::MPIOFileAccess
 Configure MPI access for the file. More...
 
class  HighFive::FileVersionBounds
 Configure the version bounds for the file. More...
 
class  HighFive::MetadataBlockSize
 Configure the metadata block size to use writing to files. More...
 
class  HighFive::EstimatedLinkInfo
 Set hints as to how many links to expect and their average length. More...
 
class  HighFive::Chunking
 
class  HighFive::Deflate
 
class  HighFive::Szip
 
class  HighFive::Shuffle
 
class  HighFive::AllocationTime
 When are datasets allocated? More...
 
class  HighFive::Caching
 
class  HighFive::CreateIntermediateGroup
 
class  HighFive::UseCollectiveIO
 
class  HighFive::MpioNoCollectiveCause
 The cause for non-collective I/O. More...
 
struct  HighFive::CreationOrder
 
class  HighFive::LinkCreationOrder
 Track and index creation order time. More...
 
class  HighFive::AttributePhaseChange
 Set threshold for attribute storage. More...
 
interface  PropertyInterface
 HDF5 file property object. More...
 

Typedefs

using HighFive::ObjectCreateProps = PropertyList<PropertyType::OBJECT_CREATE>
 
using HighFive::FileCreateProps = PropertyList<PropertyType::FILE_CREATE>
 
using HighFive::FileAccessProps = PropertyList<PropertyType::FILE_ACCESS>
 
using HighFive::DataSetCreateProps = PropertyList<PropertyType::DATASET_CREATE>
 
using HighFive::DataSetAccessProps = PropertyList<PropertyType::DATASET_ACCESS>
 
using HighFive::DataTransferProps = PropertyList<PropertyType::DATASET_XFER>
 
using HighFive::GroupCreateProps = PropertyList<PropertyType::GROUP_CREATE>
 
using HighFive::GroupAccessProps = PropertyList<PropertyType::GROUP_ACCESS>
 
using HighFive::DataTypeCreateProps = PropertyList<PropertyType::DATATYPE_CREATE>
 
using HighFive::DataTypeAccessProps = PropertyList<PropertyType::DATATYPE_ACCESS>
 
using HighFive::StringCreateProps = PropertyList<PropertyType::STRING_CREATE>
 
using HighFive::AttributeCreateProps = PropertyList<PropertyType::ATTRIBUTE_CREATE>
 
using HighFive::ObjectCopyProps = PropertyList<PropertyType::OBJECT_COPY>
 
using HighFive::LinkCreateProps = PropertyList<PropertyType::LINK_CREATE>
 
using HighFive::LinkAccessProps = PropertyList<PropertyType::LINK_ACCESS>
 

Enumerations

enum class  HighFive::PropertyType : int {
  HighFive::PropertyType::OBJECT_CREATE , HighFive::PropertyType::FILE_CREATE , HighFive::PropertyType::FILE_ACCESS , HighFive::PropertyType::DATASET_CREATE ,
  HighFive::PropertyType::DATASET_ACCESS , HighFive::PropertyType::DATASET_XFER , HighFive::PropertyType::GROUP_CREATE , HighFive::PropertyType::GROUP_ACCESS ,
  HighFive::PropertyType::DATATYPE_CREATE , HighFive::PropertyType::DATATYPE_ACCESS , HighFive::PropertyType::STRING_CREATE , HighFive::PropertyType::ATTRIBUTE_CREATE ,
  HighFive::PropertyType::OBJECT_COPY , HighFive::PropertyType::LINK_CREATE , HighFive::PropertyType::LINK_ACCESS
}
 Types of property lists. More...
 

Typedef Documentation

◆ AttributeCreateProps

◆ DataSetAccessProps

◆ DataSetCreateProps

◆ DataTransferProps

◆ DataTypeAccessProps

◆ DataTypeCreateProps

◆ FileAccessProps

◆ FileCreateProps

◆ GroupAccessProps

◆ GroupCreateProps

◆ LinkAccessProps

◆ LinkCreateProps

◆ ObjectCopyProps

◆ ObjectCreateProps

◆ StringCreateProps

Enumeration Type Documentation

◆ PropertyType

enum class HighFive::PropertyType : int
strong

Types of property lists.

Enumerator
OBJECT_CREATE 
FILE_CREATE 
FILE_ACCESS 
DATASET_CREATE 
DATASET_ACCESS 
DATASET_XFER 
GROUP_CREATE 
GROUP_ACCESS 
DATATYPE_CREATE 
DATATYPE_ACCESS 
STRING_CREATE 
ATTRIBUTE_CREATE 
OBJECT_COPY 
LINK_CREATE 
LINK_ACCESS