31 const word& patchFieldType,
32 const word& actualPatchType,
40 <<
"patchFieldType = " << patchFieldType
41 <<
", actualPatchType = " << actualPatchType
42 <<
", patchType = " << p.type()
46 typename patchConstructorTable::iterator cstrIter =
47 patchConstructorTablePtr_->find(patchFieldType);
49 if (cstrIter == patchConstructorTablePtr_->end())
52 <<
"Unknown patchField type " 53 << patchFieldType <<
nl <<
nl 54 <<
"Valid patchField types are :" <<
endl 55 << patchConstructorTablePtr_->sortedToc()
61 actualPatchType == word::null
62 || actualPatchType != p.type()
65 typename patchConstructorTable::iterator patchTypeCstrIter =
66 patchConstructorTablePtr_->find(p.type());
68 if (patchTypeCstrIter != patchConstructorTablePtr_->end())
70 return patchTypeCstrIter()(
p, iF);
74 return cstrIter()(
p, iF);
79 return cstrIter()(
p, iF);
87 const word& patchFieldType,
92 return New(patchFieldType, word::null, p, iF);
109 <<
"patchFieldType = " << patchFieldType
110 <<
", actualPatchType = " 112 <<
", patchType = " << p.type()
116 typename dictionaryConstructorTable::iterator cstrIter
117 = dictionaryConstructorTablePtr_->find(patchFieldType);
119 if (cstrIter == dictionaryConstructorTablePtr_->end())
121 if (!disallowGenericFvsPatchField)
123 cstrIter = dictionaryConstructorTablePtr_->find(
"generic");
126 if (cstrIter == dictionaryConstructorTablePtr_->end())
131 ) <<
"Unknown patchField type " << patchFieldType
132 <<
" for patch type " << p.type() <<
nl <<
nl 133 <<
"Valid patchField types are :" <<
endl 134 << dictionaryConstructorTablePtr_->sortedToc()
141 !dict.
found(
"patchType")
145 typename dictionaryConstructorTable::iterator patchTypeCstrIter
146 = dictionaryConstructorTablePtr_->find(p.type());
150 patchTypeCstrIter != dictionaryConstructorTablePtr_->end()
151 && patchTypeCstrIter() != cstrIter()
157 ) <<
"inconsistent patch and patchField types for \n" 158 " patch type " << p.type()
159 <<
" and patchField type " << patchFieldType
164 return cstrIter()(
p, iF,
dict);
182 typename patchMapperConstructorTable::iterator cstrIter =
183 patchMapperConstructorTablePtr_->find(ptf.type());
185 if (cstrIter == patchMapperConstructorTablePtr_->end())
188 <<
"Unknown patchField type " << ptf.type() <<
nl <<
nl 189 <<
"Valid patchField types are :" <<
endl 190 << patchMapperConstructorTablePtr_->sortedToc()
194 return cstrIter()(ptf,
p, iF, pfMapper);
bool found(const word &, bool recursive=false, bool patternMatch=true) const
Search dictionary for given keyword.
errorManipArg< error, int > exit(error &err, const int errNo=1)
A list of keyword definitions, which are a keyword followed by any number of values (e...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
Ostream & endl(Ostream &os)
Add newline and flush stream.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
static tmp< fvsPatchField< Type > > New(const word &, const fvPatch &, const DimensionedField< Type, surfaceMesh > &)
Return a pointer to a new patchField created on freestore given.
autoPtr< BasicCompressibleMomentumTransportModel > New(const volScalarField &rho, const volVectorField &U, const surfaceScalarField &phi, const typename BasicCompressibleMomentumTransportModel::transportModel &transport)
A class for handling words, derived from string.
Foam::fvPatchFieldMapper.
T lookupOrDefault(const word &, const T &, bool recursive=false, bool patternMatch=true) const
Find and return a T,.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
A class for managing temporary objects.
word patchFieldType(const PatchField &pf)
An abstract base class with a fat-interface to all derived classes covering all possible ways in whic...
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
#define InfoInFunction
Report an information message using Foam::Info.