Per-cell 2D infiltration: value types, tag/override resolution and method↔parameter masks. More...
#include <QByteArray>#include <QHash>#include <QString>#include <QStringList>#include <QVector>#include <QtGlobal>#include <QtNumeric>Go to the source code of this file.
Classes | |
| struct | mesh::InfilRow |
| One infiltration specification: method + positional parameters + destination. More... | |
| struct | mesh::InfilDefaultRow |
One [2D_INFILTRATION_DEFAULTS] row. More... | |
| struct | mesh::InfilOptions |
[2D_INFILTRATION_OPTIONS]. More... | |
| struct | mesh::ResolvedInfil |
| Result of resolving one triangle's infiltration. More... | |
| struct | mesh::InfilLookupEntry |
| One row of a classified lookup: a key (or key pair, for the Curve-Number landuse×HSG case) mapping to a full InfilRow. More... | |
| struct | mesh::InfilLookupTable |
| An editable, reusable classified lookup table. More... | |
Namespaces | |
| namespace | mesh |
The Qt-facing MeshKit API (meshkit::core_qt, meshkit::model_qt, meshkit::io_qt): mesh value types and cell attributes, the mesh generator, quad regions, matching and cleanup, mesh statistics, and the INP and 2DM mesh codecs. | |
Enumerations | |
| enum class | mesh::InfilMethod : int { mesh::None = -1 , mesh::Horton = 0 , mesh::ModHorton = 1 , mesh::GreenAmpt = 2 , mesh::ModGreenAmpt = 3 , mesh::CurveNumber = 4 , mesh::Constant = 5 } |
| Infiltration method. More... | |
| enum class | mesh::InfilDest : int { mesh::Lost = 0 , mesh::SubcatchAquifer = 1 , mesh::Aquifer2D = 2 } |
Destination of infiltrated water (engine Infil2DDest). More... | |
| enum class | mesh::InfilProvenance : int { mesh::None = 0 , mesh::Star = 1 , mesh::Tag = 2 , mesh::Override = 3 } |
| Where a cell's resolved parameters came from — drives the muted/italic "inherited" rendering in the attribute table and property panels, and is what undo must restore (GUI plan §3.5(3)). More... | |
Functions | |
| ResolvedInfil | mesh::resolveInfil (const MeshResult &mesh, int tri) |
| Resolve an owned infiltration specification while preserving its authoring provenance. | |
| InfilRow | mesh::starDefault (const MeshResult &mesh) |
| Copy the first wildcard infiltration default, if present. | |
| int | mesh::indexOfDefault (const MeshResult &mesh, const QString &tag) |
| Find the first exact case-sensitive default tag match. | |
| bool | mesh::infilUsesParam (InfilMethod method, int slot) |
| Check whether a model uses a zero-based positional parameter slot. | |
| int | mesh::infilParamCount (InfilMethod method) |
| Report serialized parameter-column width rather than number of active values. | |
| QString | mesh::infilParamLabel (InfilMethod method, int slot) |
| Translate the model-specific label for an active positional parameter. | |
| QByteArray | mesh::infilParamKey (InfilMethod method, int slot) |
| Map an active model slot to its case-sensitive shared registry key. | |
| int | mesh::infilSlotForKey (InfilMethod method, const QByteArray &key) |
| Resolve a named parameter key to its position under one model. | |
| const QVector< QByteArray > & | mesh::infilParamKeys () |
| Return the immutable union of named infiltration parameter keys in registration order. | |
| QString | mesh::infilMethodToken (InfilMethod m) |
| Encode an infiltration method using the stable uppercase file vocabulary. | |
| InfilMethod | mesh::infilMethodFromToken (const QString &token, bool *ok=nullptr) |
| Parse a trimmed case-insensitive infiltration method token. | |
| QString | mesh::infilMethodLabel (InfilMethod m) |
| Translate a display label for an infiltration method. | |
| QStringList | mesh::infilMethodLabels () |
| Build translated method labels in consecutive enum order from None through Constant. | |
| QString | mesh::infilDestToken (InfilDest d) |
| Encode a destination enum as its retained uppercase file token. | |
| InfilDest | mesh::infilDestFromToken (const QString &token, bool *ok=nullptr) |
| Parse a retained destination token independently of current engine support. | |
| QString | mesh::infilDestLabel (InfilDest d) |
| Translate the display label of a retained destination value. | |
| QStringList | mesh::infilDestLabels () |
| Build translated destination labels in enum order Lost, SubcatchAquifer, Aquifer2D. | |
| QString | mesh::infilDestHint (InfilDest d) |
| Translate destination guidance without resolving any open model. | |
| bool | mesh::saveLookupTableCsv (const InfilLookupTable &table, const QString &path, QString *err) |
| Serialize classified infiltration entries and optional fallback to a QSaveFile CSV replacement. | |
| bool | mesh::loadLookupTableCsv (InfilLookupTable *table, const QString &path, QString *err) |
| Load the permissive unquoted classified-lookup CSV format into a fresh table value. | |
Variables | |
| constexpr int | mesh::kInfilMaxParams = 5 |
| Widest positional parameter count (Horton: f0 fmin decay dry_time Fmax). | |
Per-cell 2D infiltration: value types, tag/override resolution and method↔parameter masks.
Implements workplans/INTEGRATED2D_GW_GUI_PLAN_2026-08-15.md §3.2a (phase GG0). Mirrors the engine contract in openswmm.engine/src/engine/2d/infil/Infil2D.hpp — the two MUST agree on method tokens, positional parameter order, destination tokens and resolution precedence, because they read and write the same [2D_INFILTRATION*] sections.
Key invariants:
. The GUI never flattens tag inheritance into per-cell rows.**Units (user decision 2026-08-20):** parameters are in PROJECT units — the same numbers a user types into[INFILTRATION]`. The GUI stores and displays them verbatim and performs no conversion.