mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
BUG: polyMesh constructor AUTO_WRITE flag, ignored readOpt (#1147)
- fixed some more places with an explicit AUTO_WRITE. BUG: revert handling of the readOption. It should not be NO_READ. In cases where the user a IOobject without specifying read/write, it defaults to NO_READ anyhow. However, the move constructor can also be called with empty lists and a read option. This has the same signature, but obviously will not work with NO_READ.
This commit is contained in:
@ -213,7 +213,9 @@ int main(int argc, char *argv[])
|
|||||||
(
|
(
|
||||||
fvMesh::defaultRegion,
|
fvMesh::defaultRegion,
|
||||||
runTime.timeName(),
|
runTime.timeName(),
|
||||||
runTime
|
runTime,
|
||||||
|
IOobject::NO_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
pointField(mesh.points()), // Could we safely re-use the data?
|
pointField(mesh.points()), // Could we safely re-use the data?
|
||||||
faceList(mesh.faces()),
|
faceList(mesh.faces()),
|
||||||
|
|||||||
@ -3,7 +3,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-2016 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation | Copyright (C) 2019 OpenCFD Ltd.
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
@ -605,7 +605,9 @@ int main(int argc, char *argv[])
|
|||||||
(
|
(
|
||||||
polyMesh::defaultRegion,
|
polyMesh::defaultRegion,
|
||||||
runTime.constant(),
|
runTime.constant(),
|
||||||
runTime
|
runTime,
|
||||||
|
IOobject::NO_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
std::move(points),
|
std::move(points),
|
||||||
cellShapes,
|
cellShapes,
|
||||||
|
|||||||
@ -3,7 +3,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-2016 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation | Copyright (C) 2015-2019 OpenCFD Ltd.
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
@ -329,7 +329,9 @@ int main(int argc, char *argv[])
|
|||||||
(
|
(
|
||||||
polyMesh::defaultRegion,
|
polyMesh::defaultRegion,
|
||||||
runTime.constant(),
|
runTime.constant(),
|
||||||
runTime
|
runTime,
|
||||||
|
IOobject::NO_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
pointField(points), // Copy of points
|
pointField(points), // Copy of points
|
||||||
cells,
|
cells,
|
||||||
|
|||||||
@ -374,7 +374,7 @@ Foam::polyMesh::polyMesh
|
|||||||
instance(),
|
instance(),
|
||||||
meshSubDir,
|
meshSubDir,
|
||||||
*this,
|
*this,
|
||||||
IOobject::NO_READ,
|
io.readOpt(),
|
||||||
io.writeOpt()
|
io.writeOpt()
|
||||||
),
|
),
|
||||||
std::move(points)
|
std::move(points)
|
||||||
@ -387,7 +387,7 @@ Foam::polyMesh::polyMesh
|
|||||||
instance(),
|
instance(),
|
||||||
meshSubDir,
|
meshSubDir,
|
||||||
*this,
|
*this,
|
||||||
IOobject::NO_READ,
|
io.readOpt(),
|
||||||
io.writeOpt()
|
io.writeOpt()
|
||||||
),
|
),
|
||||||
std::move(faces)
|
std::move(faces)
|
||||||
@ -400,7 +400,7 @@ Foam::polyMesh::polyMesh
|
|||||||
instance(),
|
instance(),
|
||||||
meshSubDir,
|
meshSubDir,
|
||||||
*this,
|
*this,
|
||||||
IOobject::NO_READ,
|
io.readOpt(),
|
||||||
io.writeOpt()
|
io.writeOpt()
|
||||||
),
|
),
|
||||||
std::move(owner)
|
std::move(owner)
|
||||||
@ -413,7 +413,7 @@ Foam::polyMesh::polyMesh
|
|||||||
instance(),
|
instance(),
|
||||||
meshSubDir,
|
meshSubDir,
|
||||||
*this,
|
*this,
|
||||||
IOobject::NO_READ,
|
io.readOpt(),
|
||||||
io.writeOpt()
|
io.writeOpt()
|
||||||
),
|
),
|
||||||
std::move(neighbour)
|
std::move(neighbour)
|
||||||
@ -427,7 +427,7 @@ Foam::polyMesh::polyMesh
|
|||||||
instance(),
|
instance(),
|
||||||
meshSubDir,
|
meshSubDir,
|
||||||
*this,
|
*this,
|
||||||
IOobject::NO_READ,
|
io.readOpt(),
|
||||||
io.writeOpt()
|
io.writeOpt()
|
||||||
),
|
),
|
||||||
*this,
|
*this,
|
||||||
@ -447,7 +447,7 @@ Foam::polyMesh::polyMesh
|
|||||||
instance(),
|
instance(),
|
||||||
meshSubDir,
|
meshSubDir,
|
||||||
*this,
|
*this,
|
||||||
IOobject::NO_READ,
|
io.readOpt(),
|
||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
*this,
|
*this,
|
||||||
@ -461,7 +461,7 @@ Foam::polyMesh::polyMesh
|
|||||||
instance(),
|
instance(),
|
||||||
meshSubDir,
|
meshSubDir,
|
||||||
*this,
|
*this,
|
||||||
IOobject::NO_READ,
|
io.readOpt(),
|
||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
*this,
|
*this,
|
||||||
@ -475,7 +475,7 @@ Foam::polyMesh::polyMesh
|
|||||||
instance(),
|
instance(),
|
||||||
meshSubDir,
|
meshSubDir,
|
||||||
*this,
|
*this,
|
||||||
IOobject::NO_READ,
|
io.readOpt(),
|
||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
*this,
|
*this,
|
||||||
|
|||||||
@ -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) 2016-2018 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 2016-2019 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -2607,7 +2607,9 @@ Foam::autoPtr<Foam::polyMesh> Foam::ccm::reader::mesh
|
|||||||
(
|
(
|
||||||
polyMesh::defaultRegion,
|
polyMesh::defaultRegion,
|
||||||
"constant",
|
"constant",
|
||||||
registry
|
registry,
|
||||||
|
IOobject::NO_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
std::move(points_),
|
std::move(points_),
|
||||||
std::move(faces_),
|
std::move(faces_),
|
||||||
|
|||||||
@ -3,7 +3,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-2016 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation | Copyright (C) 2019 OpenCFD Ltd.
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
@ -97,7 +97,9 @@ Foam::autoPtr<Foam::polyMesh> Foam::meshReader::mesh
|
|||||||
(
|
(
|
||||||
polyMesh::defaultRegion,
|
polyMesh::defaultRegion,
|
||||||
registry.time().constant(),
|
registry.time().constant(),
|
||||||
registry
|
registry,
|
||||||
|
IOobject::NO_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
std::move(points_),
|
std::move(points_),
|
||||||
std::move(meshFaces_),
|
std::move(meshFaces_),
|
||||||
|
|||||||
@ -3,7 +3,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) 2016-2018 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 2016-2018 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation | Copyright (C) 2019 OpenCFD Ltd.
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
@ -431,7 +431,9 @@ Foam::autoPtr<Foam::polyMesh> Foam::fileFormats::FIREMeshReader::mesh
|
|||||||
(
|
(
|
||||||
polyMesh::defaultRegion,
|
polyMesh::defaultRegion,
|
||||||
"constant",
|
"constant",
|
||||||
registry
|
registry,
|
||||||
|
IOobject::NO_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
std::move(points_),
|
std::move(points_),
|
||||||
std::move(meshFaces_),
|
std::move(meshFaces_),
|
||||||
|
|||||||
@ -3311,6 +3311,7 @@ Foam::autoPtr<Foam::mapPolyMesh> Foam::polyTopoChange::makeMesh
|
|||||||
|
|
||||||
IOobject noReadIO(io);
|
IOobject noReadIO(io);
|
||||||
noReadIO.readOpt() = IOobject::NO_READ;
|
noReadIO.readOpt() = IOobject::NO_READ;
|
||||||
|
noReadIO.readOpt() = IOobject::AUTO_WRITE;
|
||||||
newMeshPtr.reset
|
newMeshPtr.reset
|
||||||
(
|
(
|
||||||
new fvMesh
|
new fvMesh
|
||||||
|
|||||||
@ -3,7 +3,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) 2012-2017 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2012-2017 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015-2018 OpenCFD Ltd.
|
\\/ M anipulation | Copyright (C) 2015-2019 OpenCFD Ltd.
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
@ -478,7 +478,8 @@ void Foam::meshToMesh::calculate(const word& methodName, const bool normalise)
|
|||||||
"newTgt." + Foam::name(Pstream::myProcNo()),
|
"newTgt." + Foam::name(Pstream::myProcNo()),
|
||||||
tgtRegion_.time().timeName(),
|
tgtRegion_.time().timeName(),
|
||||||
tgtRegion_.time(),
|
tgtRegion_.time(),
|
||||||
IOobject::NO_READ
|
IOobject::NO_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
std::move(newTgtPoints),
|
std::move(newTgtPoints),
|
||||||
std::move(newTgtFaces),
|
std::move(newTgtFaces),
|
||||||
|
|||||||
Reference in New Issue
Block a user