.set_output_directory(+)

PlanitRoutedServicesWriterSettings method

Description

Set an output directory to use for the zoning output file to be persisted in.

This setting is expected to be explicitly set by the user, only if it is not set on the parent settings of the PlanitIntermodalWriterSettings, otherwise the writer will fail.

Signature

.set_output_directory(output_dir: str)

with

Parameter Type Unit Default Description
output_dir str None N/A The output directory to use

Return type

N/A

Example 1 - minimum configuration

from planit import *

# create an intermodal converter
planit_instance = Planit()
intermodal_converter = planit_instance.converter_factory.create(ConverterType.INTERMODAL)

# Open Street Map (OSM) intermodal reader        
osm_reader = intermodal_converter.create_reader(IntermodalReaderType.OSM, "<country_name>")
osm_reader.settings.set_input_file("<path_to_input_file>")

# PLANit intermodal writer
planit_writer = intermodal_converter.create_writer(IntermodalWriterType.PLANIT)
planit_writer.settings.set_output_directory("<path_to_output_dir>")

# configure routed services specific aspects of PLANit intermodal writer
planit_writer.settings.routed_services_settings.set_output_directory("<my_different_routed_services_dir>")

# perform conversion
intermodal_converter.convert(osm_reader,planit_writer)

See also

N/A

Source code

Class WriterSettingsWrapper in converterwrappers.py