Nix (Dev) 3.5.10
dev - 3.5.10 - 1af9301
Loading...
Searching...
No Matches
LogicComponentBroadCastChannel Class Referencefinal

#include <LogicComponentBroadCastChannel.hpp>

Inheritance diagram for LogicComponentBroadCastChannel:
[legend]
Collaboration diagram for LogicComponentBroadCastChannel:
[legend]

Classes

struct  Constants
 
struct  DefaultValues
 
struct  Keys
 
struct  Sections
 

Public Types

enum class  ECPPosition {
  Bottom , Left , Right , Top ,
  Without
}
 
typedef std::map< AbstractCanvasItem::TId, std::shared_ptr< CLogicsConnectionPoint > > TMapIdConnPoint
 
enum class  EPartType {
  MainShape , MainText , SubText1 , SubText2 ,
  SubText3
}
 
typedef std::pair< TIndex, EPartTypeTPairIndexPartType
 
typedef std::map< TIndex, EPartTypeTMapIndexPartType
 
typedef std::map< TPairIndexPartType, AbstractCanvasItem::TTupleDrawingModeTMapPartTypeDrawingMode
 
typedef std::map< AbstractCanvasItem::TTupleDrawingMode, TMapPartTypeDrawingModeTMapDrawingModePartsDrawingMode
 
enum class  EMarkMode { None , Selected }
 
enum class  EStandOutMode { Highlighted , Warning , None }
 
typedef uint32_t TId
 
typedef std::pair< double, double > TPosition2d
 
typedef uint32_t TIndex
 
typedef std::tuple< EMarkMode, EStandOutModeTTupleDrawingMode
 

Public Member Functions

 LogicComponentBroadCastChannel (const iv::types::logic::ComponentType &componentType, std::optional< iv::types::unitId > unitId)
 
 LogicComponentBroadCastChannel (AbstractCanvasItem::TId id, const iv::types::logic::ComponentType &componentType, const std::string &name, std::optional< iv::types::unitId > unitId)
 
 ~LogicComponentBroadCastChannel () override=default
 
iv::file::xml::node read (const iv::file::xml::node &node) override
 
iv::file::xml::node save (iv::file::xml::node &node) const override
 
std::string maxText () const override
 
std::string getDescriptiveText () const override
 
uint32_t firmwareValue () const
 
iv::types::logic::channelGlobalId getChannelId () const
 
std::string constantLogicStateToConstantFirmwareString () const
 
std::string toString () const
 
uint32_t indexArea () const
 
void setIndexArea (uint32_t indexArea)
 
void setConnectionPointPosition (ECPPosition cPPosition)
 
ECPPosition getConnectionPointPosition () const
 
std::vector< std::shared_ptr< AbstractCanvasItem > > getLinkedItems () override
 
void updateLinkedItems () override
 
void resetLinkedItems () override
 
void addConnectionPointInput (const std::shared_ptr< CLogicsConnectionPoint > &connectionPoint)
 
void addConnectionPointOutput (const std::shared_ptr< CLogicsConnectionPoint > &connectionPoint)
 
size_t numberOfInputs () const
 
size_t numberOfOutputs () const
 
bool isAllConnected () const
 
const iv::types::logic::componentFinalTypegetComponentFinalType () const
 
const iv::logic::eGeneralTypegetComponentGeneralType () const
 
const iv::types::logic::componentTypegetComponentType () const
 
const iv::types::logic::ComponentTypegetComponentTypeTuple () const
 
std::shared_ptr< CLogicsConnectionPointgetConnectionPoint (iv::logic::eDBBlockParamType pointType, iv::types::logic::paramNumber paramNum)
 
std::shared_ptr< CLogicsConnectionPointgetFirstInputConnectionPoint () const
 
std::shared_ptr< CLogicsConnectionPointgetInputConnectionPoint (uint32_t index)
 
std::shared_ptr< CLogicsConnectionPointgetFirstOutputConnectionPoint () const
 
std::shared_ptr< CLogicsConnectionPointgetOutputConnectionPoint (uint32_t index)
 
