Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #include "genericPolyPatch.H"
00027 #include <OpenFOAM/addToRunTimeSelectionTable.H>
00028
00029
00030
00031 namespace Foam
00032 {
00033 defineTypeNameAndDebug(genericPolyPatch, 0);
00034
00035 addToRunTimeSelectionTable(polyPatch, genericPolyPatch, word);
00036 addToRunTimeSelectionTable(polyPatch, genericPolyPatch, dictionary);
00037 }
00038
00039
00040
00041
00042 Foam::genericPolyPatch::genericPolyPatch
00043 (
00044 const word& name,
00045 const label size,
00046 const label start,
00047 const label index,
00048 const polyBoundaryMesh& bm
00049 )
00050 :
00051 polyPatch(name, size, start, index, bm)
00052 {}
00053
00054
00055 Foam::genericPolyPatch::genericPolyPatch
00056 (
00057 const word& name,
00058 const dictionary& dict,
00059 const label index,
00060 const polyBoundaryMesh& bm
00061 )
00062 :
00063 polyPatch(name, dict, index, bm),
00064 actualTypeName_(dict.lookup("type")),
00065 dict_(dict)
00066 {}
00067
00068
00069 Foam::genericPolyPatch::genericPolyPatch
00070 (
00071 const genericPolyPatch& pp,
00072 const polyBoundaryMesh& bm
00073 )
00074 :
00075 polyPatch(pp, bm),
00076 actualTypeName_(pp.actualTypeName_),
00077 dict_(pp.dict_)
00078 {}
00079
00080
00081 Foam::genericPolyPatch::genericPolyPatch
00082 (
00083 const genericPolyPatch& pp,
00084 const polyBoundaryMesh& bm,
00085 const label index,
00086 const label newSize,
00087 const label newStart
00088 )
00089 :
00090 polyPatch(pp, bm, index, newSize, newStart),
00091 actualTypeName_(pp.actualTypeName_),
00092 dict_(pp.dict_)
00093 {}
00094
00095
00096
00097
00098 Foam::genericPolyPatch::~genericPolyPatch()
00099 {}
00100
00101
00102
00103
00104 void Foam::genericPolyPatch::write(Ostream& os) const
00105 {
00106 os.writeKeyword("type") << actualTypeName_ << token::END_STATEMENT << nl;
00107 patchIdentifier::write(os);
00108 os.writeKeyword("nFaces") << size() << token::END_STATEMENT << nl;
00109 os.writeKeyword("startFace") << start() << token::END_STATEMENT << nl;
00110
00111 for
00112 (
00113 dictionary::const_iterator iter = dict_.begin();
00114 iter != dict_.end();
00115 ++iter
00116 )
00117 {
00118 if
00119 (
00120 iter().keyword() != "type"
00121 && iter().keyword() != "nFaces"
00122 && iter().keyword() != "startFace"
00123 )
00124 {
00125 iter().write(os);
00126 }
00127 }
00128 }
00129
00130
00131