h5cpp  0.5.1
A modern C++ wrapper for the HDF5 C library
hdf5::node::ChunkedDataset Class Reference

dataset with chunked layout More...

#include <chunked_dataset.hpp>

Inheritance diagram for hdf5::node::ChunkedDataset:
Collaboration diagram for hdf5::node::ChunkedDataset:

Public Member Functions

 ChunkedDataset ()=default
 default constructor More...
 
 ChunkedDataset (const ChunkedDataset &)=default
 copy constructor More...
 
 ChunkedDataset (const Group &base, const Path &path, const datatype::Datatype &type, const dataspace::Simple &space, const Dimensions &chunk_shape, const property::LinkCreationList &lcpl=property::LinkCreationList(), const property::DatasetCreationList &dcpl=property::DatasetCreationList(), const property::DatasetAccessList &dapl=property::DatasetAccessList())
 constructor More...
 
- Public Member Functions inherited from hdf5::node::Dataset
 Dataset ()=default
 default constructor More...
 
 Dataset (const Node &node)
 construct More...
 
 Dataset (const Group &base, const Path &path, const datatype::Datatype &type, const dataspace::Dataspace &space=dataspace::Scalar(), const property::LinkCreationList &lcpl=property::LinkCreationList(), const property::DatasetCreationList &dcpl=property::DatasetCreationList(), const property::DatasetAccessList &dapl=property::DatasetAccessList())
 constructor More...
 
dataspace::Dataspace dataspace () const
 get dataspace of dataset More...
 
property::DatasetCreationList creation_list () const
 get the dataset creation property list used for creation More...
 
property::DatasetAccessList access_list () const
 get the dataset access property list for the instance More...
 
datatype::Datatype datatype () const
 get datatype of dataset More...
 
void extent (const Dimensions &dims) const
 set extent of the dataset More...
 
void extent (size_t dim, ssize_t delta_elements) const
 
void resize (const Dimensions &dims) const
 resize the dataset More...
 
void refresh () const
 refresh the dataset (since hdf5 1.10.0) More...
 
