2021-08-26 13:27:43 -04:00
|
|
|
"""
|
|
|
|
Location module
|
|
|
|
SPDX - License - Identifier: LGPL - 3.0 - or -later
|
2022-04-08 09:35:33 -04:00
|
|
|
Copyright © 2022 Concordia CERC group
|
|
|
|
Project Coder Guille Gutierrez guillermo.gutierrezmorote@concordia.ca
|
|
|
|
Code contributors: Pilar Monsalvete Alvarez de Uribarri pilar.monsalvete@concordia.ca
|
2021-08-26 13:27:43 -04:00
|
|
|
"""
|
|
|
|
|
|
|
|
|
2021-04-13 14:12:45 -04:00
|
|
|
class Location:
|
2021-08-26 13:27:43 -04:00
|
|
|
"""
|
|
|
|
Location
|
|
|
|
"""
|
2023-06-06 13:32:37 -04:00
|
|
|
def __init__(self, country, city, region_code):
|
2021-04-13 14:12:45 -04:00
|
|
|
self._country = country
|
|
|
|
self._city = city
|
2023-06-06 13:32:37 -04:00
|
|
|
self._region_code = region_code
|
2021-04-13 14:12:45 -04:00
|
|
|
|
|
|
|
@property
|
|
|
|
def city(self):
|
2021-08-26 13:27:43 -04:00
|
|
|
"""
|
2023-06-06 13:32:37 -04:00
|
|
|
Get city name
|
2021-08-26 13:27:43 -04:00
|
|
|
"""
|
2021-04-13 14:12:45 -04:00
|
|
|
return self._city
|
|
|
|
|
|
|
|
@property
|
|
|
|
def country(self):
|
2021-08-26 13:27:43 -04:00
|
|
|
"""
|
2023-06-06 13:32:37 -04:00
|
|
|
Get country code
|
2021-08-26 13:27:43 -04:00
|
|
|
"""
|
|
|
|
return self._country
|
2023-06-06 13:32:37 -04:00
|
|
|
|
|
|
|
@property
|
|
|
|
def region_code(self):
|
|
|
|
"""
|
|
|
|
Get region
|
|
|
|
"""
|
|
|
|
return self._region_code
|