![]() |
OpenSWMM Engine
6.0.0-alpha.4
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.4)
|
Write profile: which engine the file is written for. More...
#include <InpWriter.hpp>
Public Types | |
| enum class | Profile { Full , Swmm5 , Swmm5Stock } |
| enum class | OutputKind { Model = 0 , Mesh = 1 , Component = 2 } |
Public Attributes | |
| Profile | profile = Profile::Full |
| FILE * | stream = nullptr |
| bool | internal_units = false |
| bool | inline_mesh = false |
| bool | skip_component_files = false |
| std::function< std::string(const std::string &, OutputKind)> | map_output |
Write profile: which engine the file is written for.
Full is the native format. Swmm5 writes a file a SWMM 5.x engine can read (MULTI_ENGINE plan V2 Phase 4): the v6-only sections are omitted ([2D_*], [PLUGINS], [PROCESS_COMPONENTS], [USER_FLAGS], [USER_FLAG_VALUES], [RDII_DECAY]), v6-only option keys are omitted and incompatible values mapped (FLOW_ROUTING FV → DYNWAVE, SURCHARGE_METHOD DYNAMIC_SLOT/TPA → SLOT), a virtual junction becomes an ordinary junction, and an inlet junction becomes an ordinary junction plus an [INLET_USAGE] row on its approach conduit with the same capture node (the legacy-equivalent model). Every substitution is reported through warnings; the file starts with a comment naming the profile.
Swmm5Stock is Swmm5 for a STOCK EPA SWMM 5 engine (5.2.4 as built for SWMMVis): it additionally drops the positional grammar extensions the in-tree legacy 5.3.0 engine added — the [SUBCATCHMENTS] Snowpack * placeholder with the RainScale / SnowScale columns behind it, and the [RAINGAGES] scale-factor column — which a stock parser reads as an object name or a malformed row (ERROR 209 / 200). A dropped factor that is not 1.0 is reported through warnings, since it is real model content.
|
strong |
|
strong |
| bool openswmm::inp_writer::InpWriteOptions::inline_mesh = false |
| bool openswmm::inp_writer::InpWriteOptions::internal_units = false |
| std::function<std::string(const std::string&, OutputKind)> openswmm::inp_writer::InpWriteOptions::map_output |
| Profile openswmm::inp_writer::InpWriteOptions::profile = Profile::Full |
| bool openswmm::inp_writer::InpWriteOptions::skip_component_files = false |
| FILE* openswmm::inp_writer::InpWriteOptions::stream = nullptr |