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
swmmnodepropertyadapter.h
Go to the documentation of this file.
1
21#ifndef SWMMNODEPROPERTYADAPTER_H
22#define SWMMNODEPROPERTYADAPTER_H
23
24#include <QObject>
25#include <QString>
26#include <QUuid> // Slice QA.2 — stats-source identity
27
28#include <functional> // writeInletUsage() mutator
29
30#include <openswmm/engine/openswmm_engine.h>
31#include <openswmm/engine/openswmm_infrastructure.h> // SWMM_InletUsage
32
37
38class SWMMModelLayer;
39namespace openswmmvis { class OutputStatsRegistry; } // Slice QA.2
40
51class SWMMNodePropertyAdapter : public QObject
52{
53 Q_OBJECT
54
55public:
67 enum NodeKind { Junction = 0, Outfall = 1, Storage = 2, Divider = 3,
69 enum OutfallType { FREE = 0, NORMAL = 1, FIXED = 2, TIDAL = 3, TIMESERIES = 4 };
70 enum DividerType { CUTOFF = 0, OVERFLOW_ = 1, TABULAR = 2, WEIR = 3 };
71 enum FlapGate { NO = 0, YES = 1 };
74 enum InletPlacement { AUTOMATIC = 0, ON_GRADE = 1, ON_SAG = 2 };
94 Q_ENUM(NodeKind)
95 Q_ENUM(OutfallType)
96 Q_ENUM(DividerType)
97 Q_ENUM(FlapGate)
98 Q_ENUM(StorageShape)
99 Q_ENUM(InletPlacement)
100
101 // Common to every node type — Name + Type + Invert + Coords + Tag.
102 Q_PROPERTY(QString name READ name WRITE setName)
103 Q_PROPERTY(NodeKind nodeKind READ nodeKind)
104 Q_PROPERTY(double invertElev READ invertElev WRITE setInvertElev NOTIFY changed)
107 Q_PROPERTY(QString tag READ tag WRITE setTag NOTIFY changed)
108 // Slice DB — coordinates editable. Writes go through `coordChangeRequested`
109 // so the bound layer can route them via `applyNodeMove`, which refreshes
110 // the cached scene coords + attached-link bboxes (a raw engine setter
111 // would leave the canvas stale until the next full rebuild).
112 Q_PROPERTY(double xCoord READ xCoord WRITE setXCoord NOTIFY changed)
113 Q_PROPERTY(double yCoord READ yCoord WRITE setYCoord NOTIFY changed)
114
118 QObject *parent = nullptr);
119
122 void setModelLayer(SWMMModelLayer *layer) { m_layer = layer; }
123 [[nodiscard]] SWMMModelLayer *modelLayer() const { return m_layer; }
124
125 [[nodiscard]] QString name() const { return m_name; }
126 [[nodiscard]] NodeKind nodeKind() const;
127
128 [[nodiscard]] QString tag() const;
129 [[nodiscard]] double invertElev() const;
130 [[nodiscard]] double maxDepth() const;
135 [[nodiscard]] double rimDepth() const;
136 [[nodiscard]] double initialDepth() const;
137 [[nodiscard]] double surchargeDepth() const;
138 [[nodiscard]] double pondedArea() const;
139 [[nodiscard]] double seepRate() const;
140 [[nodiscard]] double xCoord() const;
141 [[nodiscard]] double yCoord() const;
142 [[nodiscard]] OutfallType outfallType() const;
143 [[nodiscard]] FlapGate outfallFlapGate() const;
144 [[nodiscard]] DividerType dividerType() const;
145
146 // Slice DB — read-only computed + statistics summary getters.
147 // `crownElev` / `fullVolume` / `degree` are populated at input time
148 // (computed when links connect at load). The four `stat*` values
149 // are populated only after a simulation run; pre-run they read back
150 // as zero. Exposed via Q_PROPERTY without WRITE so QPropertyModel
151 // renders them as non-editable rows.
152 [[nodiscard]] double crownElev() const;
153 [[nodiscard]] double fullVolume() const;
154 [[nodiscard]] int degree() const;
155 [[nodiscard]] double statMaxDepth() const;
156 [[nodiscard]] double statMaxOverflow() const;
157 [[nodiscard]] double statVolFlooded() const;
158 [[nodiscard]] double statTimeFlooded() const;
159
160 // Slice DB.2 — compound-attribute refs. Each returns a value that
161 // the registered `NodeCompoundEditButton` editor creator picks up
162 // via the custom metatype dispatch; clicking the cell opens the
163 // matching page of `NodeCompoundEditDialog`. The `summary` field
164 // is computed live from the engine count so the cell shows a
165 // useful preview even before the user opens the dialog.
166 [[nodiscard]] NodeCompoundEditRef inflowsRef() const;
167 [[nodiscard]] NodeCompoundEditRef dwfRef() const;
168 [[nodiscard]] NodeCompoundEditRef rdiiRef() const;
169 [[nodiscard]] NodeCompoundEditRef treatmentRef() const;
170
175 [[nodiscard]] NodeCompoundEditRef groundwaterSourcesRef() const;
176
182 [[nodiscard]] UserFlagsEditRef userFlagsRef() const;
183
187 [[nodiscard]] InitialQualityEditRef initialQualityRef() const;
188
189 // Slice DA.4.3 — outfall stage-data accessors. Live on the base class
190 // (rather than only on the outfall subclass) so the cpp can use the
191 // same `nodeIdx() / m_engine` helpers as every other accessor. Only
192 // the outfall subclass declares them as Q_PROPERTY, so QPropertyModel
193 // only shows the rows on outfall nodes.
194 //
195 // The engine stores stage / tidal-curve-idx / timeseries-idx in a
196 // shared union `outfall_param` slot, so switching outfall type is
197 // destructive of the prior-type's assignment — getters return 0 /
198 // empty when the current outfall type doesn't match what the property
199 // means. PropertiesPanel greys out the inapplicable rows via
200 // `setRowEditable` to reinforce this visually.
201 [[nodiscard]] double outfallStage() const;
202 [[nodiscard]] DataObjectRef outfallTidalCurveRef() const;
203 [[nodiscard]] DataObjectRef outfallTimeseriesRef() const;
204
205 // Slice AG.4 — storage-unit geometry accessors. Live on the base class
206 // (like the outfall stage-data accessors above) so the cpp can reuse the
207 // shared `nodeIdx() / m_engine` helpers; only SWMMStoragePropertyAdapter
208 // declares them as Q_PROPERTY.
209 //
210 // `storageShape()` now reads the engine's real shape field
211 // (`swmm_node_get_storage_shape`) rather than inferring TABULAR from
212 // `curve_idx >= 0` — that inference could not represent the four geometric
213 // shapes, which are curve-less but are not power-law functional either.
214 //
215 // Which of the parameter accessors is meaningful depends on the shape:
216 // Tabular → storageCurveRef()
217 // Functional → storageCoeffA/ExpB/ConstC() (A·d^B + C)
218 // geometric shapes → storageParam1/2/3() (raw L/W/Z)
219 // The panel greys the inapplicable rows; see storageshapegeom.h.
220 // Inlet-junction accessors (INLET_EDITOR_AND_INLET_JUNCTION_GUI_PLAN
221 // §3.4). Like the outfall / storage blocks they live on the base class so
222 // the cpp reuses nodeIdx() / m_engine; only
223 // SWMMInletJunctionPropertyAdapter declares them as Q_PROPERTY.
224 //
225 // All of them read and write ONE engine row — the node's SWMM_InletUsage
226 // (host_kind = SWMM_INLET_HOST_NODE). Every setter is a read-modify-write
227 // of that row pushed as a SetInletUsageCommand through the model layer, so
228 // each edit is one undo step and every view refreshes from attributeChanged.
229 // Without a bound layer the setters are no-ops (the command needs one).
230 [[nodiscard]] DataObjectRef inletDesignRef() const;
231 [[nodiscard]] DataObjectRef captureNodeRef() const;
232 [[nodiscard]] int numInlets() const;
233 [[nodiscard]] double pctClogged() const;
234 [[nodiscard]] double flowRestriction() const;
235 [[nodiscard]] double depressionHeight() const;
236 [[nodiscard]] double depressionWidth() const;
237 [[nodiscard]] InletPlacement placement() const;
240 [[nodiscard]] QString approachStreet() const;
241
242 [[nodiscard]] StorageShape storageShape() const;
243 [[nodiscard]] DataObjectRef storageCurveRef() const;
244 [[nodiscard]] double storageCoeffA() const;
245 [[nodiscard]] double storageExpB() const;
246 [[nodiscard]] double storageConstC() const;
247 [[nodiscard]] double storageParam1() const;
248 [[nodiscard]] double storageParam2() const;
249 [[nodiscard]] double storageParam3() const;
250
258 Q_INVOKABLE QString displayLabelFor(const QString &property) const;
259
260public slots:
261 void setName(const QString &newName);
262 void setTag(const QString &t);
263 void setInvertElev(double v);
264 void setMaxDepth(double v);
265 void setRimDepth(double v);
266 void setInitialDepth(double v);
267 void setSurchargeDepth(double v);
268 void setPondedArea(double v);
269 void setSeepRate(double v);
270 void setXCoord(double v);
271 void setYCoord(double v);
275
286 void setInflowsRef(const NodeCompoundEditRef &) { emit changed(); }
287 void setDwfRef(const NodeCompoundEditRef &) { emit changed(); }
288 void setRdiiRef(const NodeCompoundEditRef &) { emit changed(); }
291 void setUserFlagsRef(const UserFlagsEditRef &) { emit changed(); }
293
294 // Slice DA.4.3 — outfall stage-data setters. Each calls the matching
295 // swmm_node_set_outfall_* engine setter, which also flips the outfall
296 // type to the matching kind (FIXED / TIDAL / TIMESERIES) — that's a
297 // deliberate engine invariant. So calling setOutfallStage()
298 // implicitly switches the outfall to FIXED. The setRowEditable
299 // wiring in PropertiesPanel re-runs on every `changed()` and updates
300 // which row is enabled accordingly.
301 void setOutfallStage(double v);
304
305 // Slice AG.4 — storage geometry setters.
306 // setStorageShape(Functional) detaches any tabular curve so the engine
307 // falls back to the functional coefficients.
308 // setStorageShape(Tabular) keeps the current curve if one is assigned,
309 // else assigns the first [STORAGE]-type curve in the model; if none
310 // exist it is a no-op (the row stays FUNCTIONAL after re-read).
311 // The coefficient setters read-modify-write the engine's atomic (A,B,C)
312 // triple so each row edits one term without clobbering the others.
313 // setStorageShape(<geometric>) detaches any curve (engine-side) and
314 // re-derives the area coefficients from the node's current L/W/Z.
315 // The param setters read-modify-write the engine's atomic (p1,p2,p3)
316 // triple, same as the coefficient setters do for (A,B,C). The engine
317 // rejects invalid dimensions (L<=0, W<=0, Z<0, or Z==0 on a paraboloid)
318 // and leaves the node on its previous geometry, so a bad keystroke
319 // cannot wedge the model.
320 // Inlet-junction setters — each is a read-modify-write of the node's one
321 // SWMM_InletUsage row pushed as a SetInletUsageCommand (see the getters).
322 void setInletDesignRef(const DataObjectRef &r);
323 void setCaptureNodeRef(const DataObjectRef &r);
324 void setNumInlets(int v);
325 void setPctClogged(double v);
326 void setFlowRestriction(double v);
327 void setDepressionHeight(double v);
328 void setDepressionWidth(double v);
330
332 void setStorageCurveRef(const DataObjectRef &r);
333 void setStorageCoeffA(double v);
334 void setStorageExpB(double v);
335 void setStorageConstC(double v);
336 void setStorageParam1(double v);
337 void setStorageParam2(double v);
338 void setStorageParam3(double v);
339
345 void refresh() { emit changed(); }
346
349 void updateStoredName(const QString &newName) { m_name = newName; }
350
351 // ------------------------------------------------------------------
352 // Slice QA.2 — stats-source dispatch
353 // ------------------------------------------------------------------
354 //
355 // The four `statMax*` getters dispatch on `m_statsSourceId`:
356 // - null UUID → today's behaviour (read from m_engine via
357 // swmm_node_get_stat_*, i.e. the editing-engine's
358 // ambient post-run stats).
359 // - non-null → look up the corresponding SWMMResultsLayer via
360 // m_statsRegistry and call its nodeStatMax*()
361 // accessor (returns 0 until engine API QA-01 lands
362 // — see swmmresultslayer.cpp QA.3 comment).
363 //
364 // setStatsRegistry is called once by PropertiesPanel when the adapter
365 // is first wired up; setStatsSource is called from the combo's
366 // currentIndexChanged slot every time the user picks a different
367 // source. Either may be called with nullptr / null UUID to revert
368 // to the editing-engine default.
370 void setStatsSource(const QUuid &id);
371 [[nodiscard]] QUuid statsSourceId() const { return m_statsSourceId; }
372
373signals:
374 void changed();
377 void renameRequested(const QString &oldName, const QString &newName);
386 void coordChangeRequested(double newX, double newY);
391
392protected:
393 [[nodiscard]] int nodeIdx() const;
394
401 void writeInletUsage(const std::function<bool(SWMM_InletUsage &)> &mutate);
402
404 QString m_name;
406
412};
413
419{
420 Q_OBJECT
421 Q_PROPERTY(double maxDepth READ maxDepth WRITE setMaxDepth NOTIFY changed)
422 Q_PROPERTY(double initialDepth READ initialDepth WRITE setInitialDepth NOTIFY changed)
423 Q_PROPERTY(double surchargeDepth READ surchargeDepth WRITE setSurchargeDepth NOTIFY changed)
424 Q_PROPERTY(double pondedArea READ pondedArea WRITE setPondedArea NOTIFY changed)
425 // Slice DB — read-only summary (no WRITE → QPropertyModel renders as
426 // non-editable). Computed by engine at link-insert / post-run time.
427 Q_PROPERTY(double crownElev READ crownElev NOTIFY changed)
428 Q_PROPERTY(double fullVolume READ fullVolume NOTIFY changed)
429 Q_PROPERTY(int degree READ degree NOTIFY changed)
430 Q_PROPERTY(double statMaxDepth READ statMaxDepth NOTIFY changed)
431 Q_PROPERTY(double statMaxOverflow READ statMaxOverflow NOTIFY changed)
432 Q_PROPERTY(double statVolFlooded READ statVolFlooded NOTIFY changed)
433 Q_PROPERTY(double statTimeFlooded READ statTimeFlooded NOTIFY changed)
434 // Slice DB.2 — compound-attribute "Edit…" buttons.
436 READ inflowsRef WRITE setInflowsRef NOTIFY changed)
438 READ dwfRef WRITE setDwfRef NOTIFY changed)
440 READ rdiiRef WRITE setRdiiRef NOTIFY changed)
442 READ treatmentRef WRITE setTreatmentRef NOTIFY changed)
448 READ userFlagsRef WRITE setUserFlagsRef NOTIFY changed)
449public:
451};
452
472{
473 Q_OBJECT
474 Q_PROPERTY(double rimDepth READ rimDepth WRITE setRimDepth NOTIFY changed)
475 Q_PROPERTY(double crownElev READ crownElev NOTIFY changed)
476 Q_PROPERTY(int degree READ degree NOTIFY changed)
477 Q_PROPERTY(double statMaxDepth READ statMaxDepth NOTIFY changed)
479 READ inflowsRef WRITE setInflowsRef NOTIFY changed)
481 READ dwfRef WRITE setDwfRef NOTIFY changed)
483 READ rdiiRef WRITE setRdiiRef NOTIFY changed)
485 READ treatmentRef WRITE setTreatmentRef NOTIFY changed)
489 READ userFlagsRef WRITE setUserFlagsRef NOTIFY changed)
490public:
492};
493
511{
512 Q_OBJECT
513 // rimDepth / crownElev / degree are INHERITED from the virtual-junction
514 // adapter and deliberately not redeclared: QPropertyModel builds its rows
515 // from the whole metaObject, so a redeclaration would render the row
516 // twice. rimDepth's inlet-specific label ("Street Max Depth") comes from
517 // displayLabelFor(), which branches on nodeKind().
518 Q_PROPERTY(DataObjectRef inletDesign
519 READ inletDesignRef WRITE setInletDesignRef NOTIFY changed)
520 Q_PROPERTY(DataObjectRef captureNode
521 READ captureNodeRef WRITE setCaptureNodeRef NOTIFY changed)
522 Q_PROPERTY(int numInlets READ numInlets WRITE setNumInlets NOTIFY changed)
523 Q_PROPERTY(double pctClogged READ pctClogged WRITE setPctClogged NOTIFY changed)
524 Q_PROPERTY(double flowRestriction READ flowRestriction WRITE setFlowRestriction NOTIFY changed)
526 Q_PROPERTY(double depressionWidth READ depressionWidth WRITE setDepressionWidth NOTIFY changed)
528 READ placement WRITE setPlacement NOTIFY changed)
529 // Read-only context (no WRITE → QPropertyModel renders non-editable).
530 Q_PROPERTY(QString approachStreet READ approachStreet NOTIFY changed)
531public:
536 QObject *parent = nullptr)
538};
539
544{
545 Q_OBJECT
546 // Enum properties on the derived class need the type spelled with
547 // its base-class scope so moc can resolve it without re-declaring
548 // Q_ENUM in every subclass.
550 READ outfallType WRITE setOutfallType NOTIFY changed)
551 // Slice DA.4.3 — stage-data per-type rows. PropertiesPanel toggles
552 // their `isEditable` flag based on the live `outfallType` so the
553 // user can only edit the row that matches the current type.
554 Q_PROPERTY(double outfallStage
555 READ outfallStage WRITE setOutfallStage NOTIFY changed)
556 Q_PROPERTY(DataObjectRef outfallTidalCurve
557 READ outfallTidalCurveRef WRITE setOutfallTidalCurveRef NOTIFY changed)
558 Q_PROPERTY(DataObjectRef outfallTimeseries
559 READ outfallTimeseriesRef WRITE setOutfallTimeseriesRef NOTIFY changed)
560 Q_PROPERTY(SWMMNodePropertyAdapter::FlapGate outfallFlapGate
561 READ outfallFlapGate WRITE setOutfallFlapGate NOTIFY changed)
562 // Slice DB — same read-only summary block as the other node kinds.
563 // Stat values are still meaningful at outfalls (max depth = stage,
564 // max overflow is always zero by definition but kept for parity).
565 Q_PROPERTY(double crownElev READ crownElev NOTIFY changed)
566 Q_PROPERTY(double fullVolume READ fullVolume NOTIFY changed)
567 Q_PROPERTY(int degree READ degree NOTIFY changed)
568 Q_PROPERTY(double statMaxDepth READ statMaxDepth NOTIFY changed)
569 Q_PROPERTY(double statMaxOverflow READ statMaxOverflow NOTIFY changed)
570 Q_PROPERTY(double statVolFlooded READ statVolFlooded NOTIFY changed)
571 Q_PROPERTY(double statTimeFlooded READ statTimeFlooded NOTIFY changed)
572 // Slice DB.2 — compound-attribute "Edit…" buttons. SWMM allows
573 // Inflows / DWF / Treatment at boundary nodes; RDII surfaced for
574 // parity though legacy SWMM-GUI grays it out for outfalls.
575 Q_PROPERTY(NodeCompoundEditRef inflows
576 READ inflowsRef WRITE setInflowsRef NOTIFY changed)
577 Q_PROPERTY(NodeCompoundEditRef dwf
578 READ dwfRef WRITE setDwfRef NOTIFY changed)
579 Q_PROPERTY(NodeCompoundEditRef rdii
580 READ rdiiRef WRITE setRdiiRef NOTIFY changed)
581 Q_PROPERTY(NodeCompoundEditRef treatment
582 READ treatmentRef WRITE setTreatmentRef NOTIFY changed)
583 Q_PROPERTY(NodeCompoundEditRef groundwaterSources
584 READ groundwaterSourcesRef WRITE setGroundwaterSourcesRef NOTIFY changed)
585 Q_PROPERTY(InitialQualityEditRef initialQuality
586 READ initialQualityRef WRITE setInitialQualityRef NOTIFY changed)
587 Q_PROPERTY(UserFlagsEditRef userFlags
588 READ userFlagsRef WRITE setUserFlagsRef NOTIFY changed)
589public:
591};
592
598{
599 Q_OBJECT
600 Q_PROPERTY(double maxDepth READ maxDepth WRITE setMaxDepth NOTIFY changed)
601 Q_PROPERTY(double initialDepth READ initialDepth WRITE setInitialDepth NOTIFY changed)
602 Q_PROPERTY(double surchargeDepth READ surchargeDepth WRITE setSurchargeDepth NOTIFY changed)
603 Q_PROPERTY(double seepRate READ seepRate WRITE setSeepRate NOTIFY changed)
604 // Slice AG.4 — storage geometry. The Shape combobox switches between a tabular
605 // depth–area curve, the functional power-law form, and the four geometric shapes.
606 // PropertiesPanel greys out the rows that don't apply to the live shape (curve vs.
607 // coefficients vs. dimensions), mirroring the outfall stage-data wiring.
608 //
609 // The three dimension rows keep GENERIC names (Param 1/2/3) because QPropertyModel
610 // reflects rows from metaObject() and cannot rename or hide them at runtime; the
611 // shape-specific meaning ("Major Axis Length", "Side Slope", …) is supplied as the
612 // row label + tooltip via storageshapegeom.h. This is the same compromise the link
613 // xsect editor already makes for geom1..geom4.
614 Q_PROPERTY(SWMMNodePropertyAdapter::StorageShape storageShape
615 READ storageShape WRITE setStorageShape NOTIFY changed)
616 Q_PROPERTY(DataObjectRef storageCurve
617 READ storageCurveRef WRITE setStorageCurveRef NOTIFY changed)
618 Q_PROPERTY(double storageCoeffA READ storageCoeffA WRITE setStorageCoeffA NOTIFY changed)
619 Q_PROPERTY(double storageExpB READ storageExpB WRITE setStorageExpB NOTIFY changed)
620 Q_PROPERTY(double storageConstC READ storageConstC WRITE setStorageConstC NOTIFY changed)
621 Q_PROPERTY(double storageParam1 READ storageParam1 WRITE setStorageParam1 NOTIFY changed)
622 Q_PROPERTY(double storageParam2 READ storageParam2 WRITE setStorageParam2 NOTIFY changed)
623 Q_PROPERTY(double storageParam3 READ storageParam3 WRITE setStorageParam3 NOTIFY changed)
624 // Slice DB — same read-only summary block; full volume is especially
625 // useful at storage nodes because it's the integrated curve volume.
626 Q_PROPERTY(double crownElev READ crownElev NOTIFY changed)
627 Q_PROPERTY(double fullVolume READ fullVolume NOTIFY changed)
628 Q_PROPERTY(int degree READ degree NOTIFY changed)
629 Q_PROPERTY(double statMaxDepth READ statMaxDepth NOTIFY changed)
630 Q_PROPERTY(double statMaxOverflow READ statMaxOverflow NOTIFY changed)
631 Q_PROPERTY(double statVolFlooded READ statVolFlooded NOTIFY changed)
632 Q_PROPERTY(double statTimeFlooded READ statTimeFlooded NOTIFY changed)
633 // Slice DB.2 — compound-attribute "Edit…" buttons.
634 Q_PROPERTY(NodeCompoundEditRef inflows
635 READ inflowsRef WRITE setInflowsRef NOTIFY changed)
636 Q_PROPERTY(NodeCompoundEditRef dwf
637 READ dwfRef WRITE setDwfRef NOTIFY changed)
638 Q_PROPERTY(NodeCompoundEditRef rdii
639 READ rdiiRef WRITE setRdiiRef NOTIFY changed)
640 Q_PROPERTY(NodeCompoundEditRef treatment
641 READ treatmentRef WRITE setTreatmentRef NOTIFY changed)
642 Q_PROPERTY(NodeCompoundEditRef groundwaterSources
643 READ groundwaterSourcesRef WRITE setGroundwaterSourcesRef NOTIFY changed)
644 Q_PROPERTY(InitialQualityEditRef initialQuality
645 READ initialQualityRef WRITE setInitialQualityRef NOTIFY changed)
646 Q_PROPERTY(UserFlagsEditRef userFlags
647 READ userFlagsRef WRITE setUserFlagsRef NOTIFY changed)
648public:
650};
651
657{
658 Q_OBJECT
660 READ dividerType WRITE setDividerType NOTIFY changed)
661 Q_PROPERTY(double maxDepth READ maxDepth WRITE setMaxDepth NOTIFY changed)
662 Q_PROPERTY(double initialDepth READ initialDepth WRITE setInitialDepth NOTIFY changed)
663 Q_PROPERTY(double surchargeDepth READ surchargeDepth WRITE setSurchargeDepth NOTIFY changed)
664 Q_PROPERTY(double pondedArea READ pondedArea WRITE setPondedArea NOTIFY changed)
665 // Slice DB — same read-only summary block.
666 Q_PROPERTY(double crownElev READ crownElev NOTIFY changed)
667 Q_PROPERTY(double fullVolume READ fullVolume NOTIFY changed)
668 Q_PROPERTY(int degree READ degree NOTIFY changed)
669 Q_PROPERTY(double statMaxDepth READ statMaxDepth NOTIFY changed)
670 Q_PROPERTY(double statMaxOverflow READ statMaxOverflow NOTIFY changed)
671 Q_PROPERTY(double statVolFlooded READ statVolFlooded NOTIFY changed)
672 Q_PROPERTY(double statTimeFlooded READ statTimeFlooded NOTIFY changed)
673 // Slice DB.2 — compound-attribute "Edit…" buttons.
674 Q_PROPERTY(NodeCompoundEditRef inflows
675 READ inflowsRef WRITE setInflowsRef NOTIFY changed)
676 Q_PROPERTY(NodeCompoundEditRef dwf
677 READ dwfRef WRITE setDwfRef NOTIFY changed)
678 Q_PROPERTY(NodeCompoundEditRef rdii
679 READ rdiiRef WRITE setRdiiRef NOTIFY changed)
680 Q_PROPERTY(NodeCompoundEditRef treatment
681 READ treatmentRef WRITE setTreatmentRef NOTIFY changed)
682 Q_PROPERTY(NodeCompoundEditRef groundwaterSources
683 READ groundwaterSourcesRef WRITE setGroundwaterSourcesRef NOTIFY changed)
684 Q_PROPERTY(InitialQualityEditRef initialQuality
685 READ initialQualityRef WRITE setInitialQualityRef NOTIFY changed)
686 Q_PROPERTY(UserFlagsEditRef userFlags
687 READ userFlagsRef WRITE setUserFlagsRef NOTIFY changed)
688public:
690};
691
692#endif // SWMMNODEPROPERTYADAPTER_H
Definition swmmnodepropertyadapter.h:657
Definition swmmnodepropertyadapter.h:511
Definition swmmnodepropertyadapter.h:419
NodeCompoundEditRef treatment
Definition swmmnodepropertyadapter.h:442
double crownElev
Definition swmmnodepropertyadapter.h:427
NodeCompoundEditRef dwf
Definition swmmnodepropertyadapter.h:438
NodeCompoundEditRef groundwaterSources
Definition swmmnodepropertyadapter.h:444
double pondedArea
Definition swmmnodepropertyadapter.h:424
double statMaxDepth
Definition swmmnodepropertyadapter.h:430
NodeCompoundEditRef inflows
Definition swmmnodepropertyadapter.h:436
double statVolFlooded
Definition swmmnodepropertyadapter.h:432
double fullVolume
Definition swmmnodepropertyadapter.h:428
int degree
Definition swmmnodepropertyadapter.h:429
double statTimeFlooded
Definition swmmnodepropertyadapter.h:433
InitialQualityEditRef initialQuality
Definition swmmnodepropertyadapter.h:446
double initialDepth
Definition swmmnodepropertyadapter.h:422
UserFlagsEditRef userFlags
Definition swmmnodepropertyadapter.h:448
double surchargeDepth
Definition swmmnodepropertyadapter.h:423
NodeCompoundEditRef rdii
Definition swmmnodepropertyadapter.h:440
double statMaxOverflow
Definition swmmnodepropertyadapter.h:431
double maxDepth
Definition swmmnodepropertyadapter.h:421
Renders the SWMM network elements (nodes, links, subcatchments, rain gages) for one OpenSWMMEngine mo...
Definition swmmmodellayer.h:133
Definition swmmnodepropertyadapter.h:52
StorageShape
Definition swmmnodepropertyadapter.h:86
@ Cylindrical
Definition swmmnodepropertyadapter.h:89
@ Paraboloid
Definition swmmnodepropertyadapter.h:91
@ Pyramidal
Definition swmmnodepropertyadapter.h:92
@ Conical
Definition swmmnodepropertyadapter.h:90
@ Functional
Definition swmmnodepropertyadapter.h:88
@ Tabular
Definition swmmnodepropertyadapter.h:87
InitialQualityEditRef initialQualityRef() const
Definition swmmnodepropertyadapter.cpp:771
void setDepressionHeight(double v)
Definition swmmnodepropertyadapter.cpp:333
UserFlagsEditRef userFlagsRef() const
Definition swmmnodepropertyadapter.cpp:762
double invertElev() const
void setInvertElev(double v)
double statMaxDepth() const
double storageParam2() const
Definition swmmnodepropertyadapter.cpp:988
void setGroundwaterSourcesRef(const NodeCompoundEditRef &)
Definition swmmnodepropertyadapter.h:290
NodeKind nodeKind
Definition swmmnodepropertyadapter.h:103
void setDepressionWidth(double v)
Definition swmmnodepropertyadapter.cpp:349
void setPondedArea(double v)
void setMaxDepth(double v)
double crownElev() const
void setOutfallFlapGate(FlapGate v)
Definition swmmnodepropertyadapter.cpp:462
void setSeepRate(double v)
void writeInletUsage(const std::function< bool(SWMM_InletUsage &)> &mutate)
Definition swmmnodepropertyadapter.cpp:193
double surchargeDepth() const
void setInitialQualityRef(const InitialQualityEditRef &)
Definition swmmnodepropertyadapter.h:292
double depressionHeight() const
Definition swmmnodepropertyadapter.cpp:327
QString m_name
Definition swmmnodepropertyadapter.h:404
void setStatsRegistry(openswmmvis::OutputStatsRegistry *registry)
Definition swmmnodepropertyadapter.cpp:536
DataObjectRef storageCurveRef() const
Definition swmmnodepropertyadapter.cpp:884
double storageConstC() const
Definition swmmnodepropertyadapter.cpp:919
void refresh()
Definition swmmnodepropertyadapter.h:345
DataObjectRef outfallTidalCurveRef() const
Definition swmmnodepropertyadapter.cpp:800
double xCoord
Definition swmmnodepropertyadapter.h:112
double rimDepth() const
void setFlowRestriction(double v)
Definition swmmnodepropertyadapter.cpp:317
NodeCompoundEditRef inflowsRef() const
Definition swmmnodepropertyadapter.cpp:631
NodeCompoundEditRef dwfRef() const
Definition swmmnodepropertyadapter.cpp:661
void setTreatmentRef(const NodeCompoundEditRef &)
Definition swmmnodepropertyadapter.h:289
void setStorageParam3(double v)
Definition swmmnodepropertyadapter.cpp:1022
void setPlacement(InletPlacement v)
Definition swmmnodepropertyadapter.cpp:367
void setStorageConstC(double v)
Definition swmmnodepropertyadapter.cpp:1066
QString name() const
Definition swmmnodepropertyadapter.h:125
void setStorageCurveRef(const DataObjectRef &r)
Definition swmmnodepropertyadapter.cpp:1031
void setUserFlagsRef(const UserFlagsEditRef &)
Definition swmmnodepropertyadapter.h:291
InletPlacement
Definition swmmnodepropertyadapter.h:74
@ ON_SAG
Definition swmmnodepropertyadapter.h:74
@ ON_GRADE
Definition swmmnodepropertyadapter.h:74
@ AUTOMATIC
Definition swmmnodepropertyadapter.h:74
double storageExpB() const
Definition swmmnodepropertyadapter.cpp:911
void setDwfRef(const NodeCompoundEditRef &)
Definition swmmnodepropertyadapter.h:287
DataObjectRef inletDesignRef() const
Definition swmmnodepropertyadapter.cpp:222
SWMMModelLayer * modelLayer() const
Definition swmmnodepropertyadapter.h:123
Q_INVOKABLE QString displayLabelFor(const QString &property) const
Definition swmmnodepropertyadapter.cpp:44
double depressionWidth() const
Definition swmmnodepropertyadapter.cpp:343
QUuid m_statsSourceId
Definition swmmnodepropertyadapter.h:410
DataObjectRef outfallTimeseriesRef() const
Definition swmmnodepropertyadapter.cpp:816
void setDividerType(DividerType v)
Definition swmmnodepropertyadapter.cpp:470
void setStorageParam1(double v)
Definition swmmnodepropertyadapter.cpp:1004
double statTimeFlooded() const
double seepRate() const
void setStorageShape(StorageShape v)
Definition swmmnodepropertyadapter.cpp:927
int nodeIdx() const
Definition swmmnodepropertyadapter.cpp:147
void setInflowsRef(const NodeCompoundEditRef &)
Definition swmmnodepropertyadapter.h:286
void coordChangeRequested(double newX, double newY)
double yCoord
Definition swmmnodepropertyadapter.h:113
double pctClogged() const
Definition swmmnodepropertyadapter.cpp:295
void setInletDesignRef(const DataObjectRef &r)
Definition swmmnodepropertyadapter.cpp:239
void setXCoord(double v)
Definition swmmnodepropertyadapter.cpp:596
void setCaptureNodeRef(const DataObjectRef &r)
Definition swmmnodepropertyadapter.cpp:266
double invertElev
Definition swmmnodepropertyadapter.h:104
OutfallType
Definition swmmnodepropertyadapter.h:69
@ TIMESERIES
Definition swmmnodepropertyadapter.h:69
@ FIXED
Definition swmmnodepropertyadapter.h:69
@ NORMAL
Definition swmmnodepropertyadapter.h:69
@ FREE
Definition swmmnodepropertyadapter.h:69
@ TIDAL
Definition swmmnodepropertyadapter.h:69
void setOutfallTidalCurveRef(const DataObjectRef &r)
Definition swmmnodepropertyadapter.cpp:841
void setNumInlets(int v)
Definition swmmnodepropertyadapter.cpp:285
double statVolFlooded() const
void setTag(const QString &t)
Definition swmmnodepropertyadapter.cpp:446
void renameRequested(const QString &oldName, const QString &newName)
double storageCoeffA() const
Definition swmmnodepropertyadapter.cpp:903
void setYCoord(double v)
Definition swmmnodepropertyadapter.cpp:609
void setSurchargeDepth(double v)
void setStatsSource(const QUuid &id)
Definition swmmnodepropertyadapter.cpp:545
SWMMModelLayer * m_layer
DB.4c — for compound-cell pickers.
Definition swmmnodepropertyadapter.h:405
QString tag
Definition swmmnodepropertyadapter.h:107
void setRimDepth(double v)
double pondedArea() const
double storageParam1() const
Definition swmmnodepropertyadapter.cpp:980
double outfallStage() const
Definition swmmnodepropertyadapter.cpp:791
DataObjectRef captureNodeRef() const
Definition swmmnodepropertyadapter.cpp:252
void setOutfallStage(double v)
Definition swmmnodepropertyadapter.cpp:832
int degree() const
Definition swmmnodepropertyadapter.cpp:556
FlapGate
Definition swmmnodepropertyadapter.h:71
@ NO
Definition swmmnodepropertyadapter.h:71
@ YES
Definition swmmnodepropertyadapter.h:71
OutfallType outfallType() const
Definition swmmnodepropertyadapter.cpp:401
DividerType dividerType() const
Definition swmmnodepropertyadapter.cpp:419
double flowRestriction() const
Definition swmmnodepropertyadapter.cpp:311
SWMM_Engine m_engine
Definition swmmnodepropertyadapter.h:403
openswmmvis::OutputStatsRegistry * m_statsRegistry
Definition swmmnodepropertyadapter.h:411
void setName(const QString &newName)
Definition swmmnodepropertyadapter.cpp:428
QString approachStreet() const
Definition swmmnodepropertyadapter.cpp:377
double statMaxOverflow() const
DividerType
Definition swmmnodepropertyadapter.h:70
@ OVERFLOW_
Definition swmmnodepropertyadapter.h:70
@ CUTOFF
Definition swmmnodepropertyadapter.h:70
@ WEIR
Definition swmmnodepropertyadapter.h:70
@ TABULAR
Definition swmmnodepropertyadapter.h:70
double fullVolume() const
void setPctClogged(double v)
Definition swmmnodepropertyadapter.cpp:301
void setOutfallTimeseriesRef(const DataObjectRef &r)
Definition swmmnodepropertyadapter.cpp:850
double storageParam3() const
Definition swmmnodepropertyadapter.cpp:996
void setStorageParam2(double v)
Definition swmmnodepropertyadapter.cpp:1013
NodeCompoundEditRef treatmentRef() const
Definition swmmnodepropertyadapter.cpp:716
int numInlets() const
Definition swmmnodepropertyadapter.cpp:279
void updateStoredName(const QString &newName)
Definition swmmnodepropertyadapter.h:349
double initialDepth() const
FlapGate outfallFlapGate() const
Definition swmmnodepropertyadapter.cpp:410
NodeCompoundEditRef rdiiRef() const
Definition swmmnodepropertyadapter.cpp:692
QString name
Definition swmmnodepropertyadapter.h:102
void setRdiiRef(const NodeCompoundEditRef &)
Definition swmmnodepropertyadapter.h:288
NodeCompoundEditRef groundwaterSourcesRef() const
Definition swmmnodepropertyadapter.cpp:745
InletPlacement placement() const
Definition swmmnodepropertyadapter.cpp:360
void setStorageExpB(double v)
Definition swmmnodepropertyadapter.cpp:1057
double maxDepth() const
void setOutfallType(OutfallType v)
Definition swmmnodepropertyadapter.cpp:454
StorageShape storageShape() const
Definition swmmnodepropertyadapter.cpp:873
void setInitialDepth(double v)
NodeKind
Definition swmmnodepropertyadapter.h:67
@ Outfall
Definition swmmnodepropertyadapter.h:67
@ InletJunction
Definition swmmnodepropertyadapter.h:68
@ VirtualJunction
Definition swmmnodepropertyadapter.h:68
@ Divider
Definition swmmnodepropertyadapter.h:67
@ Junction
Definition swmmnodepropertyadapter.h:67
@ Storage
Definition swmmnodepropertyadapter.h:67
void setStorageCoeffA(double v)
Definition swmmnodepropertyadapter.cpp:1048
QUuid statsSourceId() const
Definition swmmnodepropertyadapter.h:371
void setModelLayer(SWMMModelLayer *layer)
Definition swmmnodepropertyadapter.h:122
Definition swmmnodepropertyadapter.h:544
Definition swmmnodepropertyadapter.h:598
Definition swmmnodepropertyadapter.h:472
Definition outputstatsregistry.h:70
DiagramType t
Definition diagramspec.cpp:20
Definition aquiferprovider.h:21
void * SWMM_Engine
Definition objectdefaultsapplier.h:19
QVector< int > v
pool vertex indices
Definition pslgminsize.cpp:159
QVector< int > parent
union-find
Definition pslgminsize.cpp:176
Definition dataobjectref.h:34
Definition initialqualityeditref.h:27
Definition nodecompoundeditref.h:32
Definition userflagseditref.h:29