PyFoam.RunDictionary.TimeDirectory module¶
Working with direcotries from a time-step
-
class
PyFoam.RunDictionary.TimeDirectory.
TimeDirectory
(name, time, create=False, region=None, processor=None, tolerant=False, yieldParsedFiles=False)[source]¶ Bases:
object
Represents a directory for a timestep
-
_TimeDirectory__remove
(key)¶
-
__dict__
= dict_proxy({'getFiles': <function getFiles>, '__module__': 'PyFoam.RunDictionary.TimeDirectory', 'reread': <function reread>, '__getitem__': <function __getitem__>, '__contains__': <function __contains__>, '_TimeDirectory__remove': <function __remove>, 'baseName': <function baseName>, '__setitem__': <function __setitem__>, '__doc__': 'Represents a directory for a timestep', '__iter__': <function __iter__>, '__init__': <function __init__>, '__delitem__': <function __delitem__>, '__dict__': <attribute '__dict__' of 'TimeDirectory' objects>, 'copy': <function copy>, '__weakref__': <attribute '__weakref__' of 'TimeDirectory' objects>, 'clear': <function clear>, '__len__': <function __len__>})¶
-
__init__
(name, time, create=False, region=None, processor=None, tolerant=False, yieldParsedFiles=False)[source]¶ Parameters: - name – name of the case directory
- time – time in the directory
- create – Create the directory if it does not exist
- tolerant – Do not fail if there are inconsistencies
- region – The mesh region for multi-region cases
- yieldParsedFiles – let the iterator return PasedParameterFile objects instead of SolutionFile
-
__module__
= 'PyFoam.RunDictionary.TimeDirectory'¶
-
__weakref__
¶ list of weak references to the object (if defined)
-
copy
(orig, purge=False, overwrite=True, mustExist=False, exclude=[], include=['*'])[source]¶ Copy SolutionFiles from another TimeDirectory to the current TimeDirectory. Returns a list with the copied values :param orig: the TimeDirectory with the original files :param purge: remove all current files in this directory :param overwrite: if the file already exists it is overwritten :param mustExist: only if the file already exists it is overwritten :param exclude: List of fnmatch-patterns that should be excluded (Default: none) :param include: List of fnmatch-patterns that should be included (Default: all)
-