TMapIdConnPoint getInputRefs ()
 
const TMapIdConnPointgetInputRefsConst () const
 
TMapIdConnPoint getOutputRefs ()
 
const TMapIdConnPointgetOutputRefsConst () const
 
std::set< std::shared_ptr< CLogicsConnectionPoint > > getConnectionPoints () const
 
const iv::logic::eLogicsElementTypegetElementType () const
 
const std::string & getElementName () const
 
virtual std::string getMainText () const
 
virtual std::optional< iv::types::SizegetDefaultSize () const
 
void addListenerClick (std::unique_ptr< IListenerCanvasItemClick > listener)
 
void addListenerMove (std::unique_ptr< IListenerCanvasItemMove > listener)
 
void addListenerEnter (std::unique_ptr< IListenerCanvasItemEnter > listener)
 
void addListenerLeave (std::unique_ptr< IListenerCanvasItemLeave > listener)
 
void runListenersClick (CEventCanvasButton *evtCanvasButton)
 
void runListenersMove (CEventCanvasButton *evtCanvasButton)
 
void runListenersEnter ()
 
void runListenersLeave ()
 
void setCanvasItem (ICanvasItem *canvasItem)
 
void setCurrentMarkMode (EMarkMode markMode)
 
void setCurrentStandoutMode (EStandOutMode standoutMode)
 
void setGlobalPosition2d (const TPosition2d &position2d)
 
void setId (TId id)
 
void setRedrawFlag (bool redraw)
 
ICanvasItemgetCanvasItem ()
 
const ICanvasItemgetCanvasItem () const
 
const AbstractCanvasItem::TTupleDrawingModegetCurrentDrawingMode () const
 
const TPosition2dgetGlobalPosition2d () const
 
TId getId () const
 
bool getRedrawFlag () const
 

Static Public Member Functions

static std::string strGuiOthers (iv::logic::eOthers otherBlock, bool shortName=false)
 
static iv::logic::eGeneralType enumGeneralType (const std::string &strType)
 
static std::string strGeneralType (iv::logic::eGeneralType generalType)
 
static iv::types::logic::ComponentType readLogicsComponentTypeTuple (const iv::file::xml::node &node)
 
static bool hasExecutionOrder (const iv::types::logic::ComponentType &componentTypeTuple)
 
static bool isExecBlock (const iv::types::logic::ComponentType &componentTypeTuple)
 
static bool isLibraryBlock (const iv::types::logic::ComponentType &componentTypeTuple)
 
static iv::logic::eLogicsElementType enumLogicsElementType (const std::string &strType)
 
static std::string strLogicsElementType (iv::logic::eLogicsElementType type)
 
static iv::logic::eLogicsElementType readLogicsElementType (const iv::file::xml::node &node)
 

Public Attributes

iv::logic::eBroadCastChannelType m_broadCastChannelType
 

Static Public Attributes

static constexpr std::string_view kPrvKeySectionLogicsElementData = "LogicsElementData"
 
static const TId kInvalidCanvasItemId = 0
 
static const TId kStartingCanvasItemId = 1
 
static const TPosition2d kZeroPosition = {0., 0.}
 

Protected Member Functions

virtual std::optional< uint32_t > getIndexOfConnectionForParam (iv::logic::eDBBlockParamType type, iv::types::logic::paramNumber number) const
 

Private Attributes

uint32_t m_indexArea
 
std::optional< iv::types::unitIdm_unitId
 
ECPPosition m_cPPosition
 
iv::types::logic::ComponentType m_componentTypeTuple
 
TMapIdConnPoint m_inputRefs
 
TMapIdConnPoint m_outputRefs
 
iv::logic::eLogicsElementType m_logicsElementType
 
std::string m_name
 
TId m_id
 
TPosition2d m_globalPosition2d
 
TTupleDrawingMode m_currentDrawingMode
 
bool m_redrawFlag
 
ICanvasItemm_canvasItem
 
