SpECTRE Documentation Coverage Report
Current view: top level - ParallelAlgorithms/Amr/Criteria/Tags - Criteria.hpp Hit Total Coverage
Commit: b5f497991094937944b0a3f519166bb54739d08a Lines: 4 12 33.3 %
Date: 2024-03-28 18:20:13
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 <memory>
       7             : #include <unordered_set>
       8             : #include <vector>
       9             : 
      10             : #include "DataStructures/DataBox/Tag.hpp"
      11             : #include "Options/String.hpp"
      12             : #include "ParallelAlgorithms/Amr/Criteria/Criterion.hpp"
      13             : #include "ParallelAlgorithms/Amr/Tags.hpp"
      14             : #include "Utilities/Serialization/Serialize.hpp"
      15             : #include "Utilities/TMPL.hpp"
      16             : 
      17             : namespace amr::Criteria {
      18             : /// Option tags for AMR criteria
      19           1 : namespace OptionTags {
      20             : /// \ingroup OptionTagsGroup
      21             : /// Options for AMR criteria
      22           1 : struct Criteria {
      23           0 :   static constexpr Options::String help = "Options for AMR criteria";
      24           0 :   using type = std::vector<std::unique_ptr<amr::Criterion>>;
      25           0 :   using group = amr::OptionTags::AmrGroup;
      26             : };
      27             : }  // namespace OptionTags
      28             : 
      29           1 : namespace Tags {
      30             : /// The set of adaptive mesh refinement criteria
      31           1 : struct Criteria : db::SimpleTag {
      32           0 :   using type = std::vector<std::unique_ptr<amr::Criterion>>;
      33           0 :   using option_tags = tmpl::list<amr::Criteria::OptionTags::Criteria>;
      34             : 
      35           0 :   static constexpr bool pass_metavariables = false;
      36           0 :   static type create_from_options(const type& value) {
      37             :     return {deserialize<type>(serialize<type>(value).data())};
      38             :   }
      39             : };
      40             : }  // namespace Tags
      41             : }  // namespace amr::Criteria

Generated by: LCOV version 1.14