Phoxonics  1.0
Object Oriented FDTD Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Hdf5Base.hpp
Go to the documentation of this file.
1 /*
2  * Hdf5Base.hpp
3  *
4  * Created on: Nov 18, 2014
5  * Author: nano
6  */
7 
8 #ifndef HDF5BASE_HPP_
9 #define HDF5BASE_HPP_
10 
11 #include "../common/CommonBase.hpp"
12 #include "H5Cpp.h"
13 
14 namespace phoxonics {
15 namespace common {
16 
17 class Hdf5Base : public CommonBase {
18 public:
19  explicit Hdf5Base(std::string h5_file_name, std::string dataset_name, bool print_exception);
20  virtual ~Hdf5Base();
21 
22  // create dataset slice
23  virtual void create_dataset_slice(const void* data);
24 
25  // create dataset
26  virtual void create_dataset(const void* data);
27 
28 protected:
29  // file and data set name for the generated h5
30  H5std_string h5_file_name_;
31  H5std_string dataset_name_;
32 
33  // print hdf5 internal exception system
35 
36  // dim y dataset extend variable
37  long long unsigned int dim_y_extend_ { 1 };
38 
39  // dim z dataset extend variable
40  long long unsigned int dim_z_extend_ { 1 };
41 
42  // data offset, this must increment
43  long long unsigned int data_offset_ { 0 };
44 };
45 
46 } /* namespace common */
47 } /* namespace phoxonics */
48 
49 #endif /* HDF5BASE_HPP_ */
Definition: CommonBase.hpp:14
H5std_string dataset_name_
Definition: Hdf5Base.hpp:31
long long unsigned int dim_z_extend_
Definition: Hdf5Base.hpp:40
long long unsigned int data_offset_
Definition: Hdf5Base.hpp:43
H5std_string h5_file_name_
Definition: Hdf5Base.hpp:30
Definition: CommonBase.hpp:17
virtual ~Hdf5Base()
Definition: Hdf5Base.cpp:21
Definition: Hdf5Base.hpp:17
virtual void create_dataset_slice(const void *data)
Definition: Hdf5Base.cpp:25
Hdf5Base(std::string h5_file_name, std::string dataset_name, bool print_exception)
Definition: Hdf5Base.cpp:13
bool print_exception_
Definition: Hdf5Base.hpp:34
virtual void create_dataset(const void *data)
Definition: Hdf5Base.cpp:30
long long unsigned int dim_y_extend_
Definition: Hdf5Base.hpp:37