#pragma once #include "OTSParticle.h" namespace OTSDATA { typedef enum class __declspec(dllexport) REPORT_GRID_DATA_TYPE { INVALID = -1, MIN = 0, STRING = 0, PARTICLE = 1, INT = 2, FLOAT = 3, MAX = 3 }REPORT_GRID_DATA_TYPE; typedef enum class __declspec(dllexport) REPORT_PARTICLE_GEN_INFO_GRID_CLUMN { INVALID = -1, MIN = 0, NAME = 0, IMAGE = 1, SIZE = 2, MAXLENGTH = 3, MINLENGTH =4, AXIALRATIO = 5, EquivalentCircleDiameter = 6, FerretDiameter = 7, PERP = 8, PERI = 9, INSCR = 10, MEAN = 11, ELONG = 12, ASPECT_ELONG = 13, ASPECT_MAX = 14, Orientation = 15, //ELEMENTLIST =3, MAX = 15 }REPORT_PARTICLE_GEN_INFO_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_PARTICLE_TRIO_INFO_GRID_CLUMN { INVALID = -1, MIN = 0, SIZE = 0,//Á£¼¶¼¶±ð Location = 1, MAX = 1 }REPORT_PARTICLE_TRIO_INFO_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_MEASURE_RESULT_INFO_GRID_CLUMN { INVALID = -1, MIN = 0, NAME = 0, INFORMATIN = 1, MAX = 1 }REPORT_MEASURE_RESULT_INFO_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_SORT_CLASS_GRID_CLUMN { INVALID = -1, MIN = 0, TOO_SMALL = 0, OVER_SIZE = 1, GRAY_NO_INTERS = 2, LOW_COUNT =3, NO_INTEREST_ELEMENTS = 4, NOT_INCLUSION_SIC = 5, NOT_INCLUSION_FEO = 6, NOT_IDENTIFIED = 7, IDENTIFIED = 8, MAX = 8 }REPORT_SORT_CLASS_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_SORT_KIND_GRID_CLUMN { INVALID = -1, MIN = 0, NOT_IDENTIFIED = 0, MAX = 0 }REPORT_SORT_KIND_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_SORT_SIZE_GRID_CLUMN { INVALID = -1, MIN = 0, USER_DENTIFIED = 0, MAX = 0 }REPORT_SORT_SIZE_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_PARTICLE_COMPONENT_GRID_CLUMN { INVALID = -1, MIN = 0, NAME = 0, COLOUR = 1, PARTICLE_NUM = 2, AVE_VALUE = 3, MAX_VALUE = 4, MAX = 4 }REPORT_PARTICLE_COMPONENT_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_ELEMENT_COMPONENT_GRID_CLUMN { INVALID = -1, MIN = 0, NAME = 0, NUM = 1, MAX = 1 }REPORT_ELEMENT_COMPONENT_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_AVE_ELEMENT_GRID_CLUMN { INVALID = -1, MIN = 0, PATICLE_TYPE = 0, AREA = 1, MAX = 1 }REPORT_AVE_ELEMENT_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_SIZE_DISTRIBUTION_GRID_CLUMN { INVALID = -1, MIN = 0, NAME = 0, COLOUR = 1, MAX = 1 }REPORT_SIZE_DISTRIBUTION_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_LEVEL_CLASS_GRID_CLUMN { INVALID = -1, MIN = 0, NAME = 0, WIDTH = 1, MAX = 1 }REPORT_LEVEL_CLASSN_GRID_CLUMN; typedef enum class __declspec(dllexport) REPORT_COMMON_FIVE_GRID_CLUMN { INVALID = -1, MIN = 0, SULFIDE_OXIDE = 0, OXIDE = 1, SULFIDE = 2, NITRIDES = 3, SPINEL = 4, MAX = 4 }REPORT_COMMON_FIVE_GRID_CLUMN; class __declspec(dllexport) CGridRow { public: // constructor CGridRow(); // constructor CGridRow(const CGridRow&); // copy constructor CGridRow(CGridRow*); // copy constructor CGridRow& operator=(const CGridRow&); // =operator BOOL operator==(const CGridRow&); // ==operator virtual ~CGridRow(); // destructor // data type REPORT_GRID_DATA_TYPE GetDataType() { return m_nDataType; } void SetDataType(REPORT_GRID_DATA_TYPE a_nDataType) { m_nDataType = a_nDataType; } // get string value CString GetStringValue() { return m_strValue; } void SetStringValue(CString a_strValue) { m_strValue = a_strValue; } COTSParticlePtr GetParticle() { return m_oParticle; } BOOL SetParticle(COTSParticlePtr a_oParticle); int GetIntValue() { return m_nIntValue; } void SetIntValue(int a_nIntValue) { m_nIntValue = a_nIntValue; } double GetDoubleValue() { return m_dFloatValue; } void SetDoubleValue(double a_dFloatValue) { m_dFloatValue = a_dFloatValue; } protected: // cleanup void Cleanup(); // initialization void Init(); // duplication void Duplicate(const CGridRow& a_oSource); // data type REPORT_GRID_DATA_TYPE m_nDataType; // string data CString m_strValue; // particle data COTSParticlePtr m_oParticle; // int value int m_nIntValue; // float value double m_dFloatValue; }; typedef std::shared_ptr __declspec(dllexport) CGridRowPtr; typedef std::vector __declspec(dllexport) CGridRowsList; class __declspec(dllexport) CGridColumn { public: // constructor CGridColumn(); // constructor CGridColumn(const CGridColumn&); // copy constructor CGridColumn(CGridColumn*); // copy constructor CGridColumn& operator=(const CGridColumn&); // =operator BOOL operator==(const CGridColumn&); // ==operator virtual ~CGridColumn(); // destructor CString GetName() { return m_strName; } void SetName(CString a_strName) { m_strName = a_strName; } CGridRowsList GetRowList() { return m_listGridRows; } BOOL SetGridRowsList(CGridRowsList a_listGridRows, BOOL a_bClear = TRUE); protected: // cleanup void Cleanup(); // initialization void Init(); // duplication void Duplicate(const CGridColumn& a_oSource); // name CString m_strName; // list of rows CGridRowsList m_listGridRows; }; typedef std::shared_ptr __declspec(dllexport) CGridColumnPtr; typedef std::vector __declspec(dllexport) CGridColumnsList; class __declspec(dllexport) CGridData { public: // constructor CGridData(); // constructor CGridData(const CGridData&); // copy constructor CGridData(CGridData*); // copy constructor CGridData& operator=(const CGridData&); // =operator BOOL operator==(const CGridData&); // ==operator virtual ~CGridData(); // destructor CGridColumnsList GetGridColumnList() { return m_listGridColumn; } BOOL SetGridColumnList(CGridColumnsList a_listGridColumn, BOOL a_bClear = TRUE); // data source id std::vector& GetDataSourceList() { return m_listDataSource; } BOOL SetDataSourceList(std::vector a_listDataSource); int GetDataSourceId() { return m_nDataSourceId; } BOOL SetDataSourceId(int a_nDataSourceId); protected: // cleanup void Cleanup(); // initialization void Init(); // duplication void Duplicate(const CGridData& a_oSource); // list of column CGridColumnsList m_listGridColumn; // data source id std::vector m_listDataSource; int m_nDataSourceId; }; typedef std::shared_ptr __declspec(dllexport) CGridDataPtr; typedef std::vector __declspec(dllexport) CGridDatasList; /*typedef std::vector __declspec(dllexport) CMultiGridDataList;*/ }