mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: minor improvements for Enum
- found() method for consistency with other classes - operator()(name, deflt) for similarity to lookupOrDefault, but without a dictionary
This commit is contained in:
@ -377,7 +377,7 @@ bool Foam::fileFormats::FIREMeshReader::readGeometry(const scalar scaleFactor)
|
||||
IOstream::streamFormat fmt = IOstream::ASCII;
|
||||
|
||||
const word ext = geometryFile_.ext();
|
||||
bool supported = FIRECore::file3dExtensions.hasEnum(ext);
|
||||
bool supported = FIRECore::file3dExtensions.found(ext);
|
||||
if (supported)
|
||||
{
|
||||
FIRECore::fileExt3d fireFileType = FIRECore::file3dExtensions[ext];
|
||||
|
||||
@ -278,7 +278,7 @@ bool Foam::fileFormats::FIREMeshWriter::write(const fileName& meshName) const
|
||||
{
|
||||
const word ext = baseName.ext();
|
||||
|
||||
if (FIRECore::file3dExtensions.hasEnum(ext))
|
||||
if (FIRECore::file3dExtensions.found(ext))
|
||||
{
|
||||
FIRECore::fileExt3d fireFileType = FIRECore::file3dExtensions[ext];
|
||||
if (fireFileType == FIRECore::fileExt3d::POLY_ASCII)
|
||||
|
||||
Reference in New Issue
Block a user