OTSSampleClr.h 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213
  1. #pragma once
  2. #include "MsrParamsClr.h"
  3. #include "DomainClr.h"
  4. #include "SEMDataMsrClr.h"
  5. #include "MsrSampleStatusClr.h"
  6. #include "MsrResultsClr.h"
  7. #include "OTSSample.h"
  8. #include "PropItemClr.h"
  9. #include <OTSSample.h>
  10. //#include "ProjMgrClr.h"
  11. namespace OTSCLRINTERFACE {
  12. using namespace System;
  13. using namespace OTSMODEL;
  14. //using namespace Newtonsoft::Json::Linq;
  15. ref class CProjMgrClr;
  16. typedef System::Collections::Generic::List<String^> CStringListClr;
  17. public ref class COTSSampleClr : public Object
  18. {
  19. public:
  20. COTSSampleClr(); // constructor
  21. COTSSampleClr(COTSSamplePtr); // copy constructor
  22. ~COTSSampleClr();
  23. !COTSSampleClr();
  24. //JObject^ GetJSONProperty();
  25. COTSSamplePtr GetSamplePtr();
  26. // name
  27. String^ GetName() { return gcnew String(theSample->get()->GetName()); }
  28. void SetName(String^ a_strName) { theSample->get()->SetName(CString(a_strName)); }
  29. // sample hole
  30. String^ GetSampleHoleName() { return gcnew String(theSample->get()->GetSampleHoleName ()); }
  31. void SetSampleHoleName(String^ a_strHoleName) { theSample->get()->SetSampleHoleName (CString(a_strHoleName)); }
  32. // param lock
  33. bool GetParamLock() { return theSample->get()->GetParamLock (); }
  34. void SetParamLock(bool a_bParamLock) { theSample->get()->SetParamLock (a_bParamLock); }
  35. // switch
  36. bool GetSwitch() { return theSample->get()->GetSwitch (); }
  37. void SetSwitch(bool a_bSwitch) { theSample->get()->SetSwitch (a_bSwitch); }
  38. // measurement parameter
  39. CMsrParamsClr^ GetMsrParams() { return gcnew CMsrParamsClr(theSample->get()->GetMsrParams()); }
  40. void SetMsrParams(CMsrParamsClr^ a_poMsrParams) { theSample->get()->SetMsrParams(a_poMsrParams->GetMsrParamsPtr()); }
  41. // measurement area
  42. CDomainClr^ GetMsrArea() { return gcnew CDomainClr(theSample->get()->GetMsrArea()); }
  43. void SetMsrArea(CDomainClr^ a_poMsrArea)
  44. {
  45. theSample->get()->SetMsrArea(a_poMsrArea->GetDomainPtr());
  46. }
  47. // SEM data (measurement)
  48. CSEMDataMsrClr^ GetSEMDataMsr() { return gcnew CSEMDataMsrClr(theSample->get()->GetSEMDataMsr ()); }
  49. void SetSEMDataMsr(CSEMDataMsrClr^ a_poSEMDataMsr) { theSample->get()->SetSEMDataMsr(a_poSEMDataMsr->GetSEMDataMsrPtr()); }
  50. // measure status
  51. CMsrSampleStatusClr^ GetMsrStatus() { return gcnew CMsrSampleStatusClr(theSample->get()->GetMsrStatus()); }
  52. void SetMsrStatus(CMsrSampleStatusClr^ a_poMsrStatus) { theSample->get()->SetMsrStatus(a_poMsrStatus->GetMsrSampleStatusPtr()); }
  53. // measure results
  54. CMsrResultsClr^ GetMsrResults() { return gcnew CMsrResultsClr(theSample->get()->GetMsrResults()) ; }
  55. void SetMsrResults(CMsrResultsClr^ a_poMsrResults) { theSample->get()->SetMsrResults(a_poMsrResults->GetMsrResultsPtr()); }
  56. // has measure results test
  57. bool HasMeasureResult();
  58. //设置属性组
  59. // 输入:无
  60. // 输出:设置结果,bool, true:设置成功,false:设置失败
  61. //bool SetPropItemGrps();
  62. //根据索引获取属性组
  63. // 输入:int 索引值
  64. // 输出:CPropItemGrpClr 返回属性组
  65. //CPropItemGrpClr^ GetPropItemGrpByIndex(int a_nIndex);
  66. //
  67. ////根据属性组Id获取属性组
  68. //// 输入:int, id值
  69. //// 输出:CPropItemGrpClr 返回属性组
  70. //CPropItemGrpClr^ GetPropItemGrpById(int a_nId);
  71. //
  72. ////更新相关联属性组
  73. //// 输入:int, nId属性组id
  74. //// 输出:CPropItemGrpClr^ 返回属性组
  75. //CPropItemGrpClr^ UpdatePropItemGrp(int a_nId);
  76. ////根据属性Id获取属性
  77. //// 输入:int, 属性id
  78. //// 输出:CPropItemClr^ 返回的属性
  79. //CPropItemClr^ GetPropItemById(int a_nId);
  80. // BOOL data (1)
  81. //获取bool类型的数值
  82. // 输入:int :属性在属性组内id bool 返回的获取值
  83. // 输出: 获取结果, bool, true:成功,false:失败
  84. //bool GetPropBOOLData(int a_nId, bool% a_bValue);
  85. //
  86. ////设定属性值
  87. //// 输入:int,属性id ;bool,需要设定的值
  88. //// 输出:bool,设定结果,true,成功,false, 失败
  89. //bool SetPropBOOLData(int a_nId, bool a_bValue);
  90. //// int data (16)
  91. ////获取int类型的数值
  92. //// 输入:int :属性在属性组内id int 返回的获取值
  93. //// 输出: 获取结果, bool, true:成功,false:失败
  94. //bool GetPropIntData(int a_nId, int% a_nValue);
  95. //
  96. ////设定属性值
  97. //// 输入:int,属性id ;int,需要设定的值
  98. //// 输出:bool,设定结果,true,成功,false, 失败
  99. //bool SetPropIntData(int a_nId, int a_nValue);
  100. //// double data (4)
  101. ////获取double类型的数值
  102. //// 输入:int :属性在属性组内id double 返回的获取值
  103. //// 输出: 获取结果, bool, true:成功,false:失败
  104. //bool GetPropDoubleData(int a_nId, double% a_dValue);
  105. //
  106. ////设定属性值
  107. //// 输入:int,属性id ;double,需要设定的值
  108. //// 输出:bool,设定结果,true,成功,false, 失败
  109. //bool SetPropDoubleData(int a_nId, double a_dValue);
  110. //// string data (7)
  111. ////获取string类型的数值
  112. //// 输入:int :属性在属性组内id string 返回的获取值
  113. //// 输出: 获取结果, bool, true:成功,false:失败
  114. //bool GetPropStringData(int a_nId, String^% a_strValue);
  115. //
  116. ////设定属性值
  117. //// 输入:int,属性id ;string,需要设定的值
  118. //// 输出:bool,设定结果,true,成功,false, 失败
  119. //bool SetPropStringData(int a_nId, String^ a_strValue);
  120. //// combo data (7)
  121. ////获取Combo类型的数值
  122. //// 输入:int :属性在属性组内id Combo 返回的获取值
  123. //// 输出: 获取结果, bool, true:成功,false:失败
  124. //bool GetPropComboData(int a_nId, int% a_nValue);
  125. ////设定属性值
  126. //// 输入:int,属性id ;string,需要设定的值
  127. //// 输出:bool,设定结果,true,成功,false, 失败
  128. //bool SetPropComboData(int a_nId, int a_nValue);
  129. //
  130. ////获取Combo字符串类型
  131. //// 输入:int,属性id,List<string> 返回的字符串
  132. //// 输出:bool,设定结果,true,成功,false, 失败
  133. //bool GetPropComboStrings(int a_nId, CStringListClr^% a_listComboStrings);
  134. //// time data (2)
  135. ////获取Time类型的数值
  136. //// 输入:int :属性在属性组内id Time 返回的获取值
  137. //// 输出: 获取结果, bool, true:成功,false:失败
  138. //bool GetPropTimeData(int a_nId, DateTime^% a_oValue);
  139. ////设定属性值
  140. //// 输入:int,属性id, DateTime,返回值
  141. //// 输出:bool,设定结果,true,成功,false,失败
  142. //bool SetPropTimeData(int a_nId, DateTime^ a_oValue);
  143. //// time span data (1)
  144. ////获取TimeSpan类型的数值
  145. //// 输入:int :属性在属性组内id TimeSpan 返回的获取值
  146. //// 输出: 获取结果, bool, true:成功,false:失败
  147. //bool GetPropTimeSpanData(int a_nId, TimeSpan^% a_oValue);
  148. ////设定属性值
  149. //// 输入:int,属性id, TimeSpan,返回值
  150. //// 输出:bool,设定结果,true,成功,false,失败
  151. //bool SetPropTimeSpanData(int a_nId, TimeSpan^ a_oValue);
  152. //// file list data (2)
  153. //bool GetPropFileListData(int a_nId, String^% a_strFileName);
  154. //bool SetPropFileListData(int a_nId, String^ a_strFileName);
  155. ////获取相关属性值
  156. //// 输入:int,属性id, int,返回相关属性值
  157. //// 输出:bool,设定结果,true,成功,false,失败
  158. //// get related property item
  159. //bool GetRelatedPropItem(int a_nId, int% a_nRelatedPropId);
  160. ////获取相关属性组
  161. //// 输入:int,属性id, int,返回相关属性组
  162. //// 输出:bool,设定结果,true,成功,false,失败
  163. //// get related property item group
  164. //bool GetRelatedPropItemGrp(int a_nId, int% a_nRelatedPropGrpId);
  165. bool GetBSESize(int% a_nWidth, int% a_nHeight);
  166. private:
  167. COTSSamplePtr* theSample;
  168. };
  169. typedef System::Collections::Generic::List<COTSSampleClr^> COTSSamplesListClr;
  170. }