SpECTRE Documentation Coverage Report
Current view: top level - Evolution/Systems/ScalarTensor/BoundaryCorrections - BoundaryCorrection.hpp Hit Total Coverage
Commit: 965048f86d23c819715b3af1ca3f880c8145d4bb Lines: 2 11 18.2 %
Date: 2024-05-16 17:00:40
Legend: Lines: hit not hit

          Line data    Source code
       1           0 : // 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             : 
      10             : #include "Evolution/Systems/CurvedScalarWave/BoundaryCorrections/BoundaryCorrection.hpp"
      11             : #include "Evolution/Systems/GeneralizedHarmonic/BoundaryCorrections/BoundaryCorrection.hpp"
      12             : #include "Utilities/Gsl.hpp"
      13             : #include "Utilities/Serialization/CharmPupable.hpp"
      14             : #include "Utilities/TMPL.hpp"
      15             : 
      16             : /// Boundary corrections/numerical fluxes
      17           1 : namespace ScalarTensor::BoundaryCorrections {
      18             : /// \cond
      19             : template <typename DerivedGhCorrection, typename DerivedScalarCorrection>
      20             : class ProductOfCorrections;
      21             : /// \endcond
      22             : 
      23             : namespace detail {
      24             : 
      25             : template <typename GhList, typename ScalarList>
      26             : struct AllProductCorrections;
      27             : 
      28             : template <typename GhList, typename... ScalarCorrections>
      29             : struct AllProductCorrections<GhList, tmpl::list<ScalarCorrections...>> {
      30             :   using type = tmpl::flatten<tmpl::list<
      31             :       tmpl::transform<GhList, tmpl::bind<ProductOfCorrections, tmpl::_1,
      32             :                                          tmpl::pin<ScalarCorrections>>>...>>;
      33             : };
      34             : }  // namespace detail
      35             : 
      36             : /*!
      37             :  * \brief The base class used to make boundary corrections factory creatable so
      38             :  * they can be specified in the input file.
      39             :  */
      40           1 : class BoundaryCorrection : public PUP::able {
      41             :  public:
      42           0 :   BoundaryCorrection() = default;
      43           0 :   BoundaryCorrection(const BoundaryCorrection&) = default;
      44           0 :   BoundaryCorrection& operator=(const BoundaryCorrection&) = default;
      45           0 :   BoundaryCorrection(BoundaryCorrection&&) = default;
      46           0 :   BoundaryCorrection& operator=(BoundaryCorrection&&) = default;
      47           0 :   ~BoundaryCorrection() override = default;
      48             : 
      49             :   /// \cond
      50             :   explicit BoundaryCorrection(CkMigrateMessage* msg) : PUP::able(msg) {}
      51             :   WRAPPED_PUPable_abstract(BoundaryCorrection);  // NOLINT
      52             :   /// \endcond
      53             : 
      54           0 :   using creatable_classes = typename detail::AllProductCorrections<
      55             :       typename gh::BoundaryCorrections::BoundaryCorrection<
      56             :           3>::creatable_classes,
      57             :       typename CurvedScalarWave::BoundaryCorrections::BoundaryCorrection<
      58             :           3>::creatable_classes>::type;
      59             : 
      60           0 :   virtual std::unique_ptr<BoundaryCorrection> get_clone() const = 0;
      61             : };
      62             : }  // namespace ScalarTensor::BoundaryCorrections

Generated by: LCOV version 1.14