59 const property::FileCreationList &fcpl = property::FileCreationList(),
60 const property::FileAccessList &fapl = property::FileAccessList());
63 const property::FileCreationList &fcpl = property::FileCreationList(),
64 const property::FileAccessList &fapl = property::FileAccessList());
79 const property::FileAccessList &fapl = property::FileAccessList());
82 const property::FileAccessList &fapl = property::FileAccessList());
122 return from_buffer(data, static_cast<ImageFlagsBase>(flags));
128 return from_buffer(data, static_cast<ImageFlagsBase>(flags));
136 throw std::runtime_error(
"Invalid ImageFlags for const buffer");
137 return from_buffer(const_cast<T&>(data), static_cast<ImageFlagsBase>(flags));
145 size_t databytesize = memory_space.size() * memory_type.size();
150 fid = H5LTopen_file_image(
dataspace::ptr(data), databytesize, flags);
153 std::stringstream ss;
154 ss <<
"Failure opening file image";
161 std::stringstream ss;
162 ss<<
"Failure to open non-integer buffer";
TypeTrait< T >::DataspaceType create(const T &value)
factory function for dataspaces
Definition: type_trait.hpp:115
static Singleton & instance()
reference to singleton
Definition: error.hpp:50
void throw_with_stack(const std::string &message)
throws an exception, potentially nested with error stack
indicates an integer type
bool is_hdf5_file(const fs::path &path)
check if the file reference by the path is an HDF5 file
Wrapper for hid_t object identifiers.
Definition: object_handle.hpp:66
File from_buffer(T &data, ImageFlags flags=ImageFlags::READONLY)
load an image file from a buffer
Definition: functions.hpp:120
ImageFlags
flags controlling image file opening and getting
Definition: types.hpp:59
std::underlying_type< ImageFlags >::type ImageFlagsBase
Definition: types.hpp:68
Definition: attribute.hpp:43
std::underlying_type< AccessFlags >::type AccessFlagsBase
Definition: types.hpp:48
TypeTrait< typename std::remove_const< T >::type >::TypeClass create(const T &v=T())
factory function for creating data types
Definition: factory.hpp:38
void * ptr(T &value)
Definition: type_trait.hpp:120
#define DLL_EXPORT
Definition: windows.hpp:35
File create(const fs::path &path, AccessFlags flags=AccessFlags::EXCLUSIVE, const property::FileCreationList &fcpl=property::FileCreationList(), const property::FileAccessList &fapl=property::FileAccessList())
create a new file
File open(const fs::path &path, AccessFlags flags=AccessFlags::READONLY, const property::FileAccessList &fapl=property::FileAccessList())
open an existing file
AccessFlags
flags controlling file opening and creation
Definition: types.hpp:37