-
Notifications
You must be signed in to change notification settings - Fork 0
/
apartment.py
42 lines (34 loc) · 1.09 KB
/
apartment.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
from abc import abstractmethod
class Apartment(object):
def __init__(self, ls):
"""Author: Maor Maharizi,
Created: 30.01.2023,
Detail: init the parameters,
Return: Null"""
self.list = ls
self.__kitchentype = None
@property
def kitchen(self):
return self.__kitchentype
@kitchen.setter
def kitchen(self, k):
self.__kitchentype = k
@kitchen.deleter
def kitchen(self):
del self.__kitchentype
# abstract method, calculate arnona, use in children
@abstractmethod
def calc_arnona(self):
"""Author: Maor Maharizi,
Created: 30.01.2023,
Detail: calc arnona to partment who inheritance me
Return: sum price"""
pass
# abstract method, calculate price apartment, use in children
@abstractmethod
def calc_price_apartment(self):
"""Author: Maor Maharizi,
Created: 30.01.2023,
Detail: calc price apartment who inheritance me
Return: sum price"""
pass