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 "NodalUserObject.h" 11 : #include "MooseVariableFE.h" 12 : #include "SubProblem.h" 13 : #include "MooseTypes.h" 14 : #include "Assembly.h" 15 : 16 : InputParameters 17 231633 : NodalUserObject::validParams() 18 : { 19 231633 : InputParameters params = UserObject::validParams(); 20 694899 : params.addParam<bool>("unique_node_execute", 21 463266 : false, 22 : "When false (default), block restricted objects will have the " 23 : "execute method called multiple times on a single node if the " 24 : "node lies on a interface between two subdomains."); 25 231633 : params += BlockRestrictable::validParams(); 26 231633 : params += BoundaryRestrictable::validParams(); 27 231633 : params += RandomInterface::validParams(); 28 231633 : return params; 29 0 : } 30 : 31 1762 : NodalUserObject::NodalUserObject(const InputParameters & parameters) 32 : : UserObject(parameters), 33 : BlockRestrictable(this), 34 : BoundaryRestrictable(this, blockIDs(), true), // true for applying to nodesets 35 : CoupleableMooseVariableDependencyIntermediateInterface(this, true), 36 : TransientInterface(this), 37 1758 : RandomInterface(parameters, _fe_problem, _tid, true), 38 3516 : _mesh(_subproblem.mesh()), 39 1758 : _qp(0), 40 1758 : _current_node(_assembly.node()), 41 3520 : _unique_node_execute(getParam<bool>("unique_node_execute")) 42 : { 43 1758 : } 44 : 45 : void 46 0 : NodalUserObject::subdomainSetup() 47 : { 48 0 : mooseError("NodalUserObjects do not execute subdomainSetup method, this function does nothing " 49 : "and should not be used."); 50 : }