SWMMVis  6.0.0-alpha.4
Qt6/C++ GIS-based graphical user interface for the SWMMVis engine (6.0.0-alpha.4)
Loading...
Searching...
No Matches
inletprovider.h File Reference

MVC model for a single SWMM inlet design ([INLETS]). More...

#include <QObject>
#include <QString>
Include dependency graph for inletprovider.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  openswmmvis::inlet::InletDesignData
 Every parameter of one inlet design, mirroring SWMM_InletDesign. Snapshot type for the undo commands and the engine round-trip. More...
 
class  openswmmvis::inlet::InletProvider
 

Namespaces

namespace  openswmmvis
 
namespace  openswmmvis::inlet
 

Enumerations

enum class  openswmmvis::inlet::InletType {
  openswmmvis::inlet::Grate = 0 ,
  openswmmvis::inlet::Curb = 1 ,
  openswmmvis::inlet::Combo = 2 ,
  openswmmvis::inlet::Slotted = 3 ,
  openswmmvis::inlet::DropGrate = 4 ,
  openswmmvis::inlet::DropCurb = 5 ,
  openswmmvis::inlet::Custom = 6
}
 Inlet design type. Values match SWMM_InletType. More...
 
enum class  openswmmvis::inlet::GrateType {
  openswmmvis::inlet::PBar50 = 0 ,
  openswmmvis::inlet::PBar50x100 = 1 ,
  openswmmvis::inlet::PBar30 = 2 ,
  openswmmvis::inlet::CurvedVane = 3 ,
  openswmmvis::inlet::TiltBar45 = 4 ,
  openswmmvis::inlet::TiltBar30 = 5 ,
  openswmmvis::inlet::Reticuline = 6 ,
  openswmmvis::inlet::Generic = 7
}
 Grate bar pattern (HEC-22). Values match SWMM_GrateType. More...
 
enum class  openswmmvis::inlet::ThroatType {
  openswmmvis::inlet::Horizontal = 0 ,
  openswmmvis::inlet::Inclined = 1 ,
  openswmmvis::inlet::Vertical = 2
}
 Curb-opening throat orientation. Values match SWMM_ThroatType. More...
 
enum class  openswmmvis::inlet::InletCurveKind {
  openswmmvis::inlet::None = 0 ,
  openswmmvis::inlet::Diversion = 1 ,
  openswmmvis::inlet::Rating = 2
}
 Custom-inlet capture-curve flavour. Values match SWMM_InletCurveKind. More...
 

Functions

bool openswmmvis::inlet::operator== (const InletDesignData &a, const InletDesignData &b)
 Field-by-field equality — used by setDesign to suppress no-op notifications and by the undo commands to skip empty pushes.
 
bool openswmmvis::inlet::operator!= (const InletDesignData &a, const InletDesignData &b)
 
QString openswmmvis::inlet::inletTypeLabel (InletType t)
 Legacy editor label for a type ("GRATE", "CURB OPENING", "COMBINATION", "SLOTTED DRAIN", "DROP GRATE", "DROP CURB", "CUSTOM"). These are the strings the type combo shows (Uinlet.pas:31-44).
 
const char * openswmmvis::inlet::inletTypeKeyword (InletType t)
 [INLETS] type keyword handed to swmm_inlet_add. A COMBINATION design is created as a GRATE and then promoted by swmm_inlet_set_design, which is the authority on the stored type.
 
QString openswmmvis::inlet::grateTypeLabel (GrateType t)
 HEC-22 grate name ("P_BAR-50", "CURVED_VANE", "GENERIC", …).
 

Detailed Description

MVC model for a single SWMM inlet design ([INLETS]).

Author
Caleb Buahin caleb.nosp@m..bua.nosp@m.hin@g.nosp@m.mail.nosp@m..com
Date
2026
License\n GPL-3.0-or-later

One InletProvider per [INLETS] entry. Owned by a project-scoped InletRegistry. Engine I/O walks the full-design surface of openswmm_infrastructure.h — swmm_inlet_get_design / swmm_inlet_set_design plus swmm_inlet_get_comment / swmm_inlet_set_comment — so every field of the [INLETS] grammar (curb height, throat angle, combination inlets, custom capture curves) round-trips.

The provider is the single source of truth for one design: the editor's list, property tree and drawing view all subscribe to its signals. InletDesignData mirrors SWMM_InletDesign field-for-field so a snapshot can be taken for undo (see inletundocommands.h) and pushed to the engine without an intermediate translation table.