LCOV - code coverage report
Current view: top level - src/userobjects - CutElementSubdomainModifier.C (source / functions) Hit Total Coverage
Test: idaholab/moose xfem: #31405 (292dce) with base fef103 Lines: 10 11 90.9 %
Date: 2025-09-04 07:58:55 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 "CutElementSubdomainModifier.h"
      11             : 
      12             : registerMooseObject("XFEMApp", CutElementSubdomainModifier);
      13             : 
      14             : InputParameters
      15           8 : CutElementSubdomainModifier::validParams()
      16             : {
      17           8 :   InputParameters params = ElementSubdomainModifier::validParams();
      18           8 :   params.addClassDescription("Change element subdomain based on CutSubdomainID");
      19          16 :   params.addRequiredParam<UserObjectName>(
      20             :       "geometric_cut_userobject", "The geometric cut userobject that assigns the CutSubdomainID");
      21           8 :   return params;
      22           0 : }
      23             : 
      24           4 : CutElementSubdomainModifier::CutElementSubdomainModifier(const InputParameters & parameters)
      25             :   : ElementSubdomainModifier(parameters),
      26           4 :     _cut(&getUserObject<GeometricCutUserObject>("geometric_cut_userobject"))
      27             : {
      28           4 : }
      29             : 
      30             : SubdomainID
      31        1320 : CutElementSubdomainModifier::computeSubdomainID()
      32             : {
      33        1320 :   return _cut->getCutSubdomainID(_current_elem);
      34             : }

Generated by: LCOV version 1.14