Added docstrings to class intialisers

This commit is contained in:
Marek Wolan
2023-07-06 16:08:51 +01:00
parent 9167816896
commit 653d76ec62
23 changed files with 253 additions and 137 deletions

View File

@@ -11,19 +11,7 @@ _LOGGER: Final[logging.Logger] = logging.getLogger(__name__)
class ActiveNode(Node):
"""Active Node class.
:param node_id: The node ID
:param name: The node name
:param node_type: The node type (enum)
:param priority: The node priority (enum)
:param hardware_state: The node Hardware State
:param ip_address: The node IP address
:param software_state: The node Software State
:param file_system_state: The node file system state
:param config_values: The config values
"""
"""Active Node class."""
def __init__(
self,
@@ -37,6 +25,19 @@ class ActiveNode(Node):
file_system_state: FileSystemState,
config_values: TrainingConfig,
):
"""
Initialise an active node.
:param node_id: The node ID
:param name: The node name
:param node_type: The node type (enum)
:param priority: The node priority (enum)
:param hardware_state: The node Hardware State
:param ip_address: The node IP address
:param software_state: The node Software State
:param file_system_state: The node file system state
:param config_values: The config values
"""
super().__init__(node_id, name, node_type, priority, hardware_state, config_values)
self.ip_address: str = ip_address
# Related to Software