template<typename T >
void write (const T &data, const datatype::Datatype &mem_type, const dataspace::Dataspace &mem_space, const dataspace::Dataspace &file_space, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 write data to the dataset More...
 
template<typename T >
void write (const T &data, const datatype::Datatype &mem_type, const dataspace::Dataspace &mem_space, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 write data to the dataset More...
 
template<typename T >
void read (T &data, const datatype::Datatype &mem_type, const dataspace::Dataspace &mem_space, const dataspace::Dataspace &file_space, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 read data from the dataset More...
 
template<typename T >
void read (T &data, const datatype::Datatype &mem_type, const dataspace::Dataspace &mem_space, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 
template<typename T >
void read_reshape (T &data, const datatype::Datatype &mem_type, const dataspace::Dataspace &mem_space, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 
template<typename T >
void write (const T &data, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get())
 write entire dataset More...
 
template<typename T >
void write (const T &data, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 
template<typename T >
void write_reshape (const T &data, const datatype::Datatype &mem_type, const dataspace::Dataspace &mem_space, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 write entire dataset More...
 
void write (const char *data, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get())
 write entire dataset More...
 
void write (const char *data, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 
template<typename T >
void write_chunk (const T &data, std::vector< unsigned long long > offset, std::uint32_t filter_mask=0, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get())
 write dataset chunk More...
 
template<typename T >
void write_chunk (const T &data, std::vector< unsigned long long > offset, std::uint32_t filter_mask=0, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 
template<typename T >
void write_chunk (const T &data, const datatype::Datatype &mem_type, const dataspace::Dataspace &mem_space, std::vector< unsigned long long > &offset, std::uint32_t filter_mask=0, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 write dataset chunk More...
 
template<typename T >
std::uint32_t read_chunk (T &data, std::vector< unsigned long long > offset, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 read dataset chunk (since hdf5 1.10.2) More...
 
template<typename T >
std::uint32_t read_chunk (T &data, const datatype::Datatype &mem_type, std::vector< unsigned long long > &offset, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 read dataset chunk More...
 
unsigned long long chunk_storage_size (std::vector< unsigned long long > offset) const
 read dataset chunk More...
 
template<typename T >
void read (T &data, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get())
 read entire dataset More...
 
template<typename T >
void read (T &data, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 
template<typename T >
void write (const T &data, const dataspace::Selection &selection, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get())
 write data to a selection More...
 
template<typename T >
void write (const T &data, const dataspace::Selection &selection, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 
template<typename T >
void write_reshape (const T &data, const datatype::Datatype &mem_type, const dataspace::Dataspace &mem_space, const dataspace::Selection &selection, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 write data to a selection More...
 
template<typename T >
void read (T &data, const dataspace::Selection &selection, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get())
 reading data from a selection More...
 
template<typename T >
void read (T &data, const dataspace::Selection &selection, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 
template<typename T >
void read_reshape (T &data, const datatype::Datatype &mem_type, const dataspace::Dataspace &mem_space, const dataspace::Selection &selection, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 reading data from a selection More...
 
template<typename T >
void read (T &data, const datatype::Datatype &memory_type, const dataspace::Dataspace &memory_space, const dataspace::Selection &file_selection, const property::DatasetTransferList &dtpl=property::DatasetTransferList::get()) const
 reading data from a dataset More...
 
filter::ExternalFilters filters () const
 get the dataset external filters for the instance More...
 
- Public Member Functions inherited from hdf5::node::Node
 Node (ObjectHandle &&handle, const Link &link)
 constructor More...
 
 Node ()
 default constructor More...
 
 Node (const Node &)
 copy constructor More...
 
Nodeoperator= (const Node &node)
 copy assignment More...
 
virtual ~Node ()
 destructor More...
 
NodeType type () const
 return the node type More...
 
ObjectId id () const
 get unique ID More...
 
 operator hid_t () const
 
bool is_valid () const
 true if an object is valid More...
 
void close ()
 close the node More...
 
const Linklink () const
 return link to object More...
 

Additional Inherited Members

- Public Attributes inherited from hdf5::node::Node
attribute::AttributeManager attributes
 access to the attribute manager More...
 

Detailed Description

This class provides an convenient interface to a chunked dataset. As a matter of fact the only thing added here is a convenient constructor where the chunk shape can be passed as an additional argument.

Constructor & Destructor Documentation

◆ ChunkedDataset() [1/3]

hdf5::node::ChunkedDataset::ChunkedDataset ( )
default

Required for STL compliance. We can use the compiler provided default implementation here.

◆ ChunkedDataset() [2/3]

hdf5::node::ChunkedDataset::ChunkedDataset ( const ChunkedDataset )
default

Required for STL compliance. We can use the compiler provided default implementation here.

◆ ChunkedDataset() [3/3]

hdf5::node::ChunkedDataset::ChunkedDataset ( const Group base,
const Path path,
const datatype::Datatype type,
const dataspace::Simple space,
const Dimensions chunk_shape,
const property::LinkCreationList lcpl = property::LinkCreationList(),
const property::DatasetCreationList dcpl = property::DatasetCreationList(),
const property::DatasetAccessList dapl = property::DatasetAccessList() 
)

As for all dataset constructors, references to the required property list can be passed as optional arguments. There are two things worth noting here

  • the dataspace for a chunked dataset must be a simple dataspace
  • independent of the configuration of an eventually user provided dataset creation property list, the layout of the dataset will be chunked with the provided chunk shape.

The user provided dataset creation property list will not be changed.

Exceptions
std::runtime_errorin case of a failure
Parameters
basethe base object for the dataset creation
paththe path to the new dataset
typeoptional reference to a datatype
spaceoptional reference to a dataspace
chunk_shapereference to the chunk shape
lcploptional reference to a link creation property list
dcploptional reference to a dataset creation property list
daploptional reference to a dataset access property list

The documentation for this class was generated from the following file: