104 lines
2.2 KiB
Python
104 lines
2.2 KiB
Python
"""
|
|
Appliances module
|
|
SPDX - License - Identifier: LGPL - 3.0 - or -later
|
|
Copyright © 2022 Project Author Pilar Monsalvete Alvarez de Uribarri pilar.monsalvete@concordia.ca
|
|
"""
|
|
from typing import Union
|
|
from city_model_structure.attributes.schedule import Schedule
|
|
|
|
|
|
class Appliances:
|
|
"""
|
|
Appliances class
|
|
"""
|
|
def __init__(self):
|
|
self._lighting_density = None
|
|
self._convective_fraction = None
|
|
self._radiant_fraction = None
|
|
self._latent_fraction = None
|
|
self._schedule = None
|
|
|
|
@property
|
|
def lighting_density(self) -> Union[None, float]:
|
|
"""
|
|
Get lighting density in Watts per m2
|
|
:return: None or float
|
|
"""
|
|
return self._lighting_density
|
|
|
|
@lighting_density.setter
|
|
def lighting_density(self, value):
|
|
"""
|
|
Set lighting density in Watts per m2
|
|
:param value: float
|
|
"""
|
|
if value is not None:
|
|
self._lighting_density = float(value)
|
|
|
|
@property
|
|
def convective_fraction(self) -> Union[None, float]:
|
|
"""
|
|
Get convective fraction
|
|
:return: None or float
|
|
"""
|
|
return self._convective_fraction
|
|
|
|
@convective_fraction.setter
|
|
def convective_fraction(self, value):
|
|
"""
|
|
Set convective fraction
|
|
:param value: float
|
|
"""
|
|
if value is not None:
|
|
self._convective_fraction = float(value)
|
|
|
|
@property
|
|
def radiant_fraction(self) -> Union[None, float]:
|
|
"""
|
|
Get radiant fraction
|
|
:return: None or float
|
|
"""
|
|
return self._radiant_fraction
|
|
|
|
@radiant_fraction.setter
|
|
def radiant_fraction(self, value):
|
|
"""
|
|
Set radiant fraction
|
|
:param value: float
|
|
"""
|
|
if value is not None:
|
|
self._radiant_fraction = float(value)
|
|
|
|
@property
|
|
def latent_fraction(self) -> Union[None, float]:
|
|
"""
|
|
Get latent fraction
|
|
:return: None or float
|
|
"""
|
|
return self._latent_fraction
|
|
|
|
@latent_fraction.setter
|
|
def latent_fraction(self, value):
|
|
"""
|
|
Set latent fraction
|
|
:param value: float
|
|
"""
|
|
if value is not None:
|
|
self._latent_fraction = float(value)
|
|
|
|
@property
|
|
def schedule(self) -> Union[None, Schedule]:
|
|
"""
|
|
Get schedule
|
|
:return: None or Schedule
|
|
"""
|
|
return self._schedule
|
|
|
|
@schedule.setter
|
|
def schedule(self, value):
|
|
"""
|
|
Set schedule
|
|
:param value: Schedule
|
|
"""
|
|
self._schedule = value
|