ENH: use restricted dictionary lookup for utilities (issue #762)

- get<label>, get<scalar> instead of readLabel, readScalar, etc.
This commit is contained in:
Mark Olesen
2018-07-24 08:08:30 +02:00
parent d362c2235b
commit d58c142404
90 changed files with 475 additions and 659 deletions

View File

@ -92,7 +92,7 @@ int main(int argc, char *argv[])
wordList polyMeshPatches
(
faMeshDefinition.lookup("polyMeshPatches")
faMeshDefinition.get<wordList>("polyMeshPatches")
);
const dictionary& bndDict = faMeshDefinition.subDict("boundary");
@ -107,9 +107,9 @@ int main(int argc, char *argv[])
faPatches[patchI].name_ = faPatchNames[patchI];
faPatches[patchI].type_ = word(curPatchDict.lookup("type"));
faPatches[patchI].type_ = curPatchDict.get<word>("type");
const word ownName = curPatchDict.lookup("ownerPolyPatch");
const word ownName(curPatchDict.get<word>("ownerPolyPatch"));
faPatches[patchI].ownPolyPatchID_ =
mesh.boundaryMesh().findPatchID(ownName);
@ -121,7 +121,7 @@ int main(int argc, char *argv[])
<< exit(FatalError);
}
const word neiName = curPatchDict.lookup("neighbourPolyPatch");
const word neiName(curPatchDict.get<word>("neighbourPolyPatch"));
faPatches[patchI].ngbPolyPatchID_ =
mesh.boundaryMesh().findPatchID(neiName);