Flow123d  jenkins-Flow123d-windows-release-multijob-285
output_data_base.hh
Go to the documentation of this file.
1 /*
2  * output_data_base.hh
3  *
4  * Created on: Mar 16, 2014
5  * Author: jb
6  */
7 
8 #ifndef OUTPUT_DATA_BASE_HH_
9 #define OUTPUT_DATA_BASE_HH_
10 
11 
12 
13 #include <ostream>
14 #include <string>
15 
16 #include "fields/unit_si.hh"
17 
18 /**
19  * \brief Common parent class for templated OutputData.
20  *
21  * Provides virtual method for output of stored data.
22  *
23  */
25 public:
26 
27  /**
28  * Number of components of element data stored in the database.
29  */
31  N_SCALAR = 1,
32  N_VECTOR = 3,
34  };
35 
36  /**
37  * Destructor of OutputDataBase
38  */
39  virtual ~OutputDataBase() {};
40 
41  /**
42  * Print one value at given index
43  */
44  virtual void print(ostream &out_stream, unsigned int idx) = 0;
45 
46  /**
47  * Print all data at once stored in database
48  */
49  virtual void print_all(ostream &out_stream) = 0;
50 
51  /**
52  * Data copied from Field.
53  */
54  std::string output_field_name;
55  std::string field_name;
57 
58  /**
59  * Number of data values.
60  */
61  unsigned int n_values;
62 
63  /**
64  * Number of data elements per data value.
65  */
67 
68 };
69 
70 
71 
72 
73 #endif /* OUTPUT_DATA_BASE_HH_ */
Common parent class for templated OutputData.
std::string output_field_name
virtual ~OutputDataBase()
unsigned int n_values
NumCompValueType n_elem_
virtual void print_all(ostream &out_stream)=0
std::string field_name
Class for representation SI units of Fields.
Definition: unit_si.hh:31
virtual void print(ostream &out_stream, unsigned int idx)=0