LCOV - code coverage report
Current view: top level - src/actions - AddMeshGeneratorAction.C (source / functions) Hit Total Coverage
Test: idaholab/moose framework: 419b9d Lines: 11 13 84.6 %
Date: 2025-08-08 20:01:16 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 "AddMeshGeneratorAction.h"
      11             : #include "MooseMesh.h"
      12             : #include "MeshGenerator.h"
      13             : #include "Factory.h"
      14             : #include "MooseApp.h"
      15             : 
      16             : registerMooseAction("MooseApp", AddMeshGeneratorAction, "add_mesh_generator");
      17             : 
      18             : InputParameters
      19       54438 : AddMeshGeneratorAction::validParams()
      20             : {
      21       54438 :   InputParameters params = MooseObjectAction::validParams();
      22       54438 :   params.addClassDescription("Add a MeshGenerator object to the simulation.");
      23       54438 :   return params;
      24           0 : }
      25             : 
      26       54181 : AddMeshGeneratorAction::AddMeshGeneratorAction(const InputParameters & params)
      27       54181 :   : MooseObjectAction(params)
      28             : {
      29       54181 : }
      30             : 
      31             : void
      32       54040 : AddMeshGeneratorAction::act()
      33             : {
      34       54040 :   if (!_mesh)
      35           0 :     mooseError("No mesh file was supplied and no generation block was provided");
      36             : 
      37       54040 :   _app.addMeshGenerator(_type, _name, _moose_object_pars);
      38       54040 : }

Generated by: LCOV version 1.14