ENH: support 'get()' for retrieving argList options

- previously only had 'opt<..>()' for options, but 'get<..>()'
  provides more similarity with dictionary methods.
  The 'opt<..>()' method is retained.
This commit is contained in:
Mark Olesen
2019-11-26 21:07:11 +01:00
committed by Andrew Heather
parent 29ccc00c7d
commit 1310e85225
81 changed files with 155 additions and 141 deletions

View File

@ -245,7 +245,7 @@ int main(int argc, char *argv[])
ensightCase::options caseOpts(format);
caseOpts.nodeValues(args.found("nodeValues"));
caseOpts.width(args.opt<label>("width", 8));
caseOpts.width(args.get<label>("width", 8));
caseOpts.overwrite(true); // remove existing output directory
// Can also have separate directory for lagrangian
@ -255,7 +255,7 @@ int main(int argc, char *argv[])
// Define sub-directory name to use for EnSight data.
// The path to the ensight directory is at case level only
// - For parallel cases, data only written from master
fileName outputDir = args.opt<word>("name", "EnSight");
fileName outputDir = args.get<word>("name", "EnSight");
if (!outputDir.isAbsolute())
{
outputDir = args.globalPath()/outputDir;