LCOV - code coverage report
Current view: top level - src/controllogic - SetBoolValueControl.C (source / functions) Hit Total Coverage
Test: idaholab/moose thermal_hydraulics: #30301 (3b550b) with base 2ad78d Lines: 12 13 92.3 %
Date: 2025-07-30 13:02:48 Functions: 3 3 100.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : //* This file is part of the MOOSE framework
       2             : //* https://mooseframework.inl.gov
       3             : //*
       4             : //* All rights reserved, see COPYRIGHT for full restrictions
       5             : //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
       6             : //*
       7             : //* Licensed under LGPL 2.1, please see LICENSE for details
       8             : //* https://www.gnu.org/licenses/lgpl-2.1.html
       9             : 
      10             : #include "SetBoolValueControl.h"
      11             : 
      12             : registerMooseObject("ThermalHydraulicsApp", SetBoolValueControl);
      13             : 
      14             : InputParameters
      15          36 : SetBoolValueControl::validParams()
      16             : {
      17          36 :   InputParameters params = THMControl::validParams();
      18          72 :   params.addRequiredParam<std::string>("parameter", "The input parameter(s) to control");
      19          72 :   params.addRequiredParam<std::string>(
      20             :       "value", "The name of control data to be set into the input parameter.");
      21          36 :   params.addClassDescription("Control object that reads a boolean value computed by the control "
      22             :                              "logic system and sets it into a specified MOOSE object parameter(s)");
      23          36 :   return params;
      24           0 : }
      25             : 
      26          18 : SetBoolValueControl::SetBoolValueControl(const InputParameters & parameters)
      27          18 :   : THMControl(parameters), _value(getControlData<bool>("value"))
      28             : {
      29          18 : }
      30             : 
      31             : void
      32         148 : SetBoolValueControl::execute()
      33             : {
      34         148 :   setControllableValue<bool>("parameter", _value);
      35         148 : }

Generated by: LCOV version 1.14