GeometryServiceNetworkWriterSettings

GeometryServiceNetworkWriterSettings instance

The GeometryServiceNetworkWriterSettings instance is accessible via the GeometryIntermodalWriter its [.settings](../geometryintermodalwriter/gimcw_settings property. It allows the user to configure the service network related output.

Note that service legs carry no directional information whereas the service leg segments do

Minimum configuration requirements

All methods marked as Compulsory=YES in the Methods section are expected to be configured by the user explicitly.

Methods

A GeometryServiceNetworkWriterSettings instance exposes the following methods.

Name Compulsory Default Description
.set_output_directory(+) YES N/A Set the output directory to persist the output files to
.set_country(+) NO Context dependent Set the country the service network resides in, used to determine the coordinate reference system to apply
.set_persist_service_legs(+) NO True Set flag indicating whether to persist each service leg connecting two service nodes or not
.set_service_legs_file_name(+) NO planit_service_legs Set file name (without path or extension) to use for service legs’ persistence
.set_persist_service_nodes(+) NO True Set flag indicating whether to persist each service node or not
.set_service_nodes_file_name(+) NO planit_service_nodes Set file name (without path or extension) to use for service nodes’ persistence
.set_persist_service_leg_segments(+) NO True Set flag indicating whether to persist each service leg segment or not
.set_set_service_leg_segments_file_name(+) NO planit_service_legsegments Set file name (without path or extension) to use for service leg segment’ persistence

Getters exist for most basic setters as well, e.g., .is_persist_service_legs(), however these are not yet documented explicitly.

Example

from planit import *

planit = Planit()

# converter
converter = planit.converter_factory.create(ConverterType.INTERMODAL)

# PLANit reader
planit_reader = converter.create_reader(IntermodalReaderType.PLANIT, AUSTRALIA)
planit_reader.settings.set_input_directory(PLANIT_INPUT_PATH)

# GeoIo (GIS geometry shape) writer
geo_writer = converter.create_writer(IntermodalWriterType.SHAPE)
geo_writer.settings.service_network_settings.set_output_directory(OUTPUT_PATH)
geo_writer.settings.service_network_settings.set_country("Australia")

# perform conversion
converter.convert(planit_reader, geo_writer)

See also

GeometryServiceNetworkWriter geometry (GIS) service network writer class these settings reside on

Source code

Class GeometryServiceNetworkWriterSettingsWrapper in converterwrappers.py


.set_country(+)

GeometryServiceNetworkWriterSettings method

.set_output_directory(+)

GeometryServiceNetworkWriterSettings method

.set_persist_service_leg_segments(+)

GeometryServiceNetworkWriterSettings method

.set_persist_service_legs(+)

GeometryServiceNetworkWriterSettings method

.set_persist_service_nodes(+)

GeometryServiceNetworkWriterSettings method

.set_service_legs_file_name(+)

GeometryServiceNetworkWriterSettings method

.set_service_nodes_file_name(+)

GeometryServiceNetworkWriterSettings method

.set_set_service_leg_segments_file_name(+)

GeometryServiceNetworkWriterSettings method