Code_TYMPAN  4.4.0
Industrial site acoustic simulation
data_model_common.hpp
Go to the documentation of this file.
1 /*
2  * Copyright (C) <2012-2024> <EDF-DTG> <FRANCE>
3  * This file is part of Code_TYMPAN (R).
4  * Code_TYMPAN (R) is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation, either version 3 of the License, or
7  * (at your option) any later version.
8  * Code_TYMPAN (R) is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
11  * See the GNU General Public License for more details.
12  * You should have received a copy of the GNU General Public License along
13  * with Code_TYMPAN (R). If not, see <https://www.gnu.org/licenses/>.
14  */
15 
24 #ifndef TYMPAN__DATA_MODEL_COMMON_HPP__INCLUDED
25 #define TYMPAN__DATA_MODEL_COMMON_HPP__INCLUDED
26 
27 #include "std_boost_utils.hpp"
28 
31 
32 // This section import some types from CommonTools
33 // under a more generic name into the tympan namespace. Indeed,
34 // there must be no dependency to TY-classes and no direct
35 // ones to O-classes from within the solver data model.
36 namespace tympan
37 {
38 typedef OPoint3D Point;
39 typedef OVector3D Vector;
40 typedef OSpectre Spectrum;
42 
43 typedef std::deque<Point> nodes_pool_t;
44 typedef size_t node_idx;
45 } // namespace tympan
46 
47 namespace tympan
48 {
49 
57 {
58 protected:
59  BaseEntity(){};
60 
61 public:
62  virtual ~BaseEntity(){};
63 
64  // virtual tympan::shared_ptr<BaseEntity> ptr_any() = 0;
65  // virtual tympan::shared_ptr<BaseEntity const> ptr_any() const = 0;
66  //
67  // template <class T>
68  // tympan::shared_ptr<T> ptr()
69  // { return boost::dynamic_pointer_cast<T>(ptr_any()); }
70  //
71  // template <class T>
72  // tympan::shared_ptr<T const> ptr() const
73  // { return boost::dynamic_pointer_cast<T const>(ptr_any()); }
74 };
75 
76 } /* namespace tympan */
77 
78 #endif /* TYMPAN__DATA_MODEL_COMMON_HPP__INCLUDED */
All base classes related to 3D manipulation.
The 3D point class.
Definition: 3d.h:487
The 3D vector class.
Definition: 3d.h:298
The base of all entity classes.
virtual ~BaseEntity()
Constructor.
OSpectreComplex ComplexSpectrum
OSpectre Spectrum
OPoint3D Point
std::deque< Point > nodes_pool_t
OVector3D Vector
size_t node_idx
Misc utilities used by SolverDataModel.