Power System Platform  2024w23a
Loading...
Searching...
No Matches
Node Class Reference

Node of a control element. This class manages the user interaction with the connection and control elements. More...

#include <ControlElement.h>

Public Types

enum class  NodeType { NODE_IN = 0 , NODE_OUT }
 

Public Member Functions

 Node (wxPoint2DDouble position=wxPoint2DDouble(0, 0), NodeType nodeType=NodeType::NODE_IN, double borderSize=0.0)
 
wxRect2DDouble GetRect () const
 
void SetRect (wxRect2DDouble rect)
 
wxPoint2DDouble GetPosition () const
 
void SetPosition (wxPoint2DDouble position)
 
NodeType GetNodeType () const
 
void SetNodeType (NodeType nodeType)
 
double GetRadius () const
 
std::vector< wxPoint2DDouble > GetInTrianglePts () const
 
double GetAngle () const
 
void SetAngle (double angle)
 
void Rotate (bool clockwise=true)
 
void RotateTriPt (double angle)
 
void StartMove (wxPoint2DDouble position)
 
void Move (wxPoint2DDouble position)
 
bool Contains (wxPoint2DDouble position) const
 
bool IsConnected () const
 
void SetConnected (bool connected=true)
 
int GetID () const
 
void SetID (int id)
 
NodeGetCopy () const
 

Protected Attributes

int m_id = -1
 
wxRect2DDouble m_rect
 
NodeType m_nodeType
 
bool m_connected = false
 
wxPoint2DDouble m_moveStartPt
 
wxPoint2DDouble m_movePos
 
double m_radius = 3.0
 
std::vector< wxPoint2DDouble > m_triPts
 
double m_angle = 0.0
 

Detailed Description

Node of a control element. This class manages the user interaction with the connection and control elements.

Author
Thales Lima Oliveira thale.nosp@m.s@uf.nosp@m.u.br
Date
05/10/2017

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