mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
zone updates
This commit is contained in:
@ -22,9 +22,6 @@ License
|
||||
along with OpenFOAM; if not, write to the Free Software Foundation,
|
||||
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
Description
|
||||
A subset of mesh cells.
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "cellZone.H"
|
||||
|
||||
@ -201,15 +201,9 @@ public:
|
||||
//- Return zoneMesh reference
|
||||
const cellZoneMesh& zoneMesh() const;
|
||||
|
||||
//- Clear addressing
|
||||
virtual void clearAddressing();
|
||||
|
||||
//- Check zone definition. Return true if in error.
|
||||
virtual bool checkDefinition(const bool report = false) const;
|
||||
|
||||
//- Write
|
||||
virtual void write(Ostream&) const;
|
||||
|
||||
//- Write dictionary
|
||||
virtual void writeDict(Ostream&) const;
|
||||
|
||||
|
||||
@ -22,9 +22,6 @@ License
|
||||
along with OpenFOAM; if not, write to the Free Software Foundation,
|
||||
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
Description
|
||||
A subset of mesh faces.
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "faceZone.H"
|
||||
|
||||
@ -22,9 +22,6 @@ License
|
||||
along with OpenFOAM; if not, write to the Free Software Foundation,
|
||||
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
Description
|
||||
A subset of mesh points.
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "pointZone.H"
|
||||
|
||||
@ -202,9 +202,6 @@ public:
|
||||
//- Helper function to re-direct to zone::localID(...)
|
||||
label whichPoint(const label globalPointID) const;
|
||||
|
||||
//- Clear addressing
|
||||
virtual void clearAddressing();
|
||||
|
||||
//- Check zone definition. Return true if in error.
|
||||
virtual bool checkDefinition(const bool report = false) const;
|
||||
|
||||
@ -212,9 +209,6 @@ public:
|
||||
virtual void movePoints(const pointField&)
|
||||
{}
|
||||
|
||||
//- Write
|
||||
virtual void write(Ostream&) const;
|
||||
|
||||
//- Write dictionary
|
||||
virtual void writeDict(Ostream&) const;
|
||||
|
||||
|
||||
@ -189,6 +189,36 @@ void Foam::zone::clearAddressing()
|
||||
}
|
||||
|
||||
|
||||
bool Foam::zone::checkDefinition(const label maxSize, const bool report) const
|
||||
{
|
||||
const labelList& addr = *this;
|
||||
|
||||
bool boundaryError = false;
|
||||
|
||||
forAll(addr, i)
|
||||
{
|
||||
if (addr[i] < 0 || addr[i] >= maxSize)
|
||||
{
|
||||
boundaryError = true;
|
||||
|
||||
if (report)
|
||||
{
|
||||
SeriousErrorIn
|
||||
(
|
||||
"bool zone::checkDefinition("
|
||||
"const label maxSize, const bool report) const"
|
||||
) << "Zone " << name_
|
||||
<< " contains invalid index label " << addr[i] << nl
|
||||
<< "Valid index labels are 0.."
|
||||
<< maxSize-1 << endl;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return boundaryError;
|
||||
}
|
||||
|
||||
|
||||
void Foam::zone::write(Ostream& os) const
|
||||
{
|
||||
os << nl << name_
|
||||
|
||||
Reference in New Issue
Block a user