std::vector< std::unique_ptr< IListenerCanvasItemClick > > m_listenersItemClick
 
std::vector< std::unique_ptr< IListenerCanvasItemMove > > m_listenersItemMove
 
std::vector< std::unique_ptr< IListenerCanvasItemEnter > > m_listenersItemEnter
 
std::vector< std::unique_ptr< IListenerCanvasItemLeave > > m_listenersItemLeave
 

Member Typedef Documentation

◆ TId

uint32_t AbstractCanvasItem::TId
inherited

◆ TIndex

uint32_t AbstractCanvasItem::TIndex
inherited

◆ TMapDrawingModePartsDrawingMode

◆ TMapIdConnPoint

◆ TMapIndexPartType

◆ TMapPartTypeDrawingMode

◆ TPairIndexPartType

◆ TPosition2d

std::pair<double, double> AbstractCanvasItem::TPosition2d
inherited

◆ TTupleDrawingMode

Member Enumeration Documentation

◆ ECPPosition

enum class CLogicsComponentOthers::ECPPosition
stronginherited
Enumerator
Bottom 
Left 
Right 
Top 
Without 

◆ EMarkMode

enum class AbstractCanvasItem::EMarkMode
stronginherited

Enumeration defining the different modes to mark a logic element or a part of a logic element.

Enumerator
None 
Selected 

◆ EPartType

enum class AbstractLogicsElement::EPartType
stronginherited

Enumeration defining the types of parts a logic element can be made of.

Enumerator
MainShape 
MainText 
SubText1 
SubText2 
SubText3 

◆ EStandOutMode

enum class AbstractCanvasItem::EStandOutMode
stronginherited

Enumeration defining the different modes to stand out a logic element or a part of a logic element.

Enumerator
Highlighted 
Warning 
None 

Constructor & Destructor Documentation

◆ LogicComponentBroadCastChannel() [1/2]

LogicComponentBroadCastChannel::LogicComponentBroadCastChannel ( const iv::types::logic::ComponentType & componentType,
std::optional< iv::types::unitId > unitId )
explicit

◆ LogicComponentBroadCastChannel() [2/2]

LogicComponentBroadCastChannel::LogicComponentBroadCastChannel ( AbstractCanvasItem::TId id,
const iv::types::logic::ComponentType & componentType,
const std::string & name,
std::optional< iv::types::unitId > unitId )

◆ ~LogicComponentBroadCastChannel()

LogicComponentBroadCastChannel::~LogicComponentBroadCastChannel ( )
overridedefault

Member Function Documentation

◆ addConnectionPointInput()

void CLogicsComponent::addConnectionPointInput ( const std::shared_ptr< CLogicsConnectionPoint > & connectionPoint)
inherited

◆ addConnectionPointOutput()

void CLogicsComponent::addConnectionPointOutput ( const std::shared_ptr< CLogicsConnectionPoint > & connectionPoint)
inherited

◆ addListenerClick()

void AbstractCanvasItem::addListenerClick ( std::unique_ptr< IListenerCanvasItemClick > listener)
inherited

◆ addListenerEnter()

void AbstractCanvasItem::addListenerEnter ( std::unique_ptr< IListenerCanvasItemEnter > listener)
inherited

◆ addListenerLeave()

void AbstractCanvasItem::addListenerLeave ( std::unique_ptr< IListenerCanvasItemLeave > listener)
inherited

◆ addListenerMove()

void AbstractCanvasItem::addListenerMove ( std::unique_ptr< IListenerCanvasItemMove > listener)
inherited

◆ constantLogicStateToConstantFirmwareString()

std::string LogicComponentBroadCastChannel::constantLogicStateToConstantFirmwareString ( ) const
nodiscard

◆ enumGeneralType()

iv::logic::eGeneralType CLogicsComponent::enumGeneralType ( const std::string & strType)
staticinherited

◆ enumLogicsElementType()

iv::logic::eLogicsElementType AbstractLogicsElement::enumLogicsElementType ( const std::string & strType)
staticinherited

◆ firmwareValue()

