LCOV - code coverage report
Current view: top level - src/utils - VariableSampler.C (source / functions) Hit Total Coverage
Test: idaholab/salamander: 762d38 Lines: 8 8 100.0 %
Date: 2025-07-22 20:51:44 Functions: 2 2 100.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : //* This file is part of SALAMANDER: Software for Advanced Large-scale Analysis of MAgnetic confinement for Numerical Design, Engineering & Research,
       2             : //* A multiphysics application for modeling plasma facing components
       3             : //* https://github.com/idaholab/salamander
       4             : //* https://mooseframework.inl.gov/salamander
       5             : //*
       6             : //* SALAMANDER is powered by the MOOSE Framework
       7             : //* https://www.mooseframework.inl.gov
       8             : //*
       9             : //* Licensed under LGPL 2.1, please see LICENSE for details
      10             : //* https://www.gnu.org/licenses/lgpl-2.1.html
      11             : //*
      12             : //* Copyright 2025, Battelle Energy Alliance, LLC
      13             : //* ALL RIGHTS RESERVED
      14             : //*
      15             : 
      16             : #include "VariableSampler.h"
      17             : 
      18             : namespace SALAMANDER
      19             : {
      20         714 : VariableSampler::VariableSampler(FEProblemBase & problem,
      21             :                                  const VariableName & name,
      22         714 :                                  const THREAD_ID tid)
      23         714 :   : _system(problem.getSystem(name)),
      24         714 :     _var_num(
      25             :         problem
      26         714 :             .getVariable(
      27             :                 tid, name, Moose::VarKindType::VAR_ANY, Moose::VarFieldType::VAR_FIELD_STANDARD)
      28             :             .number())
      29             : {
      30         714 : }
      31             : 
      32             : Real
      33       21632 : VariableSampler::sampleVariable(const Point & point, const Elem * element) const
      34             : {
      35       21632 :   return _system.point_value(_var_num, point, element);
      36             : }
      37             : }

Generated by: LCOV version 1.14