Nix (Dev) 3.5.10
dev - 3.5.10 - 1af9301
|
#include <GeneratorPms.hpp>
Classes | |
struct | Constants |
struct | DefaultValues |
struct | Keys |
struct | Sections |
Public Member Functions | |
GeneratorPms () | |
~GeneratorPms () override=default | |
bool | load (const iv::file::xml::node &nodeControlMimic) override |
bool | save (iv::file::xml::node &nodeControlMimic) const override |
void | getChannels (const std::shared_ptr< std::vector< std::weak_ptr< iv::channels::AbstractChannel > > > &channelsInControl) const override |
Añade los canales que el MimicElement tiene enlazado. | |
void | mapChannels (const std::function< void(std::weak_ptr< iv::channels::AbstractChannel > &)> &mapFunction) override |
Processed gets ///. | |
std::shared_ptr< iv::mimics::AbstractMimicElement > | clone () const override |
void | executeCommand (const std::string &strAction) const override |
Run actions ///. | |
std::optional< std::string > | getStringWorkingState () const override |
std::optional< std::string > | getStringControlState () const override |
std::optional< iv::mimics::eAlarmState > | getAlarmState () const override |
iv::math::geometry::Point2d | getAlarmIconPosition (const iv::math::geometry::Area &elementSize) const override |
void | drawSpecific (IGraphics *graphics, std::optional< iv::types::color > colorWorkingState, std::optional< iv::types::color > colorControlState, iv::eLanguage drawingLanguage) override |
Draws the specific abstract element shape. | |
AbstractComponentGUI * | panelEditControl () override |
UI methods ///. | |
void | addOptionsMenu (const std::shared_ptr< iv::mimics::MimicControlMenu > &menu) override |
bool | canShowCircularMenu () const override |
Behaviours gets ///. | |
bool | hasAlternativeAction () const override |
void | runAlternativeAction (CDialog *dlgFatherRef) override |
Ejecuta código específico del control. | |
std::optional< double > | normalizedPowerValue () const |
std::optional< iv::channels::FormattedValue > | getPowerText () const |
std::optional< iv::channels::FormattedValue > | getFrequencyText () const |
std::optional< iv::channels::FormattedValue > | getPriorityText () const |
std::optional< std::string > | getRemoteAutoIconState () const |
const iv::mimics::TitleSettings & | getTitleSettings () const |
std::weak_ptr< iv::mimics::OnlineVariables > | getOnlineVariables () const |
virtual void | updateEnabledLanguages (const std::set< iv::eLanguage > &enabledLanguages) |
bool | isPointInMimic (iv::types::coord x, iv::types::coord y) const |
virtual std::optional< iv::types::color > | getColorWorkingState () const |
Retrieves the color representing the current working state of the element. | |
virtual std::optional< iv::types::color > | getColorControlState () const |
Retrieves the color representing the current control state of the element. | |
virtual void | runCommandControlWithoutMenu () |
Ejecuta un comando accionado sin el menu de opciones (caso de un botón) | |
virtual void | runEvaluation () |
Ejecuta la evaluación del control. | |
virtual void | postProcess () |
PROCESSES. | |
void | draw (IGraphics *graphics, iv::eLanguage drawingLanguage, const std::optional< std::unordered_set< iv::types::channelId > > &channelsRepeatedOpt=std::nullopt, const std::optional< std::set< std::shared_ptr< AbstractMimicElement > > > &otherMimicElements=std::nullopt) |
DRAWS. | |
void | setRedrawFlag (bool reDrawFlag=true) |
void | removeGraphicsObjects (IGraphics *graphics) |
Elimina el elemento gráfico. | |
virtual void | move (double dx, double dy) |
MOVEMENTS. | |
bool | rotate (double angle) |
void | handleEvent (CEventMotion *evtMotion) |
Public Attributes | |
eZDepth | m_depth |
iv::mimics::eMimicElementType | m_mimicElementType |
iv::mimics::Location | m_location |
iv::types::width | m_width |
iv::types::height | m_height |
iv::mimics::TitleSettings | m_titleSettings |
iv::mimics::Background | m_background |
std::shared_ptr< OnlineVariables > | m_onlineVariables |
std::shared_ptr< std::vector< std::weak_ptr< iv::channels::AbstractChannel > > > | m_addedAlarms |
Protected Member Functions | |
GeneratorPms (const GeneratorPms &other) | |
bool | checkIntegrity () const override |
bool | hasRepeatedChannels (const std::unordered_set< iv::types::channelId > &channelsRepeatedOpt) const override |
Checks if the current mimic element contains any repeated channels. | |
bool | isRepeatedMimicElement (const std::set< std::shared_ptr< AbstractMimicElement > > &otherMimicsElements) const override |
Determines whether the current mimic element shares significant similarities with others. | |
void | drawGeneratorArc (IGraphics *graphics, iv::types::radius arcRadius, iv::types::width arcWidth) const |
void | drawGeneratorName (IGraphics *graphics, iv::types::radius arcRadius) const |
void | drawTextPower (IGraphics *graphics, iv::types::radius arcRadius) const |
void | drawTextFrequency (IGraphics *graphics, iv::types::radius arcRadius) const |
void | drawTextPriority (IGraphics *graphics, iv::types::radius arcRadius, iv::types::width arcWidth) const |
void | drawTextControlState (IGraphics *graphics, iv::types::radius arcRadius, iv::types::width arcWidth) const |
void | updateGeneratorTraits () |
Update the valve traits channels with the current generator channels. | |
std::vector< iv::math::geometry::Point2d > | calculateLimits (IGraphics *graphics, iv::eLanguage drawingLanguage) |
AbstractComponentGUI * | buttonEditTitle () |
AbstractComponentGUI * | panelEditSize () |
AbstractComponentGUI * | panelEditOnlineVariables () const |
AbstractComponentGUI * | panelEditAddedAlarms () const |
Protected Attributes | |
iv::types::color | m_generatorNameColor {DefaultValues::generatorNameColor} |
std::weak_ptr< iv::model::pms::Generator > | m_pmsGenerator |
bool | m_redrawFlag {false} |
Private Member Functions | |
std::unique_ptr< CDrawText > | prvCreateTextTitle (iv::eLanguage language) const |
void | applyPosition (IGraphics *graphics) const |
void | applyRotation (IGraphics *graphics) const |
std::optional< iv::mimics::eAlarmState > | getAddedAlarmsMimicAlarmState () const |
bool | loadFeedbackRunningStopped (const iv::file::xml::node &nodeStartStop) |
bool | saveFeedbackRunningStopped (iv::file::xml::node &nodeStartStop) const |
void | getChannelsFeedbackRunningStopped (const std::shared_ptr< std::vector< std::weak_ptr< iv::channels::AbstractChannel > > > &channelsInControl) const |
void | mapChannelsFeedbackRunningStopped (const std::function< void(std::weak_ptr< iv::channels::AbstractChannel > &)> &mapFunction) |
eRunningStoppedState | getState () const |
bool | hasLinkedChannels () const |
AbstractComponentGUI * | panelEditFeedback () |
bool | loadRemoteLocal (const iv::file::xml::node &nodeRemoteLocal) |
bool | saveRemoteLocal (iv::file::xml::node &nodeRemoteLocal) const |
void | getChannelsRemoteLocal (const std::shared_ptr< std::vector< std::weak_ptr< iv::channels::AbstractChannel > > > &channelsInControl) const |
void | mapChannelsRemoteLocal (const std::function< void(std::weak_ptr< iv::channels::AbstractChannel > &)> &mapFunction) |
eRemoteState | getState () const |
std::string_view | getIconState () const |
AbstractComponentGUI * | panelEditRemoteLocal () |
bool | loadTripReset (const iv::file::xml::node &nodeTripReset) |
bool | saveTripReset (iv::file::xml::node &nodeTripReset) const |
void | getChannelsTripReset (const std::shared_ptr< std::vector< std::weak_ptr< iv::channels::AbstractChannel > > > &channelsInControl) const |
void | mapChannelsTripReset (const std::function< void(std::weak_ptr< iv::channels::AbstractChannel > &)> &mapFunction) |
bool | isTrip () const |
AbstractComponentGUI * | panelEditTrip () |
void | addTraitOptionsMenu (const std::shared_ptr< iv::mimics::MimicControlMenu > &menu, const std::optional< std::function< bool(CDialog *)> > &resetCommandEvaluation) const |
bool | loadAutomaticSemiAuto (const iv::file::xml::node &nodeAutomatic) |
bool | saveAutomaticSemiAuto (iv::file::xml::node &nodeAutomatic) const |
void | getChannelsAutomaticSemiAuto (const std::shared_ptr< std::vector< std::weak_ptr< iv::channels::AbstractChannel > > > &channelsInControl) const |
void | mapChannelsAutomaticSemiAuto (const std::function< void(std::weak_ptr< iv::channels::AbstractChannel > &)> &mapFunction) |
eAutomaticState | getState () const |
std::string_view | getIconState () const |
AbstractComponentGUI * | panelEditAutomaticManual () |
void | addTraitOptionsMenu (const std::shared_ptr< iv::mimics::MimicControlMenu > &menu, const std::optional< std::function< bool(CDialog *)> > &autoCommandEvaluation, const std::optional< std::function< bool(CDialog *)> > &semiAutoCommandEvaluation) const |
Static Private Member Functions | |
static bool | checkHasRepeated (const std::unordered_set< iv::types::channelId > &repeatedChannels, const std::shared_ptr< std::vector< std::weak_ptr< iv::channels::AbstractChannel > > > &elementChannels) |
iv::mimics::elementsPms::GeneratorPms::GeneratorPms | ( | ) |
|
overridedefault |
|
protected |
|
overridevirtual |
Reimplemented from iv::mimics::AbstractMimicElement.
|
inherited |
|
inherited |
|
privateinherited |
|
privateinherited |
|
protectedinherited |
|
protectedinherited |
|
overridevirtual |
Behaviours gets ///.
Reimplemented from iv::mimics::AbstractMimicElement.
|
staticprivateinherited |
|
overrideprotectedvirtual |
Reimplemented from iv::mimics::AbstractMimicElement.
|
nodiscardoverridevirtual |
Implements iv::mimics::AbstractMimicElement.
|
inherited |
DRAWS.
Dibuja el elemento en pantalla, con título, background, alarma, toda la parte común de todos los elementos.
graphics | |
drawingLanguage | Language to draw the element |
channelsRepeatedOpt |
|
protected |
|
protected |
|
overridevirtual |
Draws the specific abstract element shape.
graphics | |
colorWorkingState | |
colorControlState | |
drawingLanguage |
Implements iv::mimics::AbstractMimicElement.
|
protected |
|
protected |
|
protected |
|
protected |
|
overridevirtual |
Run actions ///.
Ejecuta un comando accionado desde el menu de opciones
strAction |
Implements iv::mimics::AbstractMimicElement.
|
nodiscardprivateinherited |
|
nodiscardoverridevirtual |
Reimplemented from iv::mimics::AbstractMimicElement.
|
nodiscardoverridevirtual |
Reimplemented from iv::mimics::AbstractMimicElement.
|
overridevirtual |
Añade los canales que el MimicElement tiene enlazado.
[out] | channelsInControl | Map of channels in mimic element |
Reimplemented from iv::mimics::AbstractMimicElement.
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
nodiscardvirtualinherited |
Retrieves the color representing the current control state of the element.
The control state describes how the element is being controlled, with examples including Remote/Local or Online/Offline. The returned color, if any, is intended to visually convey the control mode.
Reimplemented in iv::mimics::elements::Compressor, iv::mimics::elements::Damper, iv::mimics::elements::Fan, iv::mimics::elements::Generator, and iv::mimics::elements::Pump.
|
nodiscardvirtualinherited |
Retrieves the color representing the current working state of the element.
The working state reflects the functional status of the element, which can represent states such as Running/Stopped, Open/Closed, or Undefined. The returned color, if any, is intended to visually indicate this status.
Reimplemented in iv::mimics::Digital, iv::mimics::elements::Breaker, iv::mimics::elements::Compressor, iv::mimics::elements::Damper, iv::mimics::elements::Dial, iv::mimics::elements::Digital, iv::mimics::elements::Display, iv::mimics::elements::Fan, iv::mimics::elements::Generator, iv::mimics::elements::LevelBar, iv::mimics::elements::Pump, iv::mimics::elements::Shaft, iv::mimics::elements::Tank, iv::mimics::elements::Valve, iv::mimics::elementsAutomated::DamperAutomated, iv::mimics::elementsAutomated::ValveAutomated, and iv::mimics::elementsPms::BreakerPms.
std::optional< iv::channels::FormattedValue > iv::mimics::elementsPms::GeneratorPms::getFrequencyText | ( | ) | const |
|
nodiscardinherited |
|
nodiscardinherited |
|
nodiscardinherited |
std::optional< iv::channels::FormattedValue > iv::mimics::elementsPms::GeneratorPms::getPowerText | ( | ) | const |
std::optional< iv::channels::FormattedValue > iv::mimics::elementsPms::GeneratorPms::getPriorityText | ( | ) | const |
std::optional< std::string > iv::mimics::elementsPms::GeneratorPms::getRemoteAutoIconState | ( | ) | const |
|
nodiscardinherited |
|
nodiscardinherited |
|
nodiscardinherited |
|
nodiscardoverridevirtual |
Reimplemented from iv::mimics::AbstractMimicElement.
|
nodiscardoverridevirtual |
Reimplemented from iv::mimics::AbstractMimicElement.
|
inlinenodiscardinherited |
|
inherited |
TODO: No se usa, y junto a este, el executeCommand
|
overridevirtual |
Reimplemented from iv::mimics::AbstractMimicElement.
|
nodiscardinherited |
|
overrideprotectedvirtual |
Checks if the current mimic element contains any repeated channels.
channelsRepeatedOpt | A set of channel IDs that are considered as repeated. |
Reimplemented from iv::mimics::AbstractMimicElement.
|
nodiscardinherited |
|
overrideprotectedvirtual |
Determines whether the current mimic element shares significant similarities with others.
otherMimicsElements | A set of other mimics elements to be compared against. |
Reimplemented from iv::mimics::AbstractMimicElement.
|
inherited |
|
overridevirtual |
Reimplemented from iv::mimics::AbstractMimicElement.
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
overridevirtual |
Processed gets ///.
Applies a function over each channel in the mimic element
mapFunction | Function to apply over each channel |
Reimplemented from iv::mimics::AbstractMimicElement.
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
virtualinherited |
MOVEMENTS.
Reimplemented in iv::mimics::auxiliary::Line, and iv::mimics::auxiliary::Polyline.
std::optional< double > iv::mimics::elementsPms::GeneratorPms::normalizedPowerValue | ( | ) | const |
|
nodiscardprotectedinherited |
|
inherited |
|
overridevirtual |
UI methods ///.
PANELS
Crea el panel de edición del control.
Implements iv::mimics::AbstractMimicElement.
|
inherited |
|
nodiscardprotectedinherited |
|
inherited |
|
protectedinherited |
|
inherited |
|
virtualinherited |
PROCESSES.
Procesa ciertos atributos del elemento.
Reimplemented in iv::mimics::auxiliary::Line, and iv::mimics::auxiliary::Square.
|
nodiscardprivateinherited |
|
inherited |
Elimina el elemento gráfico.
graphics |
|
inherited |
|
overridevirtual |
Ejecuta código específico del control.
Reimplemented from iv::mimics::AbstractMimicElement.
|
virtualinherited |
Ejecuta un comando accionado sin el menu de opciones (caso de un botón)
|
virtualinherited |
Ejecuta la evaluación del control.
|
overridevirtual |
Reimplemented from iv::mimics::AbstractMimicElement.
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
virtualinherited |
|
protected |
Update the valve traits channels with the current generator channels.
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
Model
|
protected |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
protected |
|
privateinherited |
|
protectedinherited |
Controller
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
mutableprivate |
|
mutableprivate |
|
mutableprivate |
|
mutableprivate |
|
mutableprivate |
|
mutableprivate |
|
mutableprivate |
|
privateinherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |