Line data Source code
1 : //* This file is part of the MOOSE framework 2 : //* https://www.mooseframework.org 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 "LegacyDynamicTensorMechanicsAction.h" 11 : 12 : registerMooseAction("TensorMechanicsApp", 13 : LegacyDynamicTensorMechanicsAction, 14 : "setup_mesh_complete"); 15 : 16 : registerMooseAction("TensorMechanicsApp", 17 : LegacyDynamicTensorMechanicsAction, 18 : "validate_coordinate_systems"); 19 : 20 : registerMooseAction("TensorMechanicsApp", LegacyDynamicTensorMechanicsAction, "add_kernel"); 21 : 22 : InputParameters 23 102 : LegacyDynamicTensorMechanicsAction::validParams() 24 : { 25 102 : InputParameters params = DynamicTensorMechanicsAction::validParams(); 26 204 : params.addParam<bool>( 27 204 : "use_displaced_mesh", false, "Whether to use displaced mesh in the kernels"); 28 102 : return params; 29 0 : } 30 : 31 102 : LegacyDynamicTensorMechanicsAction::LegacyDynamicTensorMechanicsAction( 32 102 : const InputParameters & params) 33 102 : : DynamicTensorMechanicsAction(params) 34 : { 35 102 : } 36 : 37 : void 38 306 : LegacyDynamicTensorMechanicsAction::act() 39 : { 40 306 : if (_current_task == "add_kernel" || _current_task == "validate_coordinate_systems") 41 : // note that we do not call DynamicTensorMechanicsAction::act() here, because the old 42 : // behavior is not to add inertia kernels 43 204 : TensorMechanicsAction::act(); 44 306 : }