Skip to content

Commit

Permalink
This addresses comments made regarding the msx model files. Documenta…
Browse files Browse the repository at this point in the history
…tion is not pulled in this commit
  • Loading branch information
dbhart committed Oct 1, 2024
1 parent a5c2ed3 commit f307ae9
Show file tree
Hide file tree
Showing 5 changed files with 300 additions and 300 deletions.
36 changes: 30 additions & 6 deletions wntr/msx/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ def __repr__(self):


class ReactionBase(ABC):
"""Water quality reaction class
"""Water quality reaction class.
This is an abstract class for water quality reactions with partial concrete
attribute and method definitions. All parameters and methods documented
Expand Down Expand Up @@ -355,9 +355,13 @@ class ReactionBase(ABC):
"""

def __init__(self, species_name: str, *, note: NoteType = None) -> None:
"""Water quality reaction definition
"""Reaction ABC init method.
This abstract class must be subclassed.
Make sure you call this method from your concrete subclass ``__init__`` method:
.. code::
super().__init__(species_name, note=note)
Parameters
----------
Expand Down Expand Up @@ -438,7 +442,13 @@ class VariableBase(ABC):
"""

def __init__(self, name: str, *, note: NoteType = None) -> None:
"""Multi-species variable constructor arguments
"""Variable ABC init method.
Make sure you call this method from your concrete subclass ``__init__`` method:
.. code::
super().__init__(name, note=note)
Parameters
----------
Expand Down Expand Up @@ -522,7 +532,15 @@ class ReactionSystemBase(ABC):
"""

def __init__(self) -> None:
"""Constructor for the reaction system."""
"""Constructor for the reaction system.
Make sure you call this method from your concrete subclass ``__init__`` method:
.. code::
super().__init__()
"""
self._vars: DisjointMapping = DisjointMapping()
"""Variables registry, which is mapped to dictionary functions on the
reaction system object"""
Expand Down Expand Up @@ -639,7 +657,13 @@ class QualityModelBase(ABC):
"""

def __init__(self, filename=None):
"""Abstract water quality model
"""QualityModel ABC init method.
Make sure you call this method from your concrete subclass ``__init__`` method:
.. code::
super().__init__(filename=filename)
Parameters
----------
Expand Down
Loading

0 comments on commit f307ae9

Please sign in to comment.