LCOV - code coverage report
Current view: top level - src/bcs - PostprocessorDirichletBC.C (source / functions) Hit Total Coverage
Test: idaholab/moose framework: 2bf808 Lines: 10 11 90.9 %
Date: 2025-07-17 01:28:37 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 "PostprocessorDirichletBC.h"
      11             : 
      12             : registerMooseObject("MooseApp", PostprocessorDirichletBC);
      13             : 
      14             : // Used by MOOSEDocs: syntax/Postprocessors/index.md
      15             : InputParameters
      16       17729 : PostprocessorDirichletBC::validParams()
      17             : {
      18       17729 :   InputParameters params = NodalBC::validParams();
      19       17729 :   params.addClassDescription(
      20             :       "Dirichlet boundary condition with value prescribed by a Postprocessor value.");
      21       17729 :   params.addRequiredParam<PostprocessorName>(
      22             :       "postprocessor", "The postprocessor to set the value to on the boundary.");
      23       17729 :   return params;
      24           0 : }
      25             : 
      26        1728 : PostprocessorDirichletBC::PostprocessorDirichletBC(const InputParameters & parameters)
      27        1728 :   : NodalBC(parameters), _postprocessor_value(getPostprocessorValue("postprocessor"))
      28             : {
      29        1728 : }
      30             : 
      31             : Real
      32     4409155 : PostprocessorDirichletBC::computeQpResidual()
      33             : {
      34     4409155 :   return _u[_qp] - _postprocessor_value;
      35             : }

Generated by: LCOV version 1.14