1 #ifndef PARSEAGLE_SYMBOL_H 2 #define PARSEAGLE_SYMBOL_H 3 4 #include <QtCore> 5 #include "../common/wire.h" 6 #include "../common/rectangle.h" 7 #include "../common/circle.h" 8 #include "../common/polygon.h" 9 #include "../common/text.h" 10 #include "pin.h" 11 12 namespace parseagle { 13 14 class DomElement; 15 16 class Symbol final 17 { 18 public: 19 20 // Constructors / Destructor 21 Symbol() = delete; 22 explicit Symbol(const DomElement& root); 23 ~Symbol() noexcept; 24 25 // Getters getName()26 QString getName() const noexcept {return mName;} getDescription()27 QString getDescription() const noexcept {return mDescription;} getWires()28 const QList<Wire>& getWires() const noexcept {return mWires;} getRectangles()29 const QList<Rectangle>& getRectangles() const noexcept {return mRectangles;} getCircles()30 const QList<Circle>& getCircles() const noexcept {return mCircles;} getPolygons()31 const QList<Polygon>& getPolygons() const noexcept {return mPolygons;} getTexts()32 const QList<Text>& getTexts() const noexcept {return mTexts;} getPins()33 const QList<Pin>& getPins() const noexcept {return mPins;} 34 35 36 private: 37 QString mName; 38 QString mDescription; 39 QList<Wire> mWires; 40 QList<Rectangle> mRectangles; 41 QList<Circle> mCircles; 42 QList<Polygon> mPolygons; 43 QList<Text> mTexts; 44 QList<Pin> mPins; 45 }; 46 47 } // namespace parseagle 48 49 #endif // PARSEAGLE_SYMBOL_H 50