initial commit for version 1.6.x patch release
[OpenFOAM-1.6.x.git] / src / finiteVolume / fields / fvsPatchFields / constraint / wedge / wedgeFvsPatchField.C
blob132f37f6a37cc9a7a2be891f64ff8e35bb85fa85
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 1991-2009 OpenCFD Ltd.
6      \\/     M anipulation  |
7 -------------------------------------------------------------------------------
8 License
9     This file is part of OpenFOAM.
11     OpenFOAM is free software; you can redistribute it and/or modify it
12     under the terms of the GNU General Public License as published by the
13     Free Software Foundation; either version 2 of the License, or (at your
14     option) any later version.
16     OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17     ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18     FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
19     for more details.
21     You should have received a copy of the GNU General Public License
22     along with OpenFOAM; if not, write to the Free Software Foundation,
23     Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25 \*---------------------------------------------------------------------------*/
27 #include "wedgeFvsPatchField.H"
29 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
31 namespace Foam
34 // * * * * * * * * * * * * * * * * Constructors  * * * * * * * * * * * * * * //
36 template<class Type>
37 wedgeFvsPatchField<Type>::wedgeFvsPatchField
39     const fvPatch& p,
40     const DimensionedField<Type, surfaceMesh>& iF
43     fvsPatchField<Type>(p, iF)
47 template<class Type>
48 wedgeFvsPatchField<Type>::wedgeFvsPatchField
50     const wedgeFvsPatchField<Type>& ptf,
51     const fvPatch& p,
52     const DimensionedField<Type, surfaceMesh>& iF,
53     const fvPatchFieldMapper& mapper
56     fvsPatchField<Type>(ptf, p, iF, mapper)
58     if (!isType<wedgeFvPatch>(this->patch()))
59     {
60         FatalErrorIn
61         (
62             "wedgeFvsPatchField<Type>::wedgeFvsPatchField\n"
63             "(\n"
64             "    const wedgeFvsPatchField<Type>& ptf,\n"
65             "    const fvPatch& p,\n"
66             "    const DimensionedField<Type, surfaceMesh>& iF,\n"
67             "    const fvPatchFieldMapper& mapper\n"
68             ")\n"
69         )   << "Field type does not correspond to patch type for patch "
70             << this->patch().index() << "." << endl
71             << "Field type: " << typeName << endl
72             << "Patch type: " << this->patch().type()
73             << exit(FatalError);
74     }
78 template<class Type>
79 wedgeFvsPatchField<Type>::wedgeFvsPatchField
81     const fvPatch& p,
82     const DimensionedField<Type, surfaceMesh>& iF,
83     const dictionary& dict
86     fvsPatchField<Type>(p, iF, dict)
88     if (!isType<wedgeFvPatch>(p))
89     {
90         FatalIOErrorIn
91         (
92             "wedgeFvsPatchField<Type>::wedgeFvsPatchField\n"
93             "(\n"
94             "    const fvPatch& p,\n"
95             "    const Field<Type>& field,\n"
96             "    dictionary& dict\n"
97             ")\n",
98             dict
99         )   << "patch " << this->patch().index() << " not wedge type. "
100             << "Patch type = " << p.type()
101             << exit(FatalIOError);
102     }
106 template<class Type>
107 wedgeFvsPatchField<Type>::wedgeFvsPatchField
109     const wedgeFvsPatchField<Type>& ptf
112     fvsPatchField<Type>(ptf)
116 template<class Type>
117 wedgeFvsPatchField<Type>::wedgeFvsPatchField
119     const wedgeFvsPatchField<Type>& ptf,
120     const DimensionedField<Type, surfaceMesh>& iF
123     fvsPatchField<Type>(ptf, iF)
127 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
129 } // End namespace Foam
131 // ************************************************************************* //