added the belonging specific edges and nodes to origind-destination and traffic networks
This commit is contained in:
parent
7af71db19d
commit
41f79b189a
|
@ -4,7 +4,10 @@ SPDX - License - Identifier: LGPL - 3.0 - or -later
|
||||||
Copyright © 2020 Project Author Pilar Monsalvete Alvarez de Uribarri pilar.monsalvete@concordia.ca
|
Copyright © 2020 Project Author Pilar Monsalvete Alvarez de Uribarri pilar.monsalvete@concordia.ca
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
from typing import List
|
||||||
from city_model_structure.network import Network
|
from city_model_structure.network import Network
|
||||||
|
from city_model_structure.transport.origin_destination_edge import OriginDestinationEdge
|
||||||
|
from city_model_structure.transport.origin_destination_node import OriginDestinationNode
|
||||||
|
|
||||||
|
|
||||||
class OriginDestinationNetwork(Network):
|
class OriginDestinationNetwork(Network):
|
||||||
|
@ -22,3 +25,19 @@ class OriginDestinationNetwork(Network):
|
||||||
:return: str
|
:return: str
|
||||||
"""
|
"""
|
||||||
return self._type
|
return self._type
|
||||||
|
|
||||||
|
@property
|
||||||
|
def edges(self) -> List[OriginDestinationEdge]:
|
||||||
|
"""
|
||||||
|
Get network edges
|
||||||
|
:return: [OriginDestinationEdge]
|
||||||
|
"""
|
||||||
|
return self._edges
|
||||||
|
|
||||||
|
@property
|
||||||
|
def nodes(self) -> List[OriginDestinationNode]:
|
||||||
|
"""
|
||||||
|
Get network nodes
|
||||||
|
:return: [OriginDestinationNode]
|
||||||
|
"""
|
||||||
|
return self._nodes
|
||||||
|
|
|
@ -6,7 +6,10 @@ Contributor Milad milad.aghamohamadnia@concordia.ca
|
||||||
Contributor Guille guille.gutierrezmorote@concordia.ca
|
Contributor Guille guille.gutierrezmorote@concordia.ca
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
from typing import List
|
||||||
from city_model_structure.network import Network
|
from city_model_structure.network import Network
|
||||||
|
from city_model_structure.transport.traffic_edge import TrafficEdge
|
||||||
|
from city_model_structure.transport.traffic_node import TrafficNode
|
||||||
|
|
||||||
|
|
||||||
class TrafficNetwork(Network):
|
class TrafficNetwork(Network):
|
||||||
|
@ -24,3 +27,19 @@ class TrafficNetwork(Network):
|
||||||
:return: str
|
:return: str
|
||||||
"""
|
"""
|
||||||
return self._type
|
return self._type
|
||||||
|
|
||||||
|
@property
|
||||||
|
def edges(self) -> List[TrafficEdge]:
|
||||||
|
"""
|
||||||
|
Get network edges
|
||||||
|
:return: [TrafficEdge]
|
||||||
|
"""
|
||||||
|
return self._edges
|
||||||
|
|
||||||
|
@property
|
||||||
|
def nodes(self) -> List[TrafficNode]:
|
||||||
|
"""
|
||||||
|
Get network nodes
|
||||||
|
:return: [TrafficNode]
|
||||||
|
"""
|
||||||
|
return self._nodes
|
||||||
|
|
Loading…
Reference in New Issue
Block a user