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 : #ifdef MOOSE_MFEM_ENABLED 11 : 12 : #include "MFEMAuxKernel.h" 13 : #include "MFEMProblem.h" 14 : 15 : InputParameters 16 26030 : MFEMAuxKernel::validParams() 17 : { 18 26030 : InputParameters params = MFEMGeneralUserObject::validParams(); 19 26030 : params.registerBase("AuxKernel"); 20 26030 : params.addClassDescription("Base class for MFEMGeneralUserObjects that update auxiliary " 21 : "variables outside of the main solve step."); 22 26030 : params.addRequiredParam<AuxVariableName>("variable", 23 : "The name of the variable that this object applies to"); 24 26030 : return params; 25 0 : } 26 : 27 70 : MFEMAuxKernel::MFEMAuxKernel(const InputParameters & parameters) 28 : : MFEMGeneralUserObject(parameters), 29 70 : _result_var_name(getParam<AuxVariableName>("variable")), 30 140 : _result_var(*getMFEMProblem().getProblemData().gridfunctions.Get(_result_var_name)) 31 : { 32 70 : _result_var = 0.0; 33 70 : } 34 : 35 : #endif