Commit 4413212d authored by andy's avatar andy
Browse files

ENH: regionModel - AMI list now mutable to allow const access

parent feacb903
...@@ -197,7 +197,7 @@ Foam::regionModels::regionModel::interRegionAMI ...@@ -197,7 +197,7 @@ Foam::regionModels::regionModel::interRegionAMI
const label regionPatchI, const label regionPatchI,
const label nbrPatchI, const label nbrPatchI,
const bool flip const bool flip
) ) const
{ {
label nbrRegionID = findIndex(interRegionAMINames_, nbrRegion.name()); label nbrRegionID = findIndex(interRegionAMINames_, nbrRegion.name());
......
...@@ -125,10 +125,11 @@ protected: ...@@ -125,10 +125,11 @@ protected:
// Inter-region AMI interpolation caching // Inter-region AMI interpolation caching
//- List of region names this region is coupled to //- List of region names this region is coupled to
wordList interRegionAMINames_; mutable wordList interRegionAMINames_;
//- List of AMI objects per coupled region //- List of AMI objects per coupled region
PtrList<PtrList<AMIPatchToPatchInterpolation> > interRegionAMI_; mutable PtrList<PtrList<AMIPatchToPatchInterpolation> >
interRegionAMI_;
// Protected member functions // Protected member functions
...@@ -146,7 +147,7 @@ protected: ...@@ -146,7 +147,7 @@ protected:
const label regionPatchI, const label regionPatchI,
const label nbrPatchI, const label nbrPatchI,
const bool flip const bool flip
); ) const;
public: public:
...@@ -257,7 +258,7 @@ public: ...@@ -257,7 +258,7 @@ public:
const label nbrPatchI, const label nbrPatchI,
const Field<Type>& nbrField, const Field<Type>& nbrField,
const bool flip = false const bool flip = false
); ) const;
//- Map patch field from another region model to local patch //- Map patch field from another region model to local patch
template<class Type> template<class Type>
...@@ -267,7 +268,7 @@ public: ...@@ -267,7 +268,7 @@ public:
const word& fieldName, const word& fieldName,
const label regionPatchI, const label regionPatchI,
const bool flip = false const bool flip = false
); ) const;
//- Map patch internal field from another region model to local //- Map patch internal field from another region model to local
// patch // patch
...@@ -278,7 +279,7 @@ public: ...@@ -278,7 +279,7 @@ public:
const word& fieldName, const word& fieldName,
const label regionPatchI, const label regionPatchI,
const bool flip = false const bool flip = false
); ) const;
//- Convert a local region field to the primary region //- Convert a local region field to the primary region
template<class Type> template<class Type>
......
...@@ -2,7 +2,7 @@ ...@@ -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) 2011-2012 OpenFOAM Foundation \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
\\/ M anipulation | \\/ M anipulation |
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
License License
...@@ -32,7 +32,7 @@ Foam::regionModels::regionModel::mapRegionPatchField ...@@ -32,7 +32,7 @@ Foam::regionModels::regionModel::mapRegionPatchField
const label nbrPatchI, const label nbrPatchI,
const Field<Type>& nbrField, const Field<Type>& nbrField,
const bool flip const bool flip
) ) const
{ {
int oldTag = UPstream::msgType(); int oldTag = UPstream::msgType();
UPstream::msgType() = oldTag + 1; UPstream::msgType() = oldTag + 1;
...@@ -56,7 +56,7 @@ Foam::regionModels::regionModel::mapRegionPatchField ...@@ -56,7 +56,7 @@ Foam::regionModels::regionModel::mapRegionPatchField
const word& fieldName, const word& fieldName,
const label regionPatchI, const label regionPatchI,
const bool flip const bool flip
) ) const
{ {
typedef GeometricField<Type, fvPatchField, volMesh> fieldType; typedef GeometricField<Type, fvPatchField, volMesh> fieldType;
...@@ -108,7 +108,7 @@ Foam::regionModels::regionModel::mapRegionPatchInternalField ...@@ -108,7 +108,7 @@ Foam::regionModels::regionModel::mapRegionPatchInternalField
const word& fieldName, const word& fieldName,
const label regionPatchI, const label regionPatchI,
const bool flip const bool flip
) ) const
{ {
typedef GeometricField<Type, fvPatchField, volMesh> fieldType; typedef GeometricField<Type, fvPatchField, volMesh> fieldType;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment