- now use findEtcEntry() instead to handle file or directory.
Added findEtcEntries(), which provides provides a common code basis
for findEtcDirs(), findEtcFiles() ...
- this simplifies use of a unified test for directory or file.
fileName::Type what = myfile.type(true, true);
if (what == FILE) ...
if (what == DIRECTORY) ...
- Use distinct bit values for fileName::Type, for possible use in
the future.
- related to issue #1121, since we need a more flexible way of
expanding file or directory.
An alternative would be to add checkGzip to Foam::exists() and
Foam::type() functions, but that would make the code there more
confusing and in the fileHandler classes.
- for some special cases we wish to mark command-line arguments as
being optional, in order to do our own treatment. For example,
when an arbitrary number of arguments should be allowed.
Now tag this situation with argList::noMandatoryArgs().
The argList::argsMandatory() query can then be used in any further
logic, including the standard default argument checking.
- with the new default check, can consolidate the special-purpose
"setRootCaseNonMandatoryArgs.H"
into the regular
"setRootCase.H"
- revert to a simple "setRootCase.H" and move all the listing related
bits to a "setRootCaseLists.H" file. This leaves the information
available for solvers, or whoever else wishes, without being
introduced everywhere.
- add include guards and scoping to the listing files and rename to
something less generic.
listOptions.H -> setRootCaseListOptions.H
listOutput.H -> setRootCaseListOutput.H
- Now also responds to the contents of the trigger file,
processing action= contents similar to used with external coupling.
Previously it only handled an action that was defined in the
dictionary. With this update, the user can chose a diferent action
simply by echoing the appropriate action string into the trigger
file.
- similar to the foamEtcFile script -mode=... option, the specific
search location (user/group/other) can now also specified for
string expansions and as a numerical value for etcFile()
For example, if searching for group or other (project) controlDict,
but not wishing to see the user controlDict:
1. foamEtcFile -mode=go controlDict
2. fileName dictFile("<etc:go>/controlDict");
dictFile.expand();
3. etcFile(controlDict, false, 0077);
The default behaviour for searching all contexts is unchanged.
1. foamEtcFile controlDict
2. fileName dictFile("<etc>/controlDict");
dictFile.expand();
3. etcFile(controlDict);
- the local third-party headers are to be searched before any MPI
include directories. This stops the situation where an mpi-specific
version of ptscotch.h is installed into the MPI directories.
This "system" version may well have a different SCOTCH_Num size
(32 bit vs 64 bit) from the third-party library etc.
- change previous default (convert all faceZones unless -noFaceZones
specified) with the default behaviour to only convert face zones on
request.
- uses the '-faceZones' option as per foamToEnsight
- the result of lsof, which is used in the etc/cshrc to locate the
installation, may contain trailing information about host and mount
point.
There is also a moderate concern with people sourcing the
file indirectly with their own version in the same directory.
For example, a 'etc/cshrc-site' that actually sources 'etc/cshrc'.
This leads to multiple matches in the lsof output, so we only take
the first one, stop there and hope they didn't do something even
trickier.
- the counterpart to floatVector, doubleTensor, which can be useful
for connecting to programs that always expect double precision for
the arguments, when using single-precision for OpenFOAM itself.
Eg,
doubleVector pos = ...;
vtkcamera->SetPosition(pos.v_);
- prefer this to using the OPENFOAM define since this improves the
internal consistency with the build information.
The API information could change between builds without the
etcFiles.C being recompiled whereas the value of
Foam::foamVersion::api is force updated during the build (triggers
recompilation of globals.Cver)
Reports the min|max|average AMI weights to text file and optionally
writes VTK surfaces of the sum of the weights, and mask field for
ACMI patches.
Example usage:
AMIWeights
{
type AMIWeights;
libs ("libfieldFunctionObjects.so");
writeControl writeTime;
writeFields yes;
}