Quinoa all test code coverage report
Current view: top level - Control/Inciter/Options - Flux.hpp (source / functions) Hit Total Coverage
Commit: -128-NOTFOUND Lines: 4 4 100.0 %
Date: 2024-04-29 14:42:33 Functions: 1 1 100.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 9 22 40.9 %

           Branch data     Line data    Source code
       1                 :            : // *****************************************************************************
       2                 :            : /*!
       3                 :            :   \file      src/Control/Inciter/Options/Flux.hpp
       4                 :            :   \copyright 2012-2015 J. Bakosi,
       5                 :            :              2016-2018 Los Alamos National Security, LLC.,
       6                 :            :              2019-2021 Triad National Security, LLC.
       7                 :            :              All rights reserved. See the LICENSE file for details.
       8                 :            :   \brief     Flux function options for inciter
       9                 :            :   \details   Flux function options for inciter
      10                 :            : */
      11                 :            : // *****************************************************************************
      12                 :            : #ifndef FluxOptions_h
      13                 :            : #define FluxOptions_h
      14                 :            : 
      15                 :            : #include <brigand/sequences/list.hpp>
      16                 :            : 
      17                 :            : #include "Toggle.hpp"
      18                 :            : #include "PUPUtil.hpp"
      19                 :            : 
      20                 :            : namespace inciter {
      21                 :            : namespace ctr {
      22                 :            : 
      23                 :            : //! Flux types
      24                 :            : enum class FluxType : uint8_t { LaxFriedrichs
      25                 :            :                               , HLLC
      26                 :            :                               , UPWIND
      27                 :            :                               , AUSM
      28                 :            :                               , HLL
      29                 :            :                               , Rusanov
      30                 :            :                               };
      31                 :            : 
      32                 :            : //! Pack/Unpack FluxType: forward overload to generic enum class packer
      33                 :            : inline void operator|( PUP::er& p, FluxType& e ) { PUP::pup( p, e ); }
      34                 :            : 
      35                 :            : //! \brief Flux options: outsource to base templated on enum type
      36                 :        263 : class Flux : public tk::Toggle< FluxType > {
      37                 :            : 
      38                 :            :   public:
      39                 :            :     //! \brief Options constructor
      40                 :            :     //! \details Simply initialize in-line and pass associations to base, which
      41                 :            :     //!    will handle client interactions
      42                 :        263 :     explicit Flux() :
      43                 :            :       tk::Toggle< FluxType >(
      44                 :            :         //! Group, i.e., options, name
      45                 :            :         "Flux",
      46                 :            :         //! Enums -> names (if defined, policy codes, if not, name)
      47                 :            :         { { FluxType::LaxFriedrichs, "laxfriedrichs" }
      48                 :            :         , { FluxType::HLLC, "hllc" }
      49                 :            :         , { FluxType::UPWIND, "upwind" }
      50                 :            :         , { FluxType::AUSM, "ausm" }
      51                 :            :         , { FluxType::HLL, "hll" }
      52                 :            :         },
      53                 :            :         //! keywords -> Enums
      54                 :            :         { { "laxfriedrichs", FluxType::LaxFriedrichs }
      55                 :            :         , { "hllc", FluxType::HLLC }
      56                 :            :         , { "upwind", FluxType::UPWIND }
      57                 :            :         , { "ausm", FluxType::AUSM }
      58                 :            :         , { "hll", FluxType::HLL }
      59 [ +  - ][ +  - ]:       3682 :         } )
         [ +  - ][ +  + ]
         [ -  + ][ +  + ]
         [ -  + ][ -  - ]
         [ -  - ][ -  - ]
                 [ -  - ]
      60                 :        263 :     {}
      61                 :            : 
      62                 :            : };
      63                 :            : 
      64                 :            : } // ctr::
      65                 :            : } // inciter::
      66                 :            : 
      67                 :            : #endif // FluxOptions_h

Generated by: LCOV version 1.14