OTSSampleReportInfo.cs 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276
  1. using System;
  2. using System.Collections.Generic;
  3. //this module's enum definition are the shadow of the PropParam.h in the OTSMODEL(C++)
  4. //that means there're a same contrast definition in that module.that's because export an enum definition to C# from C++ through clr project is difficult.
  5. namespace OTSIncAReportApp.OTSSampleReportInfo
  6. {
  7. #region 相关枚举定义
  8. /// <summary>
  9. /// document标签标识
  10. /// </summary>
  11. ///
  12. public enum REPORT_GRID_DATA_TYPE
  13. {
  14. STRING = 0,
  15. PARTICLE = 1,
  16. INT = 2,
  17. FLOAT = 3
  18. }
  19. public enum DisplayPicutureType
  20. {
  21. //分析图
  22. AnalyzeImg = 0,
  23. //分析数据表
  24. AnalyzeDataTable = 1,
  25. //分析数据图
  26. AnalyzeDataChart = 2
  27. }
  28. public enum IMAGE_DISPLAY_TYPE
  29. {
  30. INVALID = -1,
  31. GENERAL = 0,
  32. IMAGE_GRID = 1,
  33. }
  34. public enum IMAGE_TYPE
  35. {
  36. INVALID = -1,
  37. BSE = 0,
  38. CLASSIFIED = 1,
  39. }
  40. public enum CALCULATE_TABLE_TYPE
  41. {
  42. INVALID = -1,
  43. MEASURE_INFO = 0,
  44. PARTICALE_GENE_INFO = 1,
  45. PARTICALE_COMP = 2,
  46. ELEMENT_COMP = 3,
  47. PARTICALE_SIZE_DISTRIBUTION = 4,
  48. AVE_ELEMENT_COMP = 5,
  49. GB_Method1 = 6,
  50. GB_Method2 = 7,
  51. ASTM = 8,
  52. DIN = 9
  53. }
  54. public enum CALCULATE_CHART_TYPE
  55. {
  56. INVALID = -1,
  57. COMMON_FIVE = 0,
  58. PARTICALE_COMP = 1,
  59. ELEMENT_COMP = 2,
  60. PARTICALE_SIZE_DISTRIBUTION = 3,
  61. TRIO_CHART = 4,
  62. }
  63. /// <summary>
  64. /// 显示计算方法的类型
  65. /// </summary>
  66. public enum ComputedColNameEnum
  67. {
  68. //最长直径
  69. MaxDiameter = 0,
  70. //最短直径
  71. MinDiameter = 1,
  72. //面积
  73. Area = 2,
  74. //等效圆直径
  75. EquivalentCircleDiameter = 3,
  76. //费雷特直径
  77. FerretDiameter = 4,
  78. //长短直径比
  79. DiameterRatio = 5
  80. }
  81. /// <summary>
  82. /// 标记分析物的类型
  83. /// </summary>
  84. public enum OTS_SOFT_PACKAGE_ID
  85. {
  86. //INVALID = -1,
  87. //MIN = 0,
  88. OTSIncA = 0, //夹杂物分析
  89. OTSPartA = 1, //颗粒度分析
  90. //MAX = 1
  91. };
  92. //国标信息表类型
  93. public enum GBTypeEnum
  94. {
  95. GB1 = 0,
  96. GB2 = 1
  97. }
  98. /// <summary>
  99. /// 样品属性值的名称
  100. /// </summary>
  101. public enum OTS_REPORT_PROP_GRID_ITEMS
  102. {
  103. INVALID = -1, //image 0\3\2\7\8\5\10\13
  104. MIN = 0,
  105. /// <summary>
  106. /// 数据源
  107. /// </summary>
  108. DATA_SOURCE = 0,
  109. /// <summary>
  110. /// 数据类型
  111. /// </summary>
  112. DATA_SOURCE_TYPE = 1,
  113. /// <summary>
  114. /// 分布图中,测量图类型
  115. /// </summary>
  116. IMAGE_TYPE = 2,
  117. /// <summary>
  118. /// 分布图中,测量图显示方式
  119. /// </summary>
  120. IMAGE_DISPLAY_TYPE = 3,
  121. /// <summary>
  122. ///
  123. /// </summary>
  124. MEASURE_DATA_TYPE = 4,
  125. /// <summary>
  126. /// 数据表,类型,查看什么表
  127. /// </summary>
  128. CALCULATE_TABLE_TYPE = 5,
  129. /// <summary>
  130. /// 数据图,类型,查看什么图
  131. /// </summary>
  132. CALCULATE_CHART_TYPE = 6,
  133. /// <summary>
  134. /// 颗粒类型,分布图中,全部,分析颗粒
  135. /// </summary>
  136. PARTICLE_TYPE = 7,
  137. /// <summary>
  138. ///
  139. /// </summary>
  140. STD_ID = 8,
  141. /// <summary>
  142. /// 粒级表
  143. /// </summary>
  144. GRAIN_SIZE_CLASS_TABLE = 9,
  145. /// <summary>
  146. /// 粒级,全部,自定义等
  147. /// </summary>
  148. GRAIN_SIZE_CLASS = 10,
  149. /// <summary>
  150. /// 粒级,最小颗粒
  151. /// </summary>
  152. GRAIN_SIZE_MIN = 11,
  153. /// <summary>
  154. /// 粒级,最大颗粒
  155. /// </summary>
  156. GRAIN_SIZE_MAX = 12,
  157. /// <summary>
  158. /// 尺寸计算法
  159. /// </summary>
  160. SIZE_CAL_METHOD_TYPE = 13,
  161. /// <summary>
  162. ///
  163. /// </summary>
  164. SIZE_GRID_CAL_METHOD_TYPE = 14,
  165. /// <summary>
  166. /// 三元相图模板
  167. /// </summary>
  168. TRIO_CHART_TYPE = 15,
  169. MAX = 16
  170. };
  171. /// <summary>
  172. /// 样品属性值的类型
  173. /// </summary>
  174. public enum OTS_ITEM_TYPES
  175. {
  176. BOOL = 0,
  177. DOUBLE = 2,
  178. COMBO = 4,
  179. };
  180. /// <summary>
  181. /// 消息框相关按钮样式
  182. /// </summary>
  183. public enum MessageBoxRev
  184. {
  185. DIALOG_YES = 0,
  186. DIALOG_NO = 1,
  187. DIALOG_CANCEL = 2
  188. };
  189. /// <summary>
  190. /// 精炼工艺方法
  191. /// </summary>
  192. public enum STEEL_TECHNOLOGY
  193. {
  194. GeneralProcessMode = 0,
  195. CaProcessMode = 1,
  196. MgProcessMode = 2,
  197. RareEarthMode = 3,
  198. };
  199. public enum MinValue
  200. {
  201. Min = -1
  202. }
  203. #endregion
  204. #region 相关结构类定义
  205. /// <summary>
  206. /// 树控件结构类,ReportApp 给 RetMgrWindow 发送添加测量结果文件的信息
  207. /// </summary>
  208. public class CTreeSampleParam
  209. {
  210. public string sSampleTitleName; //样品树显示的样品测量结果名称
  211. public List<OTS_REPORT_PROP_GRID_ITEMS> List_ShowGrid_Items; //Grid中需要显示的项集合
  212. public bool bSwitch; //样品执行开关
  213. };
  214. /// <summary>
  215. /// 测量结果属性数据类
  216. /// </summary>
  217. public class SampleData
  218. {
  219. public OTS_REPORT_PROP_GRID_ITEMS iItemId; //具体标题在哪行
  220. public String sSCaptionName; //样品标题名 //具体名称
  221. public OTS_ITEM_TYPES iItemValType; //样品标题名对应值的类型(bool,int~~~~)
  222. public bool bReadOnly; //值的类型(可读、不可读)
  223. public string sDescriptionInfo; //描述信息
  224. public Object itemVal; //样品标题名对应值
  225. public List<String> comboDownList = new List<string>(); //如果iSampleValType是combobox则在此处存储下拉列表
  226. }
  227. /// <summary>
  228. /// 测量结构信息类
  229. /// </summary>
  230. public class OTSSampleMeaInfo
  231. {
  232. #region 变量定义
  233. /// <summary>
  234. /// 样品属性数据
  235. /// </summary>
  236. public List<SampleData> SampleDataList;
  237. /// <summary>
  238. /// 树控件类,全局变量
  239. /// </summary>
  240. public CTreeSampleParam TSampleParam;
  241. /// <summary>
  242. /// 索引
  243. /// </summary>
  244. public int TabIndex;
  245. #endregion
  246. #region 构造函数
  247. /// <summary>
  248. /// 构造函数
  249. /// </summary>
  250. public OTSSampleMeaInfo()
  251. {
  252. SampleDataList = new List<SampleData>();
  253. TSampleParam = new CTreeSampleParam();
  254. }
  255. #endregion
  256. };
  257. #endregion
  258. }