From 83d046fa0b7dc39ad86c513d0cf2ec578ed5f212 Mon Sep 17 00:00:00 2001 From: Gabriel Gerlero Date: Wed, 20 Mar 2024 10:55:09 -0300 Subject: [PATCH] Improve documentation --- foamlib/__init__.py | 3 ++- foamlib/_cases.py | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/foamlib/__init__.py b/foamlib/__init__.py index df95c60..9cd8975 100644 --- a/foamlib/__init__.py +++ b/foamlib/__init__.py @@ -1,6 +1,6 @@ __version__ = "0.1.3" -from ._cases import FoamCase, AsyncFoamCase, FoamTimeDirectory +from ._cases import FoamCase, AsyncFoamCase, FoamTimeDirectory, FoamCaseBase from ._dictionaries import ( FoamFile, FoamFieldFile, @@ -15,6 +15,7 @@ "FoamCase", "AsyncFoamCase", "FoamTimeDirectory", + "FoamCaseBase", "FoamFile", "FoamFieldFile", "FoamDictionary", diff --git a/foamlib/_cases.py b/foamlib/_cases.py index 2ca5cdb..fcb72ce 100644 --- a/foamlib/_cases.py +++ b/foamlib/_cases.py @@ -25,7 +25,7 @@ from ._dictionaries import FoamFile, FoamFieldFile -class _FoamCaseBase(Sequence["FoamTimeDirectory"]): +class FoamCaseBase(Sequence["FoamTimeDirectory"]): def __init__(self, path: Union[Path, str]): self.path = Path(path).absolute() if not self.path.is_dir(): @@ -271,7 +271,7 @@ def __str__(self) -> str: return str(self.path) -class FoamCase(_FoamCaseBase): +class FoamCase(FoamCaseBase): """ An OpenFOAM case. @@ -407,7 +407,7 @@ def clone(self, dest: Union[Path, str]) -> "FoamCase": return FoamCase(dest) -class AsyncFoamCase(_FoamCaseBase): +class AsyncFoamCase(FoamCaseBase): """ An OpenFOAM case with asynchronous support.