OpenFOAM
5.0
The OpenFOAM Foundation
src
OpenFOAM
include
setSystemRunTimeDictionaryIO.H
Go to the documentation of this file.
1
fileName
dictPath
=
""
;
2
if
(
args
.
optionFound
(
"dict"
))
3
{
4
dictPath =
args
[
"dict"
];
5
if
(
isDir
(dictPath))
6
{
7
dictPath = dictPath /
dictName
;
8
}
9
}
10
11
IOobject
dictIO
12
(
13
dictName
,
14
runTime.system(),
15
runTime,
16
IOobject::MUST_READ_IF_MODIFIED,
17
IOobject::NO_WRITE
18
);
19
20
if
(dictPath.size())
21
{
22
dictIO
= IOobject
23
(
24
dictPath,
25
runTime,
26
IOobject::MUST_READ_IF_MODIFIED,
27
IOobject::NO_WRITE
28
);
29
}
dictIO
IOobject dictIO(dictName, runTime.system(), runTime, IOobject::MUST_READ_IF_MODIFIED, IOobject::NO_WRITE)
Foam::argList::optionFound
bool optionFound(const word &opt) const
Return true if the named option is found.
Definition:
argListI.H:108
Foam::isDir
bool isDir(const fileName &, const bool followLink=true)
Does the name exist as a DIRECTORY in the file system?
Definition:
POSIX.C:536
dictName
const word dictName("particleTrackDict")
dictPath
fileName dictPath
Definition:
setSystemRunTimeDictionaryIO.H:1
args
Foam::argList args(argc, argv)
Generated by
1.8.13