Stage.h 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. #pragma once
  2. #include "Hole.h"
  3. namespace OTSDATA {
  4. class __declspec(dllexport) CStage : public xmls::ISlo
  5. {
  6. /*protected:
  7. DECLARE_SERIAL(CStage)*/
  8. public:
  9. CStage(); // constructor
  10. CStage(const CStage&); // copy constructor
  11. CStage(CStage*); // copy constructor
  12. CStage& operator=(const CStage&); // =operator
  13. BOOL operator==(const CStage&); // ==operator
  14. virtual ~CStage(); // destructor
  15. // serialization
  16. void Serialize(bool isStoring, tinyxml2::XMLDocument * classDoc, tinyxml2::XMLElement * rootNode);
  17. // stage name
  18. CString GetName() { return m_strName; }
  19. void SetName(CString a_strName) { m_strName = a_strName; }
  20. // boundary
  21. CDomainPtr GetBoundary() { return m_poBourary; }
  22. void SetBoundary(CDomainPtr a_poBourary);
  23. // std
  24. CDomainPtr GetSTD() { return m_poSTD; }
  25. void SetSTD(CDomainPtr a_poSTD);
  26. // sample holes list
  27. CHolesList& GetHoleList() { return m_listHoles; }
  28. void SetHoleList(CHolesList& a_plistHoles, BOOL a_bClear = TRUE);
  29. CHolePtr GetHoleByIndex(int a_nIndex);
  30. CHolePtr GetHoleByName(CString a_strHoleName);
  31. protected:
  32. // cleanup
  33. void Cleanup();
  34. // initialization
  35. void Init();
  36. // duplication
  37. void Duplicate(const CStage& a_oSource);
  38. // stage name
  39. CString m_strName;
  40. // boundary
  41. CDomainPtr m_poBourary;
  42. // std
  43. CDomainPtr m_poSTD;
  44. // sample holes list
  45. CHolesList m_listHoles;
  46. };
  47. typedef std::shared_ptr<CStage> CStagePtr;
  48. typedef std::vector<CStagePtr> CStagesList;
  49. }