LibrePCB Developers Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
BI_NetLine Class Referencefinal

The BI_NetLine class. More...

#include <bi_netline.h>

+ Inheritance diagram for BI_NetLine:
+ Collaboration diagram for BI_NetLine:

Public Member Functions

 BI_NetLine ()=delete
 
 BI_NetLine (const BI_NetLine &other)=delete
 
 BI_NetLine (BI_NetSegment &segment, const BI_NetLine &other, BI_NetLineAnchor &startPoint, BI_NetLineAnchor &endPoint)
 
 BI_NetLine (BI_NetSegment &segment, const SExpression &node, const QHash< Uuid, QString > &netpointLayerMap, const QHash< Uuid, BI_NetLineAnchor * > &netPointAnchorMap)
 
 BI_NetLine (BI_NetSegment &segment, BI_NetLineAnchor &startPoint, BI_NetLineAnchor &endPoint, GraphicsLayer &layer, const PositiveLength &width)
 
 ~BI_NetLine () noexcept
 
BI_NetSegmentgetNetSegment () const noexcept
 
const UuidgetUuid () const noexcept
 
GraphicsLayergetLayer () const noexcept
 
const PositiveLengthgetWidth () const noexcept
 
BI_NetLineAnchorgetStartPoint () const noexcept
 
BI_NetLineAnchorgetEndPoint () const noexcept
 
BI_NetLineAnchorgetOtherPoint (const BI_NetLineAnchor &firstPoint) const noexcept
 
NetSignalgetNetSignalOfNetSegment () const noexcept
 
bool isSelectable () const noexceptoverride
 
Path getSceneOutline (const Length &expansion=Length(0)) const noexcept
 
void setLayer (GraphicsLayer &layer)
 
void setWidth (const PositiveLength &width) noexcept
 
void addToBoard () override
 
void removeFromBoard () override
 
void updateLine () noexcept
 
void serialize (SExpression &root) const override
 Serialize the object into an existing S-Expression node. More...
 
Type_t getType () const noexceptoverride
 
const PointgetPosition () const noexceptoverride
 
bool getIsMirrored () const noexceptoverride
 
QPainterPath getGrabAreaScenePx () const noexceptoverride
 
void setSelected (bool selected) noexceptoverride
 
BI_NetLineoperator= (const BI_NetLine &rhs)=delete
 
- Public Member Functions inherited from BI_Base
 BI_Base ()=delete
 
 BI_Base (const BI_Base &other)=delete
 
 BI_Base (Board &board) noexcept
 
virtual ~BI_Base () noexcept
 
ProjectgetProject () const noexcept
 
CircuitgetCircuit () const noexcept
 
BoardgetBoard () const noexcept
 
virtual bool isAddedToBoard () const noexcept
 
virtual bool isSelected () const noexcept
 
BI_Baseoperator= (const BI_Base &rhs)=delete
 
- Public Member Functions inherited from SerializableObject
 SerializableObject () noexcept
 
virtual ~SerializableObject () noexcept
 
SExpression serializeToDomElement (const QString &name) const
 Serialize the object to a new S-Expression node. More...
 

Private Member Functions

void init ()
 
BI_NetLineAnchordeserializeAnchor (const SExpression &root, const QString &oldKey, const QString &newKey, const QHash< Uuid, BI_NetLineAnchor * > &netPointAnchorMap, Uuid &oldPointUuid) const
 
void serializeAnchor (SExpression &root, BI_NetLineAnchor *anchor) const
 

Private Attributes

BI_NetSegmentmNetSegment
 
QScopedPointer< BGI_NetLinemGraphicsItem
 
Point mPosition
 the center of startpoint and endpoint More...
 
QMetaObject::Connection mHighlightChangedConnection
 
Uuid mUuid
 
BI_NetLineAnchormStartPoint
 
BI_NetLineAnchormEndPoint
 
GraphicsLayermLayer
 
PositiveLength mWidth
 

Additional Inherited Members

- Public Types inherited from BI_Base
enum  Type_t
 
- Static Public Member Functions inherited from SerializableObject
template<typename T >
static void serializeObjectContainer (SExpression &root, const T &container, const QString &itemName)
 
template<typename T >
static void serializePointerContainer (SExpression &root, const T &container, const QString &itemName)
 
template<typename T >
static void serializePointerContainerUuidSorted (SExpression &root, const T &container, const QString &itemName)
 
- Protected Member Functions inherited from BI_Base
void addToBoard (QGraphicsItem *item) noexcept
 
