STDdata.cs 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. namespace SpectrumSTDEditor
  7. {
  8. public class STDdata
  9. {
  10. //string s_STDId = "";
  11. string s_StrName = "";
  12. string s_Color = "000000";
  13. //string s_KeyElementList = "";
  14. //string s_SubElementList = "";
  15. //string s_UsingImgPropertyList = "";
  16. //string s_UsingOtherPropertyList = "";
  17. //string s_Expression = "";
  18. string s_Hardness = "";
  19. string s_Density = "";
  20. //string s_Electrical_conductivity = "";
  21. string s_BSE = "";
  22. string s_Formula = "";
  23. string s_Element = "";
  24. //string s_GroupId = "0";
  25. string s_OrderId = "";
  26. //bool b_IfElementAnalysis = true;
  27. string s_ChineseName = "";
  28. private byte[] xrayData;
  29. //public string STDId
  30. //{
  31. // set { s_STDId = value; }
  32. // get { return s_STDId; }
  33. //}
  34. public string Hardness
  35. {
  36. set { s_Hardness = value; }
  37. get { return s_Hardness; }
  38. }
  39. public string Density
  40. {
  41. set { s_Density = value; }
  42. get { return s_Density; }
  43. }
  44. //public string Electrical_conductivity
  45. //{
  46. // set { s_Electrical_conductivity = value; }
  47. // get { return s_Electrical_conductivity; }
  48. //}
  49. //灰度
  50. public string BSE
  51. {
  52. set { s_BSE = value; }
  53. get { return s_BSE; }
  54. }
  55. public string Formula
  56. {
  57. set { s_Formula = value; }
  58. get { return s_Formula; }
  59. }
  60. public string Element
  61. {
  62. set { s_Element = value; }
  63. get { return s_Element; }
  64. }
  65. public string StrName
  66. {
  67. set { s_StrName = value; }
  68. get { return s_StrName; }
  69. }
  70. public string Color
  71. {
  72. set { s_Color = value; }
  73. get { return s_Color; }
  74. }
  75. //public string KeyElementList
  76. //{
  77. // set { s_KeyElementList = value; }
  78. // get { return s_KeyElementList; }
  79. //}
  80. //public string SubElementList
  81. //{
  82. // set { s_SubElementList = value; }
  83. // get { return s_SubElementList; }
  84. //}
  85. //public string UsingImgPropertyList
  86. //{
  87. // set { s_UsingImgPropertyList = value; }
  88. // get { return s_UsingImgPropertyList; }
  89. //}
  90. //public string UsingOtherPropertyList
  91. //{
  92. // set { s_UsingOtherPropertyList = value; }
  93. // get { return s_UsingOtherPropertyList; }
  94. //}
  95. //public string Expression
  96. //{
  97. // set { s_Expression = value; }
  98. // get { return s_Expression; }
  99. //}
  100. //public string GroupId
  101. //{
  102. // set { s_GroupId = value; }
  103. // get { return s_GroupId; }
  104. //}
  105. public string OrderId
  106. {
  107. set { s_OrderId = value; }
  108. get { return s_OrderId; }
  109. }
  110. //public bool IfElementAnalysis
  111. //{
  112. // set { b_IfElementAnalysis = value; }
  113. // get { return b_IfElementAnalysis; }
  114. //}
  115. public string ChineseName { get => s_ChineseName; set => s_ChineseName = value; }
  116. public byte[] XrayData { get => xrayData; set => xrayData = value; }
  117. public bool Equals(STDdata a_oSource)
  118. {
  119. return (Hardness == a_oSource.Hardness) &&
  120. (Density == a_oSource.Density) &&
  121. //(Electrical_conductivity == a_oSource.Electrical_conductivity) &&
  122. (BSE == a_oSource.BSE) &&
  123. (Formula == a_oSource.Formula) &&
  124. (Element == a_oSource.Element) &&
  125. (StrName == a_oSource.StrName) &&
  126. (Color == a_oSource.Color) &&
  127. //(KeyElementList == a_oSource.KeyElementList) &&
  128. //(SubElementList == a_oSource.SubElementList) &&
  129. //(UsingImgPropertyList == a_oSource.UsingImgPropertyList) &&
  130. //(UsingOtherPropertyList == a_oSource.UsingOtherPropertyList) &&
  131. //(Expression == a_oSource.Expression) &&
  132. //(GroupId == a_oSource.GroupId) &&
  133. //(OrderId == a_oSource.OrderId) &&
  134. //(IfElementAnalysis == a_oSource.IfElementAnalysis)
  135. (ChineseName == a_oSource.ChineseName);
  136. }
  137. public object Clone(STDdata a_oSource)
  138. {
  139. STDdata MySTDdata = new STDdata();
  140. MySTDdata.Hardness = a_oSource.Hardness ;
  141. MySTDdata.Density = a_oSource.Density ;
  142. //MySTDdata.Electrical_conductivity = a_oSource.Electrical_conductivity ;
  143. MySTDdata.BSE = a_oSource.BSE ;
  144. MySTDdata.Formula = a_oSource.Formula ;
  145. MySTDdata.Element = a_oSource.Element ;
  146. MySTDdata.StrName = a_oSource.StrName ;
  147. MySTDdata.Color = a_oSource.Color ;
  148. //MySTDdata.KeyElementList = a_oSource.KeyElementList ;
  149. //MySTDdata.SubElementList = a_oSource.SubElementList ;
  150. //MySTDdata.UsingImgPropertyList = a_oSource.UsingImgPropertyList ;
  151. //MySTDdata.UsingOtherPropertyList = a_oSource.UsingOtherPropertyList ;
  152. //MySTDdata.Expression = a_oSource.Expression ;
  153. //MySTDdata.GroupId = a_oSource.GroupId ;
  154. //MySTDdata.OrderId = a_oSource.OrderId;
  155. //MySTDdata.IfElementAnalysis = a_oSource.IfElementAnalysis;
  156. MySTDdata.ChineseName = a_oSource.ChineseName;
  157. return MySTDdata;
  158. }
  159. }
  160. }