.has_overwritten_gtfs_stop_to_link_mapping(+)
GtfsZoningReaderSettings method
Description
Use this method to check whether a force override of the mapping between a GTFS stop and its link exists.
Signature
.has_overwritten_gtfs_stop_to_link_mapping(gtfs_stop_id: str) -> bool
Return type
bool
Example 1
from planit import *
# create an intermodal converter
planit_instance = Planit()
intermodal_converter = planit_instance.converter_factory.create(ConverterType.INTERMODAL)
from planit import *
# create an intermodal converter
planit_instance = Planit()
intermodal_converter = planit_instance.converter_factory.create(ConverterType.INTERMODAL)
# <some_intermodal_reader> = construct OSM or PLANit intermodal reader for example
# GTFS reader
gtfs_reader: GtfsIntermodalReaderWrapper = \
intermodal_converter.create_reader(IntermodalReaderType.GTFS, "Australia", <some_intermodal_reader>)
## override mapping explicitly ##
gtfs_reader.settings.zoning_settings.overwrite_gtfs_stop_to_link_mapping(
"gtfs_Stop_id_1", "osm_way_id", IdMapperType.EXTERNAL)
assert gtfs_reader.settings.zoning_settings.has_overwritten_gtfs_stop_to_link_mapping("gtfs_Stop_id_1") is True
See also
N/A
Source code
Class GtfsZoningReaderSettingsWrapper
in converterwrappers.py