h5gt 0.2.0
C++ wrapper for HDF5 library (based on HighFive project)
Loading...
Searching...
No Matches
H5Selection_misc.hpp
1/*
2 * Copyright (c), 2017, Adrien Devresse <adrien.devresse@epfl.ch>
3 *
4 * Distributed under the Boost Software License, Version 1.0.
5 * (See accompanying file LICENSE_1_0.txt or copy at
6 * http://www.boost.org/LICENSE_1_0.txt)
7 *
8 */
9#ifndef H5SELECTION_MISC_HPP
10#define H5SELECTION_MISC_HPP
11
12namespace h5gt {
13
14inline Selection::Selection(const DataSpace& memspace,
15 const DataSpace& file_space, const DataSet& set)
16 : _mem_space(memspace)
17 , _file_space(file_space)
18 , _set(set) {}
19
20inline DataSpace Selection::getSpace() const noexcept {
21 return _file_space;
22}
23
24inline DataSpace Selection::getMemSpace() const noexcept {
25 return _mem_space;
26}
27
28inline DataSet& Selection::getDataset() noexcept {
29 return _set;
30}
31
32inline const DataSet& Selection::getDataset() const noexcept {
33 return _set;
34}
35
36// Not only a shortcut but also for templated compat with H5Dataset
37inline const DataType Selection::getDataType() const {
38 return _set.getDataType();
39}
40
41} // namespace h5gt
42
43#endif // H5SELECTION_MISC_HPP
Class representing a dataset.
Definition H5DataSet.hpp:28
Class representing the space (dimensions) of a dataset.
Definition H5DataSpace.hpp:37
HDF5 Data Type.
Definition H5DataType.hpp:48
Selection(const DataSpace &space)
public constructor is needed to create virtual datasets
Definition H5Selection.hpp:27