uint32_t LogicComponentBroadCastChannel::firmwareValue ( ) const
nodiscard

◆ getCanvasItem() [1/2]

ICanvasItem * AbstractCanvasItem::getCanvasItem ( )
inherited

◆ getCanvasItem() [2/2]

const ICanvasItem * AbstractCanvasItem::getCanvasItem ( ) const
nodiscardinherited

◆ getChannelId()

iv::types::logic::channelGlobalId LogicComponentBroadCastChannel::getChannelId ( ) const
nodiscard

◆ getComponentFinalType()

const iv::types::logic::componentFinalType & CLogicsComponent::getComponentFinalType ( ) const
nodiscardinherited

◆ getComponentGeneralType()

const iv::logic::eGeneralType & CLogicsComponent::getComponentGeneralType ( ) const
nodiscardinherited

◆ getComponentType()

const iv::types::logic::componentType & CLogicsComponent::getComponentType ( ) const
nodiscardinherited

◆ getComponentTypeTuple()

const iv::types::logic::ComponentType & CLogicsComponent::getComponentTypeTuple ( ) const
nodiscardinherited

◆ getConnectionPoint()

std::shared_ptr< CLogicsConnectionPoint > CLogicsComponent::getConnectionPoint ( iv::logic::eDBBlockParamType pointType,
iv::types::logic::paramNumber paramNum )
nodiscardinherited

◆ getConnectionPointPosition()

CLogicsComponentOthers::ECPPosition CLogicsComponentOthers::getConnectionPointPosition ( ) const
nodiscardinherited

◆ getConnectionPoints()

std::set< std::shared_ptr< CLogicsConnectionPoint > > CLogicsComponent::getConnectionPoints ( ) const
nodiscardinherited

◆ getCurrentDrawingMode()

const AbstractCanvasItem::TTupleDrawingMode & AbstractCanvasItem::getCurrentDrawingMode ( ) const
nodiscardinherited

◆ getDefaultSize()

std::optional< iv::types::Size > AbstractLogicsElement::getDefaultSize ( ) const
virtualinherited

◆ getDescriptiveText()

std::string LogicComponentBroadCastChannel::getDescriptiveText ( ) const
nodiscardoverridevirtual

Reimplemented from AbstractLogicsElement.

◆ getElementName()

const std::string & AbstractLogicsElement::getElementName ( ) const
nodiscardinherited

◆ getElementType()

const iv::logic::eLogicsElementType & AbstractLogicsElement::getElementType ( ) const
nodiscardinherited

◆ getFirstInputConnectionPoint()

std::shared_ptr< CLogicsConnectionPoint > CLogicsComponent::getFirstInputConnectionPoint ( ) const
nodiscardinherited

◆ getFirstOutputConnectionPoint()

std::shared_ptr< CLogicsConnectionPoint > CLogicsComponent::getFirstOutputConnectionPoint ( ) const
nodiscardinherited

◆ getGlobalPosition2d()

const AbstractCanvasItem::TPosition2d & AbstractCanvasItem::getGlobalPosition2d ( ) const
nodiscardinherited

◆ getId()

AbstractCanvasItem::TId AbstractCanvasItem::getId ( ) const
nodiscardinherited

◆ getIndexOfConnectionForParam()

std::optional< uint32_t > CLogicsComponent::getIndexOfConnectionForParam ( iv::logic::eDBBlockParamType type,
iv::types::logic::paramNumber number ) const
protectedvirtualinherited

Reimplemented in CLogicsComponentExec.

◆ getInputConnectionPoint()

std::shared_ptr< CLogicsConnectionPoint > CLogicsComponent::getInputConnectionPoint ( uint32_t index)
nodiscardinherited

◆ getInputRefs()

CLogicsComponent::TMapIdConnPoint CLogicsComponent::getInputRefs ( )
inherited

◆ getInputRefsConst()

const CLogicsComponent::TMapIdConnPoint & CLogicsComponent::getInputRefsConst ( ) const
nodiscardinherited

◆ getLinkedItems()

