mirror of
https://github.com/OpenFOAM/OpenFOAM-6.git
synced 2025-12-08 06:57:46 +00:00
timeSelector: Rename option zeroTime -> withZero for consistency with the noZero option
This commit is contained in:
@ -72,8 +72,8 @@ int main(int argc, char *argv[])
|
||||
"Reconstruct fields of a parallel case"
|
||||
);
|
||||
|
||||
// enable -constant ... if someone really wants it
|
||||
// enable -zeroTime to prevent accidentally trashing the initial fields
|
||||
// Enable -constant ... if someone really wants it
|
||||
// Enable -withZero to prevent accidentally trashing the initial fields
|
||||
timeSelector::addOptions(true, true);
|
||||
argList::noParallel();
|
||||
#include "addRegionOption.H"
|
||||
@ -190,7 +190,7 @@ int main(int argc, char *argv[])
|
||||
);
|
||||
}
|
||||
|
||||
// use the times list from the master processor
|
||||
// Use the times list from the master processor
|
||||
// and select a subset based on the command-line options
|
||||
instantList timeDirs = timeSelector::select
|
||||
(
|
||||
@ -308,7 +308,7 @@ int main(int argc, char *argv[])
|
||||
processorMeshes procMeshes(databases, regionName);
|
||||
|
||||
|
||||
// check face addressing for meshes that have been decomposed
|
||||
// Check face addressing for meshes that have been decomposed
|
||||
// with a very old foam version
|
||||
#include "checkFaceAddressingComp.H"
|
||||
|
||||
@ -882,7 +882,7 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
}
|
||||
|
||||
Info<< "\nEnd\n" << endl;
|
||||
Info<< "End.\n" << endl;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -432,7 +432,7 @@ int main(int argc, char *argv[])
|
||||
);
|
||||
|
||||
// Enable -constant ... if someone really wants it
|
||||
// Enable -zeroTime to prevent accidentally trashing the initial fields
|
||||
// Enable -withZero to prevent accidentally trashing the initial fields
|
||||
timeSelector::addOptions(true, true);
|
||||
argList::noParallel();
|
||||
argList::addOption
|
||||
|
||||
@ -79,7 +79,7 @@ using namespace Foam;
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
// enable -constant
|
||||
// probably don't need -zeroTime though, since the fields are vetted
|
||||
// probably don't need -withZero though, since the fields are vetted
|
||||
// afterwards anyhow
|
||||
timeSelector::addOptions(true, false);
|
||||
argList::noParallel();
|
||||
|
||||
@ -113,7 +113,7 @@ void Foam::timeSelector::inplaceSelect(instantList& Times) const
|
||||
void Foam::timeSelector::addOptions
|
||||
(
|
||||
const bool constant,
|
||||
const bool zeroTime
|
||||
const bool withZero
|
||||
)
|
||||
{
|
||||
if (constant)
|
||||
@ -124,11 +124,11 @@ void Foam::timeSelector::addOptions
|
||||
"include the 'constant/' dir in the times list"
|
||||
);
|
||||
}
|
||||
if (zeroTime)
|
||||
if (withZero)
|
||||
{
|
||||
argList::addBoolOption
|
||||
(
|
||||
"zeroTime",
|
||||
"withZero",
|
||||
"include the '0/' dir in the times list"
|
||||
);
|
||||
}
|
||||
@ -136,7 +136,7 @@ void Foam::timeSelector::addOptions
|
||||
(
|
||||
"noZero",
|
||||
"exclude the '0/' dir from the times list, "
|
||||
"has precedence over the -zeroTime option"
|
||||
"has precedence over the -withZero option"
|
||||
);
|
||||
argList::addBoolOption
|
||||
(
|
||||
@ -228,10 +228,10 @@ Foam::List<Foam::instant> Foam::timeSelector::select
|
||||
// Exclude 0/ if specifically requested
|
||||
selectTimes[zeroIdx] = false;
|
||||
}
|
||||
else if (argList::validOptions.found("zeroTime"))
|
||||
else if (argList::validOptions.found("withZero"))
|
||||
{
|
||||
// With -zeroTime enabled, drop 0/ unless specifically requested
|
||||
selectTimes[zeroIdx] = args.optionFound("zeroTime");
|
||||
// With -withZero enabled, drop 0/ unless specifically requested
|
||||
selectTimes[zeroIdx] = args.optionFound("withZero");
|
||||
}
|
||||
}
|
||||
|
||||
@ -284,7 +284,7 @@ Foam::List<Foam::instant> Foam::timeSelector::selectIfPresent
|
||||
|| args.optionFound("time")
|
||||
|| args.optionFound("constant")
|
||||
|| args.optionFound("noZero")
|
||||
|| args.optionFound("zeroTime")
|
||||
|| args.optionFound("withZero")
|
||||
)
|
||||
{
|
||||
return select0(runTime, args);
|
||||
|
||||
@ -59,7 +59,7 @@ Description
|
||||
\endverbatim
|
||||
|
||||
The first argument avoids adding the \b -constant option. The second
|
||||
argument adds an additional \b -zeroTime option and also prevents the
|
||||
argument adds an additional \b -withZero option and also prevents the
|
||||
\c 0/ directory from being included in the default time range and in the
|
||||
\b -latestTime selection.
|
||||
|
||||
@ -122,16 +122,16 @@ public:
|
||||
// \param constant
|
||||
// Add the \b -constant option to include the \c constant/ directory
|
||||
//
|
||||
// \param zeroTime
|
||||
// Enable the \b -zeroTime option and alter the normal time selection
|
||||
// \param withZero
|
||||
// Enable the \b -withZero option and alter the normal time selection
|
||||
// behaviour (and \b -latestTime behaviour) to exclude the \c 0/
|
||||
// directory. The \c 0/ directory will only be included when
|
||||
// \b -zeroTime is specified.
|
||||
// The \b -noZero option has precedence over the @b -zeroTime option.
|
||||
// \b -withZero is specified.
|
||||
// The \b -noZero option has precedence over the @b -withZero option.
|
||||
static void addOptions
|
||||
(
|
||||
const bool constant=true,
|
||||
const bool zeroTime=false
|
||||
const bool withZero=false
|
||||
);
|
||||
|
||||
//- Return the set of times selected based on the argList options
|
||||
|
||||
Reference in New Issue
Block a user