SpECTRE Documentation Coverage Report
Current view: top level - DataStructures/DataBox - SubitemTag.hpp Hit Total Coverage
Commit: 3f09028930c0450a2fb61ee918b22882f5d03d2b Lines: 1 6 16.7 %
Date: 2021-10-22 20:52:16
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 "DataStructures/DataBox/Subitems.hpp"
       7             : #include "DataStructures/DataBox/Tag.hpp"
       8             : #include "Utilities/TMPL.hpp"
       9             : 
      10             : namespace Tags {
      11             : 
      12             : /// \cond
      13             : // Declaration of a tag for a subitem
      14             : // Unless specialized, it will be the reference tag below,
      15             : template <typename Tag, typename ParentTag, typename = std::nullptr_t>
      16             : struct Subitem;
      17             : /// \endcond
      18             : 
      19             : /// \brief a reference tag that refers to a particular Tag that is a subitem of
      20             : /// an item tagged with ParentTag
      21             : template <typename Tag, typename ParentTag, typename>
      22           1 : struct Subitem : Tag, db::ReferenceTag {
      23           0 :   using base = Tag;
      24           0 :   using parent_tag = ParentTag;
      25           0 :   static const auto& get(const typename parent_tag::type& parent_value) {
      26             :     return ::db::Subitems<parent_tag>::template create_compute_item<base>(
      27             :         parent_value);
      28             :   }
      29           0 :   using argument_tags = tmpl::list<parent_tag>;
      30             : };
      31             : }  // namespace Tags

Generated by: LCOV version 1.14