in reply to Discussion(maybe?) How would you do this? Modules and reading a file/dir
Each module knows how to read, modify and save it's own type of data, and when a script uses a module and invokes one of it's methods, the associated data file is read just once, and can be used, updated and saved back to disk as often as you want during the lifetime of any one process.
If there are multiple steps in a given process that use a given type of file, the corresponding module will always have its current state and content already loaded as module-internal data, with appropriate "getters" and "setters" (and other convenience functions as you see fit) tailored to that type of file.
|
|---|