Records the creation of a SWMM link (conduit/pump/orifice/weir/outlet).
More...
#include <mapundostack.h>
|
| | AddLinkCommand (SWMMModelLayer *layer, QString name, int linkType, QString fromNode, QString toNode, QVector< QPointF > interiorVertices, MapCanvas *canvas, double offsetUp=0.0, double offsetDn=0.0, QUndoCommand *parent=nullptr) |
| | Creates an add-link command.
|
| |
| void | undo () override |
| |
| void | redo () override |
| |
| int | id () const override |
| |
Public Member Functions inherited from MapCommand |
| | MapCommand (const QString &text, MapCanvas *canvas, QUndoCommand *parent=nullptr) |
| | Constructs a map command with a human-readable text.
|
| |
| MapCanvas * | canvas () const |
| |
Records the creation of a SWMM link (conduit/pump/orifice/weir/outlet).
redo() calls SWMMModelLayer::applyLinkAdd; undo() calls rollbackTailLinkAdd — only valid while the link is still the tail.
◆ AddLinkCommand()
| AddLinkCommand::AddLinkCommand |
( |
SWMMModelLayer * |
layer, |
|
|
QString |
name, |
|
|
int |
linkType, |
|
|
QString |
fromNode, |
|
|
QString |
toNode, |
|
|
QVector< QPointF > |
interiorVertices, |
|
|
MapCanvas * |
canvas, |
|
|
double |
offsetUp = 0.0, |
|
|
double |
offsetDn = 0.0, |
|
|
QUndoCommand * |
parent = nullptr |
|
) |
| |
Creates an add-link command.
- Parameters
-
| offsetUp | Upstream invert offset (m or ft). Written via swmm_link_set_offset_up after the link is created. 0.0 = no override. |
| offsetDn | Downstream invert offset. 0.0 = no override. |
◆ id()
| int AddLinkCommand::id |
( |
| ) |
const |
|
inlineoverride |
◆ redo()
| void AddLinkCommand::redo |
( |
| ) |
|
|
override |
◆ undo()
| void AddLinkCommand::undo |
( |
| ) |
|
|
override |
The documentation for this class was generated from the following files: