MemberEntity.cs 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
  1. using System.Collections.Generic;
  2. namespace WingCloudServer.GeneralDocTools.Model
  3. {
  4. /// <summary>
  5. /// 注释实体
  6. /// </summary>
  7. public class MemberEntity
  8. {
  9. /// <summary>
  10. /// 参数名
  11. /// </summary>
  12. public string ParamName { get; set; } = string.Empty;
  13. /// <summary>
  14. /// 注释
  15. /// </summary>
  16. public string Summary { get; set; } = string.Empty;
  17. /// <summary>
  18. /// 方法注释用:返回内容的默认值,当返回简单类型时【bool,int,string等等】,默认值必填,如果非简单类型,则非不填;
  19. /// </summary>
  20. public string Value { get; set; } = string.Empty;
  21. /// <summary>
  22. /// 参数对象实体
  23. /// </summary>
  24. public List<ParamEntity> Param { get; set; } = new List<ParamEntity>();
  25. /// <summary>
  26. /// 返回描述
  27. /// </summary>
  28. public string Returns { get; set; } = string.Empty;
  29. /// <summary>
  30. /// 代码 | 错误描述 :这个内容必须按照此格式进行记录,用于生成文档时,枚举表格的抬头;
  31. /// </summary>
  32. public string Remarks { get; set; } = string.Empty;
  33. /// <summary>
  34. /// 类注释:显示为该属性是否是必填项,当前1-表示必填,0-表示非必填,默认必填
  35. /// </summary>
  36. public string Code { get; set; } = "1";
  37. /// <summary>
  38. /// 类注释:此项为非必填项,当这个方法与接口上声明的调用端不一致时,用来指定特殊的一级目录;
  39. /// </summary>
  40. public string DocFirstDirectory { get; set; } = "";
  41. /// <summary>
  42. /// 类注释:此项为非必填项,当这个方法与接口上声明的二级目录不一致时,用来指定特殊的二级目录;
  43. /// </summary>
  44. public string DocSecondDirectory { get; set; } = "";
  45. /// <summary>
  46. /// 类注释:此项为非必填项,当这个方法与接口上声明的三级目录不一致时,用来指定特殊的三级目录;
  47. /// </summary>
  48. public string DocThirdDirectory { get; set; } = "";
  49. /// <summary>
  50. /// 枚举注释: 用来显示枚举信息;
  51. /// </summary>
  52. public string EnumDocFirstDirectory { get; set; } = "";
  53. /// <summary>
  54. /// 通知注释: 用来显示通知信息;
  55. /// </summary>
  56. public string NotificationDocFirstDirectory { get; set; } = "";
  57. /// <summary>
  58. /// 通知注释:此项为非必填项,当这个方法与接口上声明的二级目录不一致时,用来指定特殊的二级目录;
  59. /// </summary>
  60. public string NotificationDocSecondDirectory { get; set; } = "";
  61. /// <summary>
  62. /// 通知注释:此项为非必填项,当这个方法与接口上声明的三级目录不一致时,用来指定特殊的二级目录;
  63. /// </summary>
  64. public string NotificationDocThirdDirectory { get; set; } = "";
  65. /// <summary>
  66. /// 表示接口中可能会返回的错误码,中间以逗号相隔;非必填
  67. /// </summary>
  68. public string ErrorCodes { get; set; } = "";
  69. /// <summary>
  70. /// 类注释:false表示此方法不在文档中展示,true表示在文档展示,默认此标签可不加-此时值为true;注:若接口和方法同时出现此标签,以false值为最优先级;
  71. /// </summary>
  72. public bool Show { get; set; } = true;
  73. }
  74. /// <summary>
  75. /// 参数实体
  76. /// </summary>
  77. public class ParamEntity
  78. {
  79. /// <summary>
  80. /// 参数名称
  81. /// </summary>
  82. public string ParamName { get; set; } = string.Empty;
  83. /// <summary>
  84. /// 参数值
  85. /// </summary>
  86. public string ParamText { get; set; } = string.Empty;
  87. }
  88. /// <summary>
  89. /// 查询遍历不同接口下的方法
  90. /// </summary>
  91. public class QueryMethodMemberEntity
  92. {
  93. /// <summary>
  94. /// 一级目录
  95. /// </summary>
  96. public string DocFirstDirectory { get; set; } = "";
  97. /// <summary>
  98. /// 二级目录
  99. /// </summary>
  100. public string DocSecondDirectory { get; set; } = "";
  101. /// <summary>
  102. /// 三级目录
  103. /// </summary>
  104. public string DocThirdDirectory { get; set; } = "";
  105. /// <summary>
  106. /// 通知注释: 一级目录;
  107. /// </summary>
  108. public string NotificationDocFirstDirectory { get; set; } = "";
  109. /// <summary>
  110. /// 通知注释:二级目录;
  111. /// </summary>
  112. public string NotificationDocSecondDirectory { get; set; } = "";
  113. /// <summary>
  114. /// 通知注释:三级目录;
  115. /// </summary>
  116. public string NotificationDocThirdDirectory { get; set; } = "";
  117. public int DirectoryType { get; set; } = 2;
  118. /// <summary>
  119. /// 方法类
  120. /// </summary>
  121. public MemberEntity MethodInfo { get; set; } = new MemberEntity();
  122. /// <summary>
  123. /// 接口类型
  124. /// </summary>
  125. public Type InterfaceType { get; set; }
  126. /// <summary>
  127. /// 接口信息
  128. /// </summary>
  129. public InterfaceBasicInfoEntity InterfaceEntity { get; set; } = new InterfaceBasicInfoEntity();
  130. }
  131. public class BaseEntity
  132. {
  133. /// <summary>
  134. /// key值
  135. /// </summary>
  136. public string Key { get; set; } = "";
  137. /// <summary>
  138. /// value值
  139. /// </summary>
  140. public string Value { get; set; } = "";
  141. }
  142. }