BoundaryCorrection.hpp
1 // Distributed under the MIT License.
2 // See LICENSE.txt for details.
3 
4 #pragma once
5 
6 #include <cstddef>
7 #include <memory>
8 #include <pup.h>
9 
11 #include "Utilities/TMPL.hpp"
12 
13 /// Boundary corrections/numerical fluxes
15 /// \cond
16 template <size_t Dim>
17 class UpwindPenalty;
18 /// \endcond
19 
20 /*!
21  * \brief The base class used to make boundary corrections factory createable so
22  * they can be specified in the input file.
23  */
24 template <size_t Dim>
25 class BoundaryCorrection : public PUP::able {
26  public:
27  BoundaryCorrection() = default;
28  BoundaryCorrection(const BoundaryCorrection&) = default;
29  BoundaryCorrection& operator=(const BoundaryCorrection&) = default;
31  BoundaryCorrection& operator=(BoundaryCorrection&&) = default;
32  ~BoundaryCorrection() override = default;
33 
34  /// \cond
35  explicit BoundaryCorrection(CkMigrateMessage* msg) noexcept
36  : PUP::able(msg) {}
38  /// \endcond
39 
40  using creatable_classes = tmpl::list<UpwindPenalty<Dim>>;
41 
42  virtual std::unique_ptr<BoundaryCorrection<Dim>> get_clone()
43  const noexcept = 0;
44 };
45 } // namespace GeneralizedHarmonic::BoundaryCorrections
CharmPupable.hpp
GeneralizedHarmonic::BoundaryCorrections::BoundaryCorrection
The base class used to make boundary corrections factory createable so they can be specified in the i...
Definition: BoundaryCorrection.hpp:25
GeneralizedHarmonic::BoundaryCorrections
Boundary corrections/numerical fluxes.
Definition: BoundaryCorrection.hpp:14
cstddef
WRAPPED_PUPable_abstract
#define WRAPPED_PUPable_abstract(className)
Wraps the Charm++ macro, see the Charm++ documentation.
Definition: CharmPupable.hpp:41
memory
GeneralizedHarmonic::BoundaryCorrections::UpwindPenalty
Computes the generalized harmonic upwind multipenalty boundary correction.
Definition: UpwindPenalty.hpp:178
std::unique_ptr
TMPL.hpp