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
openswmmvis::ui::InletPropertyBag Class Reference

#include <inletpropertybag.h>

Inheritance diagram for openswmmvis::ui::InletPropertyBag:
Collaboration diagram for openswmmvis::ui::InletPropertyBag:

Public Types

enum class  GrateTypeQ : int {
  P_BAR_50 = static_cast<int>(inlet::GrateType::PBar50) ,
  P_BAR_50x100 = static_cast<int>(inlet::GrateType::PBar50x100) ,
  P_BAR_30 = static_cast<int>(inlet::GrateType::PBar30) ,
  CURVED_VANE = static_cast<int>(inlet::GrateType::CurvedVane) ,
  TILT_BAR_45 = static_cast<int>(inlet::GrateType::TiltBar45) ,
  TILT_BAR_30 = static_cast<int>(inlet::GrateType::TiltBar30) ,
  RETICULINE = static_cast<int>(inlet::GrateType::Reticuline) ,
  GENERIC = static_cast<int>(inlet::GrateType::Generic)
}
 Q_ENUM mirrors of the openswmmvis::inlet design enums so QPropertyModel renders a combo-box for each. Q_ENUM requires the enum to live in a QObject, hence the duplicates (same idiom as SeriesStyleObject::MarkerShapeQ). Values track 1:1. More...
 
enum class  ThroatTypeQ : int {
  HORIZONTAL = static_cast<int>(inlet::ThroatType::Horizontal) ,
  INCLINED = static_cast<int>(inlet::ThroatType::Inclined) ,
  VERTICAL = static_cast<int>(inlet::ThroatType::Vertical)
}
 
enum class  CurveKindQ : int {
  NONE = static_cast<int>(inlet::InletCurveKind::None) ,
  DIVERSION = static_cast<int>(inlet::InletCurveKind::Diversion) ,
  RATING = static_cast<int>(inlet::InletCurveKind::Rating)
}
 
enum  Group {
  NoGroup = 0x0 ,
  GrateGroup = 0x1 ,
  CurbGroup = 0x2 ,
  SlottedGroup = 0x4 ,
  CustomGroup = 0x8
}
 Legacy tab-visibility groups (Dinlet.pas:241-298). More...
 
using CommitFn = std::function< void(const inlet::InletDesignData &before, const inlet::InletDesignData &after)>
 Commit hook. When installed, a bag edit is handed to the host (which wraps it in a SetInletParamsCommand) instead of being written straight to the provider.
 

Public Slots

void setGrateType (GrateTypeQ v)
 
void setGrateLength (double v)
 
void setGrateWidth (double v)
 
void setOpenFraction (double v)
 
void setSplashVelocity (double v)
 
void setCurbLength (double v)
 
void setCurbHeight (double v)
 
void setThroatAngle (ThroatTypeQ v)
 
void setSlotLength (double v)
 
void setSlotWidth (double v)
 
void setCurveKind (CurveKindQ v)
 
void setCurveId (const QString &v)
 

Signals

void grateTypeChanged (GrateTypeQ)
 
void grateLengthChanged (double)
 
void grateWidthChanged (double)
 
void openFractionChanged (double)
 
void splashVelocityChanged (double)
 
void curbLengthChanged (double)
 
void curbHeightChanged (double)
 
void throatAngleChanged (ThroatTypeQ)
 
void slotLengthChanged (double)
 
void slotWidthChanged (double)
 
void curveKindChanged (CurveKindQ)
 
void curveIdChanged (const QString &)
 

Public Member Functions

 InletPropertyBag (QObject *parent=nullptr)
 
void bind (inlet::InletProvider *p)
 
inlet::InletProviderprovider () const noexcept
 
void setCommitHandler (CommitFn fn)
 
Groups visibleGroups () const
 Groups that apply to the bound design's type.
 
Q_INVOKABLE bool isPropertyVisible (const QString &property) const
 Row-level visibility: group visibility plus the two legacy exceptions (open fraction / splash-over velocity are GENERIC only; the throat angle does not apply to a DROP CURB).
 
Q_INVOKABLE QString displayLabelFor (const QString &property) const
 Group-prefixed, unit-suffixed label for the QPropertyModel row. Empty for an unknown name so the generated name is used.
 
GrateTypeQ grateType () const noexcept
 
double grateLength () const noexcept
 
double grateWidth () const noexcept
 
double openFraction () const noexcept
 
double splashVelocity () const noexcept
 
double curbLength () const noexcept
 
double curbHeight () const noexcept
 
ThroatTypeQ throatAngle () const noexcept
 
double slotLength () const noexcept
 
double slotWidth () const noexcept
 
CurveKindQ curveKind () const noexcept
 
QString curveId () const
 

Static Public Member Functions

static Groups groupsFor (inlet::InletType t)
 Groups that apply to t. Pure — used by the tests.
 
static Group groupOf (const QString &property)
 The group a raw Q_PROPERTY name belongs to.
 

Properties

GrateTypeQ grateType
 
