mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
STYLE: enforce dictionary read length for box/boxes entry
This commit is contained in:
@ -85,13 +85,18 @@ Foam::boxToCell::boxToCell
|
||||
)
|
||||
:
|
||||
topoSetSource(mesh),
|
||||
bbs_
|
||||
(
|
||||
dict.found("box")
|
||||
? treeBoundBoxList(1, treeBoundBox(dict.lookup("box")))
|
||||
: dict.lookup("boxes")
|
||||
)
|
||||
{}
|
||||
bbs_()
|
||||
{
|
||||
if (dict.found("box"))
|
||||
{
|
||||
bbs_.resize(1);
|
||||
dict.read("box", bbs_.first());
|
||||
}
|
||||
else
|
||||
{
|
||||
dict.read("boxes", bbs_);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Foam::boxToCell::boxToCell
|
||||
|
||||
@ -85,13 +85,18 @@ Foam::boxToFace::boxToFace
|
||||
)
|
||||
:
|
||||
topoSetSource(mesh),
|
||||
bbs_
|
||||
(
|
||||
dict.found("box")
|
||||
? treeBoundBoxList(1, treeBoundBox(dict.lookup("box")))
|
||||
: dict.lookup("boxes")
|
||||
)
|
||||
{}
|
||||
bbs_()
|
||||
{
|
||||
if (dict.found("box"))
|
||||
{
|
||||
bbs_.resize(1);
|
||||
dict.read("box", bbs_.first());
|
||||
}
|
||||
else
|
||||
{
|
||||
dict.read("boxes", bbs_);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Foam::boxToFace::boxToFace
|
||||
|
||||
@ -84,13 +84,18 @@ Foam::boxToPoint::boxToPoint
|
||||
)
|
||||
:
|
||||
topoSetSource(mesh),
|
||||
bbs_
|
||||
(
|
||||
dict.found("box")
|
||||
? treeBoundBoxList(1, treeBoundBox(dict.lookup("box")))
|
||||
: dict.lookup("boxes")
|
||||
)
|
||||
{}
|
||||
bbs_()
|
||||
{
|
||||
if (dict.found("box"))
|
||||
{
|
||||
bbs_.resize(1);
|
||||
dict.read("box", bbs_.first());
|
||||
}
|
||||
else
|
||||
{
|
||||
dict.read("boxes", bbs_);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Foam::boxToPoint::boxToPoint
|
||||
|
||||
Reference in New Issue
Block a user