std::vector< std::shared_ptr< AbstractCanvasItem > > CLogicsComponent::getLinkedItems ( )
overridevirtualinherited

Reimplemented from AbstractLogicsElement.

◆ getMainText()

std::string AbstractLogicsElement::getMainText ( ) const
nodiscardvirtualinherited

◆ getOutputConnectionPoint()

std::shared_ptr< CLogicsConnectionPoint > CLogicsComponent::getOutputConnectionPoint ( uint32_t index)
nodiscardinherited

◆ getOutputRefs()

CLogicsComponent::TMapIdConnPoint CLogicsComponent::getOutputRefs ( )
inherited

◆ getOutputRefsConst()

const CLogicsComponent::TMapIdConnPoint & CLogicsComponent::getOutputRefsConst ( ) const
nodiscardinherited

◆ getRedrawFlag()

bool AbstractCanvasItem::getRedrawFlag ( ) const
nodiscardinherited

◆ hasExecutionOrder()

bool CLogicsComponent::hasExecutionOrder ( const iv::types::logic::ComponentType & componentTypeTuple)
staticinherited

◆ indexArea()

uint32_t LogicComponentBroadCastChannel::indexArea ( ) const

◆ isAllConnected()

bool CLogicsComponent::isAllConnected ( ) const
nodiscardinherited

◆ isExecBlock()

bool CLogicsComponent::isExecBlock ( const iv::types::logic::ComponentType & componentTypeTuple)
staticinherited

◆ isLibraryBlock()

bool CLogicsComponent::isLibraryBlock ( const iv::types::logic::ComponentType & componentTypeTuple)
staticinherited

◆ maxText()

std::string LogicComponentBroadCastChannel::maxText ( ) const
nodiscardoverridevirtual

Reimplemented from AbstractLogicsElement.

◆ numberOfInputs()

size_t CLogicsComponent::numberOfInputs ( ) const
nodiscardinherited

◆ numberOfOutputs()

size_t CLogicsComponent::numberOfOutputs ( ) const
nodiscardinherited

◆ read()

iv::file::xml::node LogicComponentBroadCastChannel::read ( const iv::file::xml::node & node)
overridevirtual

Reimplemented from CLogicsComponentOthers.

◆ readLogicsComponentTypeTuple()

iv::types::logic::ComponentType CLogicsComponent::readLogicsComponentTypeTuple ( const iv::file::xml::node & node)
staticinherited

◆ readLogicsElementType()

iv::logic::eLogicsElementType AbstractLogicsElement::readLogicsElementType ( const iv::file::xml::node & node)
staticinherited

◆ resetLinkedItems()

void CLogicsComponent::resetLinkedItems ( )
overridevirtualinherited

Reimplemented from AbstractLogicsElement.

◆ runListenersClick()

void AbstractCanvasItem::runListenersClick ( CEventCanvasButton * evtCanvasButton)
inherited

◆ runListenersEnter()

void AbstractCanvasItem::runListenersEnter ( )
inherited

◆ runListenersLeave()

void AbstractCanvasItem::runListenersLeave ( )
inherited

◆ runListenersMove()

void AbstractCanvasItem::runListenersMove ( CEventCanvasButton * evtCanvasButton)
inherited

◆ save()

iv::file::xml::node LogicComponentBroadCastChannel::save ( iv::file::xml::node & node) const
overridevirtual

Reimplemented from CLogicsComponentOthers.

◆ setCanvasItem()

void AbstractCanvasItem::setCanvasItem ( ICanvasItem * canvasItem)
inherited

◆ setConnectionPointPosition()

void CLogicsComponentOthers::setConnectionPointPosition ( ECPPosition cPPosition)
inherited

◆ setCurrentMarkMode()

void AbstractCanvasItem::setCurrentMarkMode ( EMarkMode markMode)
inherited

◆ setCurrentStandoutMode()

void AbstractCanvasItem::setCurrentStandoutMode ( EStandOutMode standoutMode)
inherited

◆ setGlobalPosition2d()