double grateLength
 
double grateWidth
 
double openFraction
 
double splashVelocity
 
double curbLength
 
double curbHeight
 
ThroatTypeQ throatAngle
 
double slotLength
 
double slotWidth
 
CurveKindQ curveKind
 
QString curveId
 

Member Typedef Documentation

◆ CommitFn

using openswmmvis::ui::InletPropertyBag::CommitFn = std::function<void(const inlet::InletDesignData &before, const inlet::InletDesignData &after)>

Commit hook. When installed, a bag edit is handed to the host (which wraps it in a SetInletParamsCommand) instead of being written straight to the provider.

Member Enumeration Documentation

◆ CurveKindQ

Enumerator
NONE 
DIVERSION 
RATING 

◆ GrateTypeQ

Q_ENUM mirrors of the openswmmvis::inlet design enums so QPropertyModel renders a combo-box for each. Q_ENUM requires the enum to live in a QObject, hence the duplicates (same idiom as SeriesStyleObject::MarkerShapeQ). Values track 1:1.

Enumerator
P_BAR_50 
P_BAR_50x100 
P_BAR_30 
CURVED_VANE 
TILT_BAR_45 
TILT_BAR_30 
RETICULINE 
GENERIC 

◆ Group

Legacy tab-visibility groups (Dinlet.pas:241-298).

Enumerator
NoGroup 
GrateGroup 
CurbGroup 
SlottedGroup 
CustomGroup 

◆ ThroatTypeQ

Enumerator
HORIZONTAL 
INCLINED 
VERTICAL 

Constructor & Destructor Documentation

◆ InletPropertyBag()

openswmmvis::ui::InletPropertyBag::InletPropertyBag ( QObject *  parent = nullptr)
explicit

Member Function Documentation

◆ bind()

void openswmmvis::ui::InletPropertyBag::bind ( inlet::InletProvider p)
Here is the call graph for this function:

◆ curbHeight()

double openswmmvis::ui::InletPropertyBag::curbHeight ( ) const
inlinenoexcept

◆ curbHeightChanged

void openswmmvis::ui::InletPropertyBag::curbHeightChanged ( double  )
signal
Here is the caller graph for this function:

◆ curbLength()

double openswmmvis::ui::InletPropertyBag::curbLength ( ) const
inlinenoexcept

◆ curbLengthChanged

void openswmmvis::ui::InletPropertyBag::curbLengthChanged ( double  )
signal
Here is the caller graph for this function:

◆ curveId()

QString openswmmvis::ui::InletPropertyBag::curveId ( ) const
inline

◆ curveIdChanged

void openswmmvis::ui::InletPropertyBag::curveIdChanged ( const QString &  )
signal
Here is the caller graph for this function:

◆ curveKind()

CurveKindQ openswmmvis::ui::InletPropertyBag::curveKind ( ) const
inlinenoexcept

◆ curveKindChanged

void openswmmvis::ui::InletPropertyBag::curveKindChanged ( CurveKindQ  )
signal
Here is the caller graph for this function:

◆ displayLabelFor()

QString openswmmvis::ui::InletPropertyBag::displayLabelFor ( const QString &  property) const

Group-prefixed, unit-suffixed label for the QPropertyModel row. Empty for an unknown name so the generated name is used.

◆ grateLength()

double openswmmvis::ui::InletPropertyBag::grateLength ( ) const
inlinenoexcept

◆ grateLengthChanged

void openswmmvis::ui::InletPropertyBag::grateLengthChanged ( double  )
signal
Here is the caller graph for this function:

◆ grateType()

GrateTypeQ openswmmvis::ui::InletPropertyBag::grateType ( ) const
inlinenoexcept

◆ grateTypeChanged

void openswmmvis::ui::InletPropertyBag::grateTypeChanged ( GrateTypeQ  )
signal
Here is the caller graph for this function:

◆ grateWidth()

double openswmmvis::ui::InletPropertyBag::grateWidth ( ) const
inlinenoexcept

◆ grateWidthChanged

void openswmmvis::ui::InletPropertyBag::grateWidthChanged ( double  )
signal
Here is the caller graph for this function:

◆ groupOf()

InletPropertyBag::Group openswmmvis::ui::InletPropertyBag::groupOf ( const QString &  property)
static

The group a raw Q_PROPERTY name belongs to.

Here is the caller graph for this function:

◆ groupsFor()

InletPropertyBag::Groups openswmmvis::ui::InletPropertyBag::groupsFor ( inlet::InletType  t)
static

Groups that apply to t. Pure — used by the tests.

Here is the caller graph for this function:

◆ isPropertyVisible()

bool openswmmvis::ui::InletPropertyBag::isPropertyVisible ( const QString &  property) const

Row-level visibility: group visibility plus the two legacy exceptions (open fraction / splash-over velocity are GENERIC only; the throat angle does not apply to a DROP CURB).

Here is the call graph for this function:

◆ openFraction()

