|
|
|
boundaryPatch.HGo to the documentation of this file.00001 /*---------------------------------------------------------------------------*\ 00002 ========= | 00003 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox 00004 \\ / O peration | 00005 \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd. 00006 \\/ M anipulation | 00007 ------------------------------------------------------------------------------- 00008 License 00009 This file is part of OpenFOAM. 00010 00011 OpenFOAM is free software; you can redistribute it and/or modify it 00012 under the terms of the GNU General Public License as published by the 00013 Free Software Foundation; either version 2 of the License, or (at your 00014 option) any later version. 00015 00016 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT 00017 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 00018 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 00019 for more details. 00020 00021 You should have received a copy of the GNU General Public License 00022 along with OpenFOAM; if not, write to the Free Software Foundation, 00023 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00024 00025 Class 00026 Foam::boundaryPatch 00027 00028 Description 00029 Like polyPatch but without reference to mesh. patchIdentifier::index 00030 is not used. Used in boundaryMesh to hold data on patches. 00031 00032 SourceFiles 00033 boundaryPatch.C 00034 00035 \*---------------------------------------------------------------------------*/ 00036 00037 #ifndef boundaryPatch_H 00038 #define boundaryPatch_H 00039 00040 #include "patchIdentifier.H" 00041 #include "autoPtr.H" 00042 00043 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00044 00045 namespace Foam 00046 { 00047 00048 /*---------------------------------------------------------------------------*\ 00049 Class boundaryPatch Declaration 00050 \*---------------------------------------------------------------------------*/ 00051 00052 class boundaryPatch 00053 : 00054 public patchIdentifier 00055 { 00056 // Private data 00057 00058 label size_; 00059 label start_; 00060 00061 public: 00062 00063 // Constructors 00064 00065 //- Construct from components 00066 boundaryPatch 00067 ( 00068 const word& name, 00069 const label index, 00070 const label size, 00071 const label start, 00072 const word& physicalType = word::null 00073 ); 00074 00075 //- Construct from dictionary 00076 boundaryPatch 00077 ( 00078 const word& name, 00079 const dictionary& dict, 00080 const label index 00081 ); 00082 00083 //- Construct as copy 00084 boundaryPatch(const boundaryPatch&); 00085 00086 //- Construct as copy, resetting the index 00087 boundaryPatch(const boundaryPatch&, const label index); 00088 00089 //- Clone 00090 autoPtr<boundaryPatch> clone() const; 00091 00092 00093 // Destructor 00094 00095 ~boundaryPatch(); 00096 00097 00098 // Member Functions 00099 00100 label size() const 00101 { 00102 return size_; 00103 } 00104 00105 label& size() 00106 { 00107 return size_; 00108 } 00109 00110 label start() const 00111 { 00112 return start_; 00113 } 00114 00115 label& start() 00116 { 00117 return start_; 00118 } 00119 00120 00121 //- Write dictionary 00122 virtual void write(Ostream&) const; 00123 00124 00125 // Ostream Operator 00126 00127 friend Ostream& operator<<(Ostream&, const boundaryPatch&); 00128 }; 00129 00130 00131 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00132 00133 } // End namespace Foam 00134 00135 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00136 00137 #endif 00138 00139 // ************************************************************************* // |