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 : #pragma once 11 : 12 : #include "BoundaryBase.h" 13 : #include "Component2D.h" 14 : 15 : /** 16 : * Base class for heat structure boundary components 17 : */ 18 0 : class HSBoundary : public BoundaryBase 19 : { 20 : public: 21 : HSBoundary(const InputParameters & params); 22 : 23 : virtual void check() const override; 24 : 25 : protected: 26 : /** 27 : * Returns true if all of the boundaries are external. 28 : * 29 : * This method should only be called if the heat structure is known to be 2D. 30 : */ 31 : bool allComponent2DBoundariesAreExternal() const; 32 : 33 : /** 34 : * Logs an error if any boundary is not external. 35 : * 36 : * This method should only be called if the heat structure is known to be 2D. 37 : */ 38 : void checkAllComponent2DBoundariesAreExternal() const; 39 : 40 : /** 41 : * Returns true if all of the boundaries have the same external boundary type. 42 : * 43 : * This method should only be called if the heat structure is known to be 2D. 44 : */ 45 : bool hasCommonComponent2DExternalBoundaryType() const; 46 : 47 : /** 48 : * Gets the common external boundary type. 49 : * 50 : * This method should only be called if the heat structure is known to be 2D, 51 : * and it is known that there is a common type. 52 : */ 53 : Component2D::ExternalBoundaryType getCommonComponent2DExternalBoundaryType() const; 54 : 55 : /// Boundary names for which the boundary component applies 56 : const std::vector<BoundaryName> & _boundary; 57 : 58 : /// Heat structure name 59 : const std::string & _hs_name; 60 : 61 : public: 62 : static InputParameters validParams(); 63 : };