void removeFromBoard (QGraphicsItem *item) noexcept
 
- Protected Attributes inherited from BI_Base
BoardmBoard
 

Detailed Description

The BI_NetLine class.

Constructor & Destructor Documentation

BI_NetLine ( )
delete
BI_NetLine ( const BI_NetLine other)
delete
BI_NetLine ( BI_NetSegment segment,
const BI_NetLine other,
BI_NetLineAnchor startPoint,
BI_NetLineAnchor endPoint 
)

+ Here is the call graph for this function:

BI_NetLine ( BI_NetSegment segment,
const SExpression node,
const QHash< Uuid, QString > &  netpointLayerMap,
const QHash< Uuid, BI_NetLineAnchor * > &  netPointAnchorMap 
)

+ Here is the call graph for this function:

BI_NetLine ( BI_NetSegment segment,
BI_NetLineAnchor startPoint,
BI_NetLineAnchor endPoint,
GraphicsLayer layer,
const PositiveLength width 
)

+ Here is the call graph for this function:

~BI_NetLine ( )
noexcept

Member Function Documentation

BI_NetSegment& getNetSegment ( ) const
inlinenoexcept

+ Here is the caller graph for this function:

const Uuid& getUuid ( ) const
inlinenoexcept

+ Here is the caller graph for this function:

GraphicsLayer& getLayer ( ) const
inlinenoexcept

+ Here is the caller graph for this function:

const PositiveLength& getWidth ( ) const
inlinenoexcept

+ Here is the caller graph for this function:

BI_NetLineAnchor& getStartPoint ( ) const
inlinenoexcept

+ Here is the caller graph for this function:

BI_NetLineAnchor& getEndPoint ( ) const
inlinenoexcept

+ Here is the caller graph for this function:

BI_NetLineAnchor * getOtherPoint ( const BI_NetLineAnchor firstPoint) const
noexcept

+ Here is the caller graph for this function:

NetSignal & getNetSignalOfNetSegment ( ) const
noexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool isSelectable ( ) const
overridevirtualnoexcept

Implements BI_Base.

+ Here is the caller graph for this function:

Path getSceneOutline ( const Length expansion = Length(0)) const
noexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void setLayer ( GraphicsLayer layer)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void setWidth ( const PositiveLength width)
noexcept

+ Here is the caller graph for this function:

void addToBoard ( )
overridevirtual

Implements BI_Base.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void removeFromBoard ( )
overridevirtual

Implements BI_Base.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void updateLine ( )
noexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void serialize ( SExpression root) const
overridevirtual

Serialize the object into an existing S-Expression node.

This method inserts/appends all attributes and childs of the object to an existing S-Expression node. The content which already exists in the given S-Expression node will not be removed.

Note
The generated S-Expression node has always the format of the application's major version (it's not possible to generate DOMs of older versions).
Parameters
rootThe target DOM root node
Exceptions
ExceptionThis method throws an exception if an error occurs.

Implements SerializableObject.

+ Here is the call graph for this function:

Type_t getType ( ) const
inlineoverridevirtualnoexcept

Implements BI_Base.

const Point& getPosition ( ) const
inlineoverridevirtualnoexcept

Implements BI_Base.

+ Here is the caller graph for this function:

bool getIsMirrored ( ) const
inlineoverridevirtualnoexcept

Implements BI_Base.

QPainterPath getGrabAreaScenePx ( ) const
overridevirtualnoexcept

Implements BI_Base.

+ Here is the caller graph for this function:

void setSelected ( bool  selected)
overridevirtualnoexcept

Reimplemented from BI_Base.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

BI_NetLine& operator= ( const BI_NetLine rhs)
delete
void init ( )
private

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

BI_NetLineAnchor * deserializeAnchor ( const SExpression root,
const QString &  oldKey,
const QString &  newKey,
const QHash< Uuid, BI_NetLineAnchor * > &  netPointAnchorMap,
Uuid oldPointUuid 
) const
private

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void serializeAnchor ( SExpression root,
BI_NetLineAnchor anchor 
) const
private

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Member Data Documentation

BI_NetSegment& mNetSegment
private
QScopedPointer<BGI_NetLine> mGraphicsItem
private
Point mPosition
private

the center of startpoint and endpoint

QMetaObject::Connection mHighlightChangedConnection
private
Uuid mUuid
private
BI_NetLineAnchor* mStartPoint
private
BI_NetLineAnchor* mEndPoint
private
GraphicsLayer* mLayer
private
PositiveLength mWidth
private

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