ogstools.ogs6py.python_script module#
- class ogstools.ogs6py.python_script.PythonScript[source]#
Bases:
ReferencedFileClass managing the python script file (.py) for an OGS project.
Tracks both the XML reference to the script and the actual file, enabling proper save/copy operations.
Initialize a StorageBase object.
- Parameters:
class_id – Type identifier for this saveable object (e.g., “Model”, “Simulation”).
file_ext – File extension if this is a file (e.g., “yaml”, “prj”). Empty string for directories.
default_target – Default path for saving if none is specified.
id – Unique identifier. If None, generates a timestamp-based ID.
- __init__(tree)[source]#
Initialize a StorageBase object.
- Parameters:
class_id – Type identifier for this saveable object (e.g., “Model”, “Simulation”).
file_ext – File extension if this is a file (e.g., “yaml”, “prj”). Empty string for directories.
default_target – Default path for saving if none is specified.
id – Unique identifier. If None, generates a timestamp-based ID.