From 686b04cb6cfdd600d050883c57c4025980728133 Mon Sep 17 00:00:00 2001 From: Pilar Date: Wed, 9 Nov 2022 16:19:56 -0500 Subject: [PATCH] new system classes added --- .../energy_systems/hvac_system.py | 23 +++++++++++-- .../energy_systems/hvac_terminal_unit.py | 33 +++++++++++++++++++ 2 files changed, 53 insertions(+), 3 deletions(-) create mode 100644 city_model_structure/energy_systems/hvac_terminal_unit.py diff --git a/city_model_structure/energy_systems/hvac_system.py b/city_model_structure/energy_systems/hvac_system.py index 3e390cfe..d526b445 100644 --- a/city_model_structure/energy_systems/hvac_system.py +++ b/city_model_structure/energy_systems/hvac_system.py @@ -4,7 +4,8 @@ SPDX - License - Identifier: LGPL - 3.0 - or -later Copyright © 2022 Concordia CERC group Project Coder Pilar Monsalvete Alvarez de Uribarri pilar.monsalvete@concordia.ca """ -from typing import Union +from typing import Union, List +from city_model_structure.building_demand.thermal_zone import ThermalZone class HvacSystem: @@ -13,11 +14,12 @@ class HvacSystem: """ def __init__(self): self._type = None + self._thermal_zones = None @property def type(self) -> Union[None, str]: """ - Get hvac system type a thermal zone + Get hvac system type :return: None or str """ return self._type @@ -25,9 +27,24 @@ class HvacSystem: @type.setter def type(self, value): """ - Set heating set point defined for a thermal zone + Set hvac system type :param value: str """ if value is not None: self._type = str(value) + @property + def thermal_zones(self) -> Union[None, List[ThermalZone]]: + """ + Get list of zones that this unit serves + :return: None or [ThermalZone] + """ + return self._thermal_zones + + @thermal_zones.setter + def thermal_zones(self, value): + """ + Set list of zones that this unit serves + :param value: [ThermalZone] + """ + self._thermal_zones = value diff --git a/city_model_structure/energy_systems/hvac_terminal_unit.py b/city_model_structure/energy_systems/hvac_terminal_unit.py new file mode 100644 index 00000000..7583bdc4 --- /dev/null +++ b/city_model_structure/energy_systems/hvac_terminal_unit.py @@ -0,0 +1,33 @@ +""" +HvacTerminalUnit module +SPDX - License - Identifier: LGPL - 3.0 - or -later +Copyright © 2022 Concordia CERC group +Project Coder Pilar Monsalvete Alvarez de Uribarri pilar.monsalvete@concordia.ca +""" +from typing import Union + + +class HvacTerminalUnit: + """ + HvacTerminalUnit class + """ + def __init__(self): + self._type = None + + @property + def type(self) -> Union[None, str]: + """ + Get type of hvac terminal unit defined for a thermal zone + :return: None or str + """ + return self._type + + @type.setter + def type(self, value): + """ + Set type of hvac terminal unit defined for a thermal zone + :param value: str + """ + if value is not None: + self._type = str(value) +