pytuflow.TCF.tscf

Contents

pytuflow.TCF.tscf#

TCF.tscf(context=None)#

Returns the TSCF ControlFile instance.

If more than one TSCF control file instance exists, a Context object must be provided to resolve to the correct TSCF.

Parameters:

context (Context, optional) – A context object to resolve the correct TSCF control file instance. Not required unless more than one TSCF control file instance exists.

Returns:

The TSCF control file instance.

Return type:

TSCF

Raises:
  • KeyError – If the SWMM Control File is not found in the control file.

  • ValueError – If more than one SWMM Control File is found and no context is provided to resolve the correct, or if the context does not resolve into a single SWMM Control File.

Example

>>> tcf = ... # assuming is an instance of TCF
>>> tscf = tcf.tscf()