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 "GeometricSearchInterface.h" 11 : 12 : // MOOSE includes 13 : #include "GeometricSearchData.h" 14 : #include "MooseObject.h" 15 : #include "NearestNodeLocator.h" 16 : #include "PenetrationLocator.h" 17 : #include "SubProblem.h" 18 : #include "SystemBase.h" 19 : 20 : InputParameters 21 59638 : GeometricSearchInterface::validParams() 22 : { 23 59638 : return emptyInputParameters(); 24 : } 25 : 26 302873 : GeometricSearchInterface::GeometricSearchInterface(const MooseObject * moose_object) 27 302873 : : _geometric_search_data(moose_object->parameters() 28 908619 : .getCheckedPointerParam<SubProblem *>("_subproblem") 29 302873 : ->geomSearchData()), 30 302873 : _requires_geometric_search(false) 31 : { 32 302873 : } 33 : 34 : #ifdef MOOSE_KOKKOS_ENABLED 35 36803 : GeometricSearchInterface::GeometricSearchInterface(const GeometricSearchInterface & object, 36 36803 : const Moose::Kokkos::FunctorCopy &) 37 36803 : : _geometric_search_data(object._geometric_search_data), 38 36803 : _requires_geometric_search(object._requires_geometric_search) 39 : { 40 36803 : } 41 : #endif 42 : 43 : PenetrationLocator & 44 13563 : GeometricSearchInterface::getPenetrationLocator(const BoundaryName & primary, 45 : const BoundaryName & secondary, 46 : Order order) 47 : { 48 13563 : _requires_geometric_search = true; 49 13563 : return _geometric_search_data.getPenetrationLocator(primary, secondary, order); 50 : } 51 : 52 : PenetrationLocator & 53 129 : GeometricSearchInterface::getQuadraturePenetrationLocator(const BoundaryName & primary, 54 : const BoundaryName & secondary, 55 : Order order) 56 : { 57 129 : _requires_geometric_search = true; 58 129 : return _geometric_search_data.getQuadraturePenetrationLocator(primary, secondary, order); 59 : } 60 : 61 : NearestNodeLocator & 62 84 : GeometricSearchInterface::getNearestNodeLocator(const BoundaryName & primary, 63 : const BoundaryName & secondary) 64 : { 65 84 : _requires_geometric_search = true; 66 84 : return _geometric_search_data.getNearestNodeLocator(primary, secondary); 67 : } 68 : 69 : NearestNodeLocator & 70 28 : GeometricSearchInterface::getQuadratureNearestNodeLocator(const BoundaryName & primary, 71 : const BoundaryName & secondary) 72 : { 73 28 : _requires_geometric_search = true; 74 28 : return _geometric_search_data.getQuadratureNearestNodeLocator(primary, secondary); 75 : }