double openswmmvis::ui::InletPropertyBag::openFraction ( ) const
inlinenoexcept

◆ openFractionChanged

void openswmmvis::ui::InletPropertyBag::openFractionChanged ( double  )
signal
Here is the caller graph for this function:

◆ provider()

InletProvider * openswmmvis::ui::InletPropertyBag::provider ( ) const
noexcept

◆ setCommitHandler()

void openswmmvis::ui::InletPropertyBag::setCommitHandler ( CommitFn  fn)

◆ setCurbHeight

void openswmmvis::ui::InletPropertyBag::setCurbHeight ( double  v)
slot
Here is the call graph for this function:

◆ setCurbLength

void openswmmvis::ui::InletPropertyBag::setCurbLength ( double  v)
slot
Here is the call graph for this function:

◆ setCurveId

void openswmmvis::ui::InletPropertyBag::setCurveId ( const QString &  v)
slot
Here is the call graph for this function:

◆ setCurveKind

void openswmmvis::ui::InletPropertyBag::setCurveKind ( CurveKindQ  v)
slot
Here is the call graph for this function:

◆ setGrateLength

void openswmmvis::ui::InletPropertyBag::setGrateLength ( double  v)
slot
Here is the call graph for this function:

◆ setGrateType

void openswmmvis::ui::InletPropertyBag::setGrateType ( GrateTypeQ  v)
slot
Here is the call graph for this function:

◆ setGrateWidth

void openswmmvis::ui::InletPropertyBag::setGrateWidth ( double  v)
slot
Here is the call graph for this function:

◆ setOpenFraction

void openswmmvis::ui::InletPropertyBag::setOpenFraction ( double  v)
slot
Here is the call graph for this function:

◆ setSlotLength

void openswmmvis::ui::InletPropertyBag::setSlotLength ( double  v)
slot
Here is the call graph for this function:

◆ setSlotWidth

void openswmmvis::ui::InletPropertyBag::setSlotWidth ( double  v)
slot
Here is the call graph for this function:

◆ setSplashVelocity

void openswmmvis::ui::InletPropertyBag::setSplashVelocity ( double  v)
slot
Here is the call graph for this function:

◆ setThroatAngle

void openswmmvis::ui::InletPropertyBag::setThroatAngle ( ThroatTypeQ  v)
slot
Here is the call graph for this function:

◆ slotLength()

double openswmmvis::ui::InletPropertyBag::slotLength ( ) const
inlinenoexcept

◆ slotLengthChanged

void openswmmvis::ui::InletPropertyBag::slotLengthChanged ( double  )
signal
Here is the caller graph for this function:

◆ slotWidth()

double openswmmvis::ui::InletPropertyBag::slotWidth ( ) const
inlinenoexcept

◆ slotWidthChanged

void openswmmvis::ui::InletPropertyBag::slotWidthChanged ( double  )
signal
Here is the caller graph for this function:

◆ splashVelocity()

double openswmmvis::ui::InletPropertyBag::splashVelocity ( ) const
inlinenoexcept

◆ splashVelocityChanged

void openswmmvis::ui::InletPropertyBag::splashVelocityChanged ( double  )
signal
Here is the caller graph for this function:

◆ throatAngle()

ThroatTypeQ openswmmvis::ui::InletPropertyBag::throatAngle ( ) const
inlinenoexcept

◆ throatAngleChanged

void openswmmvis::ui::InletPropertyBag::throatAngleChanged ( ThroatTypeQ  )
signal
Here is the caller graph for this function:

◆ visibleGroups()

InletPropertyBag::Groups openswmmvis::ui::InletPropertyBag::visibleGroups ( ) const

Groups that apply to the bound design's type.

Here is the call graph for this function:
Here is the caller graph for this function:

Property Documentation

◆ curbHeight

double openswmmvis::ui::InletPropertyBag::curbHeight
readwrite

◆ curbLength

double openswmmvis::ui::InletPropertyBag::curbLength
readwrite

◆ curveId

QString openswmmvis::ui::InletPropertyBag::curveId
readwrite

◆ curveKind

CurveKindQ openswmmvis::ui::InletPropertyBag::curveKind
readwrite

◆ grateLength

double openswmmvis::ui::InletPropertyBag::grateLength
readwrite

◆ grateType

GrateTypeQ openswmmvis::ui::InletPropertyBag::grateType
readwrite

◆ grateWidth

double openswmmvis::ui::InletPropertyBag::grateWidth
readwrite

◆ openFraction

double openswmmvis::ui::InletPropertyBag::openFraction
readwrite

◆ slotLength

double openswmmvis::ui::InletPropertyBag::slotLength
readwrite

◆ slotWidth

double openswmmvis::ui::InletPropertyBag::slotWidth
readwrite

◆ splashVelocity

double openswmmvis::ui::InletPropertyBag::splashVelocity
readwrite

◆ throatAngle

ThroatTypeQ openswmmvis::ui::InletPropertyBag::throatAngle
readwrite

The documentation for this class was generated from the following files: