COMP: remove regExp dependency from polyBoundaryMesh

This commit is contained in:
Mark Olesen
2011-02-18 17:52:42 +01:00
parent cae015b615
commit fe9fc5e51d
6 changed files with 24 additions and 12 deletions

View File

@ -2,7 +2,7 @@
========= | ========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | \\ / O peration |
\\ / A nd | Copyright (C) 2004-2010 OpenCFD Ltd. \\ / A nd | Copyright (C) 2004-2011 OpenCFD Ltd.
\\/ M anipulation | \\/ M anipulation |
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
License License
@ -45,6 +45,7 @@ Description
#include "IOPtrList.H" #include "IOPtrList.H"
#include "polyTopoChange.H" #include "polyTopoChange.H"
#include "polyModifyFace.H" #include "polyModifyFace.H"
#include "wordReList.H"
using namespace Foam; using namespace Foam;
@ -669,7 +670,13 @@ int main(int argc, char *argv[])
if (sourceType == "patches") if (sourceType == "patches")
{ {
labelHashSet patchSources(patches.patchSet(dict.lookup("patches"))); labelHashSet patchSources
(
patches.patchSet
(
wordReList(dict.lookup("patches"))
)
);
// Repatch faces of the patches. // Repatch faces of the patches.
forAllConstIter(labelHashSet, patchSources, iter) forAllConstIter(labelHashSet, patchSources, iter)

View File

@ -18,7 +18,6 @@ LINK_DIRECTORIES(
) )
INCLUDE_DIRECTORIES( INCLUDE_DIRECTORIES(
$ENV{WM_PROJECT_DIR}/src/OSspecific/$ENV{WM_OSTYPE}/lnInclude
$ENV{WM_PROJECT_DIR}/src/OpenFOAM/lnInclude $ENV{WM_PROJECT_DIR}/src/OpenFOAM/lnInclude
$ENV{WM_PROJECT_DIR}/src/finiteVolume/lnInclude $ENV{WM_PROJECT_DIR}/src/finiteVolume/lnInclude
${PROJECT_SOURCE_DIR}/../vtkPV3Foam ${PROJECT_SOURCE_DIR}/../vtkPV3Foam

View File

@ -550,7 +550,7 @@ Foam::label Foam::polyBoundaryMesh::whichPatch(const label faceIndex) const
Foam::labelHashSet Foam::polyBoundaryMesh::patchSet Foam::labelHashSet Foam::polyBoundaryMesh::patchSet
( (
const wordReList& patchNames, const UList<wordRe>& patchNames,
const bool warnNotFound const bool warnNotFound
) const ) const
{ {

View File

@ -38,7 +38,6 @@ SourceFiles
#include "polyPatchList.H" #include "polyPatchList.H"
#include "regIOobject.H" #include "regIOobject.H"
#include "labelPair.H" #include "labelPair.H"
#include "wordReList.H"
#include "HashSet.H" #include "HashSet.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -46,7 +45,9 @@ SourceFiles
namespace Foam namespace Foam
{ {
// Forward declaration of classes
class polyMesh; class polyMesh;
class wordRe;
// Forward declaration of friend functions and operators // Forward declaration of friend functions and operators
@ -171,7 +172,7 @@ public:
// By default warns if given names are not found. // By default warns if given names are not found.
labelHashSet patchSet labelHashSet patchSet
( (
const wordReList& patchNames, const UList<wordRe>& patchNames,
const bool warnNotFound = true const bool warnNotFound = true
) const; ) const;

View File

@ -24,16 +24,14 @@ License
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#include "nearWallFields.H" #include "nearWallFields.H"
#include "wordReList.H"
//#include "volFields.H" //#include "volFields.H"
//#include "selfContainedDirectMappedFixedValueFvPatchFields.H" //#include "selfContainedDirectMappedFixedValueFvPatchFields.H"
//#include "interpolationCellPoint.H" //#include "interpolationCellPoint.H"
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * // // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
namespace Foam defineTypeNameAndDebug(Foam::nearWallFields, 0);
{
defineTypeNameAndDebug(nearWallFields, 0);
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
@ -87,7 +85,10 @@ void Foam::nearWallFields::read(const dictionary& dict)
const fvMesh& mesh = refCast<const fvMesh>(obr_); const fvMesh& mesh = refCast<const fvMesh>(obr_);
dict.lookup("fields") >> fieldSet_; dict.lookup("fields") >> fieldSet_;
patchSet_ = mesh.boundaryMesh().patchSet(dict.lookup("patches")); patchSet_ = mesh.boundaryMesh().patchSet
(
wordReList(dict.lookup("patches"))
);
distance_ = readScalar(dict.lookup("distance")); distance_ = readScalar(dict.lookup("distance"));

View File

@ -27,6 +27,7 @@ License
#include "volFields.H" #include "volFields.H"
#include "dictionary.H" #include "dictionary.H"
#include "Time.H" #include "Time.H"
#include "wordReList.H"
#include "incompressible/singlePhaseTransportModel/singlePhaseTransportModel.H" #include "incompressible/singlePhaseTransportModel/singlePhaseTransportModel.H"
#include "incompressible/RAS/RASModel/RASModel.H" #include "incompressible/RAS/RASModel/RASModel.H"
@ -229,7 +230,10 @@ void Foam::forces::read(const dictionary& dict)
const fvMesh& mesh = refCast<const fvMesh>(obr_); const fvMesh& mesh = refCast<const fvMesh>(obr_);
patchSet_ = mesh.boundaryMesh().patchSet(dict.lookup("patches")); patchSet_ = mesh.boundaryMesh().patchSet
(
wordReList(dict.lookup("patches"))
);
if (directForceDensity_) if (directForceDensity_)
{ {