mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-12-28 03:37:59 +00:00
ENH: provide Time::NewGlobalTime factory methods (#3007)
- avoids clutter of argList::envGlobalPath() ... ENH: allow temporary overwriting of output writeFormat - allows switching for particular output routines COMP: explicitly use TimePaths methods with Time - this simplifies any overloading done at a later stage
This commit is contained in:
@ -5,7 +5,7 @@
|
||||
\\ / A nd | www.openfoam.com
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
Copyright (C) 2022 OpenCFD Ltd.
|
||||
Copyright (C) 2022-2023 OpenCFD Ltd.
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
@ -122,11 +122,10 @@ int main(int argc, char *argv[])
|
||||
// Fallback (eg, no runTime)
|
||||
if (!timePtr.good())
|
||||
{
|
||||
timePtr.reset(Time::New(argList::envGlobalPath()));
|
||||
timePtr.reset(Time::NewGlobalTime());
|
||||
}
|
||||
|
||||
|
||||
const auto& tm = timePtr();
|
||||
const auto& tm = *timePtr;
|
||||
|
||||
fileName resolvedName(inputName);
|
||||
resolvedName.toAbsolute();
|
||||
|
||||
Reference in New Issue
Block a user