void AbstractCanvasItem::setGlobalPosition2d ( const TPosition2d & position2d)
inherited

◆ setId()

void AbstractCanvasItem::setId ( TId id)
inherited

◆ setIndexArea()

void LogicComponentBroadCastChannel::setIndexArea ( uint32_t indexArea)

◆ setRedrawFlag()

void AbstractCanvasItem::setRedrawFlag ( bool redraw)
inherited

◆ strGeneralType()

std::string CLogicsComponent::strGeneralType ( iv::logic::eGeneralType generalType)
staticinherited

◆ strGuiOthers()

std::string CLogicsComponentOthers::strGuiOthers ( iv::logic::eOthers otherBlock,
bool shortName = false )
staticinherited

◆ strLogicsElementType()

std::string AbstractLogicsElement::strLogicsElementType ( iv::logic::eLogicsElementType type)
staticinherited

◆ toString()

std::string LogicComponentBroadCastChannel::toString ( ) const
nodiscard

◆ updateLinkedItems()

void CLogicsComponent::updateLinkedItems ( )
overridevirtualinherited

Reimplemented from AbstractLogicsElement.

Member Data Documentation

◆ kInvalidCanvasItemId

const TId AbstractCanvasItem::kInvalidCanvasItemId = 0
inlinestaticinherited

◆ kPrvKeySectionLogicsElementData

std::string_view AbstractLogicsElement::kPrvKeySectionLogicsElementData = "LogicsElementData"
inlinestaticconstexprinherited

◆ kStartingCanvasItemId

const TId AbstractCanvasItem::kStartingCanvasItemId = 1
inlinestaticinherited

◆ kZeroPosition

const TPosition2d AbstractCanvasItem::kZeroPosition = {0., 0.}
inlinestaticinherited

◆ m_broadCastChannelType

iv::logic::eBroadCastChannelType LogicComponentBroadCastChannel::m_broadCastChannelType

◆ m_canvasItem

ICanvasItem* AbstractCanvasItem::m_canvasItem
privateinherited

◆ m_componentTypeTuple

iv::types::logic::ComponentType CLogicsComponent::m_componentTypeTuple
privateinherited

◆ m_cPPosition

ECPPosition CLogicsComponentOthers::m_cPPosition
privateinherited

◆ m_currentDrawingMode

TTupleDrawingMode AbstractCanvasItem::m_currentDrawingMode
privateinherited

◆ m_globalPosition2d

TPosition2d AbstractCanvasItem::m_globalPosition2d
privateinherited

◆ m_id

TId AbstractCanvasItem::m_id
privateinherited

◆ m_indexArea

uint32_t LogicComponentBroadCastChannel::m_indexArea
private

◆ m_inputRefs

TMapIdConnPoint CLogicsComponent::m_inputRefs
privateinherited

◆ m_listenersItemClick

std::vector<std::unique_ptr<IListenerCanvasItemClick> > AbstractCanvasItem::m_listenersItemClick
privateinherited

◆ m_listenersItemEnter

std::vector<std::unique_ptr<IListenerCanvasItemEnter> > AbstractCanvasItem::m_listenersItemEnter
privateinherited

◆ m_listenersItemLeave

std::vector<std::unique_ptr<IListenerCanvasItemLeave> > AbstractCanvasItem::m_listenersItemLeave
privateinherited

◆ m_listenersItemMove

std::vector<std::unique_ptr<IListenerCanvasItemMove> > AbstractCanvasItem::m_listenersItemMove
privateinherited

◆ m_logicsElementType

iv::logic::eLogicsElementType AbstractLogicsElement::m_logicsElementType
privateinherited

◆ m_name

std::string AbstractLogicsElement::m_name
privateinherited

◆ m_outputRefs

TMapIdConnPoint CLogicsComponent::m_outputRefs
privateinherited

◆ m_redrawFlag

bool AbstractCanvasItem::m_redrawFlag
privateinherited

◆ m_unitId

std::optional<iv::types::unitId> LogicComponentBroadCastChannel::m_unitId
private

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