.set_input_directory(+)

PlanitDemandsReaderSettings method

Description

Set the input directory to use by the PlanitDemandsReader. This is a mandatory setting the user is expected to set. The reader will then look through the available files, and use the first suitable file that is compatible with the native demands XML format.

Signature

.set_input_directory(input_dir:str)

with

Parameter Type Unit Default Description
input_dir String None N/A The input directory to extract the demands from

Return type

N/A

Example 1

from planit import *

# create a demands converter
planit_instance = Planit()
converter = planit_instance.converter_factory.create(ConverterType.DEMANDS)

# Planit XML network reader        
planit_reader = converter.create_reader(DemandsReaderType.PLANIT)
planit_reader.settings.set_input_directory("<dir_to_input_file>")

See also

N/A

Source code

Class ReaderSettingsWrapper in converterwrappers.py