LCOV - code coverage report
Current view: top level - src/controllogic - THMSolvePostprocessorControl.C (source / functions) Hit Total Coverage
Test: idaholab/moose thermal_hydraulics: #30301 (3b550b) with base 2ad78d Lines: 11 12 91.7 %
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 "THMSolvePostprocessorControl.h"
      11             : 
      12             : registerMooseObject("ThermalHydraulicsApp", THMSolvePostprocessorControl);
      13             : 
      14             : InputParameters
      15          36 : THMSolvePostprocessorControl::validParams()
      16             : {
      17          36 :   InputParameters params = THMControl::validParams();
      18          72 :   params.addRequiredParam<PostprocessorName>(
      19             :       "postprocessor", "The name of the postprocessot that indicates is a solve should be done.");
      20          36 :   params.addClassDescription("Control the solve based on a postprocessor value");
      21          36 :   return params;
      22           0 : }
      23             : 
      24          18 : THMSolvePostprocessorControl::THMSolvePostprocessorControl(const InputParameters & parameters)
      25          18 :   : THMControl(parameters), _solve_pps(getPostprocessorValue("postprocessor"))
      26             : {
      27          18 : }
      28             : 
      29             : void
      30          96 : THMSolvePostprocessorControl::execute()
      31             : {
      32         192 :   setControllableValueByName<bool>("Problem::" + _fe_problem.name(), "solve", _solve_pps != 0.);
      33          96 : }

Generated by: LCOV version 1.14