plaza_routing.integration package

Submodules

plaza_routing.integration.geocoding_service module

plaza_routing.integration.geocoding_service.geocode(address)[source]
Return type:tuple

plaza_routing.integration.overpass_service module

plaza_routing.integration.overpass_service.get_connection_coordinates(lookup_position, start_uic_ref, exit_uic_ref, line, fallback_start_position, fallback_exit_position)[source]

Retrieves the start public transport stop position (longitude, latitude) for a specific uic_ref (start_uic_ref) and the corresponding exit node in the connection based on the exit_uic_ref. Both will be returned as tuple.

OSM returns multiple public transport stops for a given uic_ref. We’ll have to retrieve the right start and exit node based on the ordering of the nodes (with ref start_uic_ref or exit_uic_ref) in the relation (ex. bus lines) that serves the start stop. If the node with ref exit_uic_ref comes after the node with ref start_uic_ref in the relation, we’ve got the public transport stop in the right direction of travel.

Returns the fallback_start_position and fallback_exit_position if all retrieval options from Overpass fail.

Return type:Tuple[tuple, tuple]
plaza_routing.integration.overpass_service.get_public_transport_stops(start_position)[source]

retrieves all public transport stops for a specific location in a given range

Return type:dict

plaza_routing.integration.routing_engine_service module

class plaza_routing.integration.routing_engine_service.RoutingEngine(strategy)[source]

Bases: object

route(start, destination)[source]

plaza_routing.integration.search_ch_service module

plaza_routing.integration.search_ch_service.get_connection(start, destination, time, date='today')[source]

retrieves the connection for a given start, destination and time of departure

Return type:dict

Module contents