CVisualRegistryElement.h
Go to the documentation of this file.
1 #ifndef icmpstr_CVisualRegistryElement_included
2 #define icmpstr_CVisualRegistryElement_included
3 
4 
5 // Qt includes
6 #include <QtGui/QIcon>
7 
8 
9 // ACF includes
10 #include "i2d/CObject2dBase.h"
11 
12 #include "icomp/IRegistry.h"
14 #include "icomp/CRegistryElement.h"
15 
16 #include "icmpstr/icmpstr.h"
17 
18 
19 namespace icmpstr
20 {
21 
22 
24 {
25 public:
27 
29 
30  const icomp::IRegistry* GetRegistry() const;
31  const icomp::CComponentAddress& GetAddress() const;
32  const QByteArray& GetName() const;
33  void SetName(const QByteArray& name);
34  const QString& GetNote() const;
35  void SetNote(const QString& note);
36 
37  // overloaded (icomp::CRegistryElement)
38  void Initialize(
39  const icomp::IRegistry* parentPtr,
40  const icomp::CComponentAddress& address);
41 
42  // reimplemented (i2d::IObject2d)
43  virtual i2d::CVector2d GetCenter() const;
44  virtual void MoveCenterTo(const i2d::CVector2d& position);
45  virtual i2d::CRectangle GetBoundingBox() const;
46  virtual bool Transform(
47  const i2d::ITransformation2d& transformation,
48  i2d::ITransformation2d::ExactnessMode mode = i2d::ITransformation2d::EM_NONE,
49  double* errorFactorPtr = NULL);
50  virtual bool InvTransform(
51  const i2d::ITransformation2d& transformation,
52  i2d::ITransformation2d::ExactnessMode mode = i2d::ITransformation2d::EM_NONE,
53  double* errorFactorPtr = NULL);
54  virtual bool GetTransformed(
55  const i2d::ITransformation2d& transformation,
56  i2d::IObject2d& result,
57  i2d::ITransformation2d::ExactnessMode mode = i2d::ITransformation2d::EM_NONE,
58  double* errorFactorPtr = NULL) const;
59  virtual bool GetInvTransformed(
60  const i2d::ITransformation2d& transformation,
61  i2d::IObject2d& result,
62  i2d::ITransformation2d::ExactnessMode mode = i2d::ITransformation2d::EM_NONE,
63  double* errorFactorPtr = NULL) const;
64 
65 private:
66  i2d::CVector2d m_center;
67  const icomp::IRegistry* m_registryPtr;
68  icomp::CComponentAddress m_address;
69  QByteArray m_name;
70  QString m_note;
71 };
72 
73 
74 // inline methods
75 
77 {
78  return m_registryPtr;
79 }
80 
81 
83 {
84  return m_address;
85 }
86 
87 
88 inline const QByteArray& CVisualRegistryElement::GetName() const
89 {
90  return m_name;
91 }
92 
93 
94 } // namespace icmpstr
95 
96 
97 #endif
98 
99 
void SetNote(const QString &note)
const icomp::IRegistry * GetRegistry() const
virtual void MoveCenterTo(const i2d::CVector2d &position)
virtual i2d::CVector2d GetCenter() const
virtual bool Transform(const i2d::ITransformation2d &transformation, i2d::ITransformation2d::ExactnessMode mode=i2d::ITransformation2d::EM_NONE, double *errorFactorPtr=NULL)
const QString & GetNote() const
virtual bool GetTransformed(const i2d::ITransformation2d &transformation, i2d::IObject2d &result, i2d::ITransformation2d::ExactnessMode mode=i2d::ITransformation2d::EM_NONE, double *errorFactorPtr=NULL) const
const icomp::CComponentAddress & GetAddress() const
void SetName(const QByteArray &name)
void Initialize(const icomp::IRegistry *parentPtr, const icomp::CComponentAddress &address)
virtual bool GetInvTransformed(const i2d::ITransformation2d &transformation, i2d::IObject2d &result, i2d::ITransformation2d::ExactnessMode mode=i2d::ITransformation2d::EM_NONE, double *errorFactorPtr=NULL) const
const QByteArray & GetName() const
virtual bool InvTransform(const i2d::ITransformation2d &transformation, i2d::ITransformation2d::ExactnessMode mode=i2d::ITransformation2d::EM_NONE, double *errorFactorPtr=NULL)
virtual i2d::CRectangle GetBoundingBox() const

© 2007-2011 Witold Gantzke and Kirill Lepskiy