.set_length_units(+)

TntpNetworkReaderSettings method

Description

Set the length units to expect from the TNTP inputs. These are defined in the custom TNTP LengthUnits enum.

Signature

.set_length_units(length_unit: LengthUnits)

with

Parameter Type Unit Default Description
length_unit LengthUnits N/A KM The length unit

Return type

N/A

Example 1

from planit import *

# create a network converter
planit_instance = Planit()
network_converter = planit_instance.converter_factory.create(ConverterType.NETWORK)

# TNTP network reader        
reader = network_converter.create_reader(NetworkReaderType.TNTP)
reader.settings.set_length_units(LengthUnits.MILES)

See also

N/A

Source code

Class TntpNetworkReaderSettingsWrapper in converterwrappers.py