OpenSWMM Engine  6.0.0-alpha.1
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.1)
Loading...
Searching...
No Matches
SpatialHandler.cpp File Reference

Section handlers for [MAP], [VERTICES], [POLYGONS], [SYMBOLS]. More...

#include "SpatialHandler.hpp"
#include "../Tokenizer.hpp"
#include "../../core/SimulationContext.hpp"
#include "../InputParseUtils.hpp"
#include <algorithm>
Include dependency graph for SpatialHandler.cpp:

Namespaces

namespace  openswmm
 
namespace  openswmm::input
 

Functions

void openswmm::input::handle_map (SimulationContext &ctx, const std::vector< std::string > &lines)
 Parse [MAP] — fills spatial.map_x1/y1/x2/y2 and map_units.
 
void openswmm::input::handle_vertices (SimulationContext &ctx, const std::vector< std::string > &lines)
 Parse [VERTICES] — fills spatial.link_vertices_x/y.
 
void openswmm::input::handle_polygons (SimulationContext &ctx, const std::vector< std::string > &lines)
 Parse [POLYGONS] — fills spatial.subcatch_polygon_x/y.
 
void openswmm::input::handle_symbols (SimulationContext &ctx, const std::vector< std::string > &lines)
 Parse [SYMBOLS] — fills spatial.gage_x/y.
 
void openswmm::input::handle_tags (SimulationContext &ctx, const std::vector< std::string > &lines)
 Parse [TAGS] — writes per-index tags onto ctx.nodes.tags / ctx.links.tags / ctx.subcatches.tags (resolves name → idx via the matching NameIndex; unresolved lines are skipped).
 

Detailed Description

Section handlers for [MAP], [VERTICES], [POLYGONS], [SYMBOLS].

[MAP] format

[MAP]
DIMENSIONS x1 y1 x2 y2
UNITS NONE
@ NONE
None option.
Definition enums.h:1220

[VERTICES] format

;; Link X Y
C1 2735.503 6483.508
C1 2174.216 6351.033
@ Y
Definition culvert.c:28
EXTERN TLink * Link
Definition globals.h:158

[POLYGONS] format

;; Subcatchment X Y
S1 2174.216 8125.000
S1 2482.570 8125.000

[SYMBOLS] format

;; Gage X Y
RG1 1000.000 5000.000
EXTERN TGage * Gage
Definition globals.h:150
See also
SpatialHandler.hpp
Author
Caleb Buahin caleb.nosp@m..bua.nosp@m.hin@g.nosp@m.mail.nosp@m..com
License\n MIT License