_test.cs 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514
  1. //------------------------------------------------------------------------------
  2. // <auto-generated>
  3. // This code was generated by a tool.
  4. //
  5. // Changes to this file may cause incorrect behavior and will be lost if
  6. // the code is regenerated.
  7. // </auto-generated>
  8. //------------------------------------------------------------------------------
  9. // ***************************************************************************
  10. // * 创建时间= 2015-08-27
  11. // ***************************************************************************
  12. // Generated from: test.proto
  13. // Note: requires additional types generated from: common.proto
  14. namespace test
  15. {
  16. //---------------------------------------------------------------------------------------
  17. /// <summary>
  18. /// 获取成就项
  19. /// <summary>
  20. [global::ProtoBuf.ServiceModel.ProtoComment("获取成就项")]
  21. [global::System.Serializable, global::ProtoBuf.ProtoContract(Name=@"AchievementGetTypesRequest")]
  22. public partial class AchievementGetTypesRequest : global::ProtoBuf.IExtensible
  23. {
  24. public AchievementGetTypesRequest() {}
  25. private global::ProtoBuf.IExtension extensionObject;
  26. global::ProtoBuf.IExtension global::ProtoBuf.IExtensible.GetExtensionObject(bool createIfMissing)
  27. { return global::ProtoBuf.Extensible.GetExtensionObject(ref extensionObject, createIfMissing); }
  28. }
  29. //---------------------------------------------------------------------------------------
  30. /// <summary>
  31. /// 获取成就项内容
  32. /// <summary>
  33. [global::ProtoBuf.ServiceModel.ProtoComment("获取成就项内容")]
  34. [global::System.Serializable, global::ProtoBuf.ProtoContract(Name=@"AchievementGetTypeElementRequest")]
  35. public partial class AchievementGetTypeElementRequest : global::ProtoBuf.IExtensible
  36. {
  37. public AchievementGetTypeElementRequest() {}
  38. private int _c2s_id;
  39. [global::ProtoBuf.ProtoMember(1, IsRequired = true, Name=@"c2s_id", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  40. public int c2s_id
  41. {
  42. get { return _c2s_id; }
  43. set { _c2s_id = value; }
  44. }
  45. private global::ProtoBuf.IExtension extensionObject;
  46. global::ProtoBuf.IExtension global::ProtoBuf.IExtensible.GetExtensionObject(bool createIfMissing)
  47. { return global::ProtoBuf.Extensible.GetExtensionObject(ref extensionObject, createIfMissing); }
  48. }
  49. //---------------------------------------------------------------------------------------
  50. /// <summary>
  51. /// 领取奖励
  52. /// <summary>
  53. [global::ProtoBuf.ServiceModel.ProtoComment("领取奖励")]
  54. [global::System.Serializable, global::ProtoBuf.ProtoContract(Name=@"AchievementGetAwardRequest")]
  55. public partial class AchievementGetAwardRequest : global::ProtoBuf.IExtensible
  56. {
  57. public AchievementGetAwardRequest() {}
  58. private int _c2s_id;
  59. [global::ProtoBuf.ProtoMember(1, IsRequired = true, Name=@"c2s_id", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  60. public int c2s_id
  61. {
  62. get { return _c2s_id; }
  63. set { _c2s_id = value; }
  64. }
  65. private test.AchievementGetAwardRequest.ReqType _req_type = test.AchievementGetAwardRequest.ReqType.TYPE1;
  66. /// <summary>
  67. /// 类型
  68. /// <summary>
  69. [global::ProtoBuf.ServiceModel.ProtoComment("类型")]
  70. [global::ProtoBuf.ProtoMember(2, IsRequired = false, Name=@"req_type", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  71. [global::System.ComponentModel.DefaultValue(test.AchievementGetAwardRequest.ReqType.TYPE1)]
  72. public test.AchievementGetAwardRequest.ReqType req_type
  73. {
  74. get { return _req_type; }
  75. set { _req_type = value; }
  76. }
  77. //---------------------------------------------------------------------------------------
  78. /// <summary>
  79. /// 枚举类型
  80. /// <summary>
  81. [global::ProtoBuf.ServiceModel.ProtoComment("枚举类型")]
  82. [global::ProtoBuf.ProtoContract(Name=@"ReqType")]
  83. public enum ReqType
  84. {
  85. /// <summary>
  86. /// 类型1
  87. /// <summary>
  88. [global::ProtoBuf.ServiceModel.ProtoComment("类型1")]
  89. [global::ProtoBuf.ProtoEnum(Name=@"TYPE1", Value=1)]
  90. TYPE1 = 1,
  91. /// <summary>
  92. /// 类型2
  93. /// <summary>
  94. [global::ProtoBuf.ServiceModel.ProtoComment("类型2")]
  95. [global::ProtoBuf.ProtoEnum(Name=@"TYPE2", Value=2)]
  96. TYPE2 = 2
  97. }
  98. private global::ProtoBuf.IExtension extensionObject;
  99. global::ProtoBuf.IExtension global::ProtoBuf.IExtensible.GetExtensionObject(bool createIfMissing)
  100. { return global::ProtoBuf.Extensible.GetExtensionObject(ref extensionObject, createIfMissing); }
  101. }
  102. //---------------------------------------------------------------------------------------
  103. /// <summary>
  104. /// 成就内容
  105. /// <summary>
  106. [global::ProtoBuf.ServiceModel.ProtoComment("成就内容")]
  107. [global::System.Serializable, global::ProtoBuf.ProtoContract(Name=@"Achievement")]
  108. public partial class Achievement : global::ProtoBuf.IExtensible
  109. {
  110. public Achievement() {}
  111. private int _id;
  112. /// <summary>
  113. /// 成就id
  114. /// <summary>
  115. [global::ProtoBuf.ServiceModel.ProtoComment("成就id")]
  116. [global::ProtoBuf.ProtoMember(1, IsRequired = true, Name=@"id", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  117. public int id
  118. {
  119. get { return _id; }
  120. set { _id = value; }
  121. }
  122. private int _scheduleCurr;
  123. /// <summary>
  124. /// 成就完成进度
  125. /// <summary>
  126. [global::ProtoBuf.ServiceModel.ProtoComment("成就完成进度")]
  127. [global::ProtoBuf.ProtoMember(2, IsRequired = true, Name=@"scheduleCurr", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  128. public int scheduleCurr
  129. {
  130. get { return _scheduleCurr; }
  131. set { _scheduleCurr = value; }
  132. }
  133. private global::ProtoBuf.IExtension extensionObject;
  134. global::ProtoBuf.IExtension global::ProtoBuf.IExtensible.GetExtensionObject(bool createIfMissing)
  135. { return global::ProtoBuf.Extensible.GetExtensionObject(ref extensionObject, createIfMissing); }
  136. }
  137. //---------------------------------------------------------------------------------------
  138. /// <summary>
  139. /// 成就项
  140. /// <summary>
  141. [global::ProtoBuf.ServiceModel.ProtoComment("成就项")]
  142. [global::System.Serializable, global::ProtoBuf.ProtoContract(Name=@"AchievementType")]
  143. public partial class AchievementType : global::ProtoBuf.IExtensible
  144. {
  145. public AchievementType() {}
  146. private int _id;
  147. /// <summary>
  148. /// 成就项id
  149. /// <summary>
  150. [global::ProtoBuf.ServiceModel.ProtoComment("成就项id")]
  151. /// <summary>
  152. /// 1,2,3,4,5
  153. /// <summary>
  154. [global::ProtoBuf.ServiceModel.ProtoComment("1,2,3,4,5")]
  155. [global::ProtoBuf.ProtoMember(1, IsRequired = true, Name=@"id", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  156. public int id
  157. {
  158. get { return _id; }
  159. set { _id = value; }
  160. }
  161. private int _maxScore = default(int);
  162. /// <summary>
  163. /// 当前项总成就点
  164. /// <summary>
  165. [global::ProtoBuf.ServiceModel.ProtoComment("当前项总成就点")]
  166. [global::ProtoBuf.ProtoMember(2, IsRequired = false, Name=@"maxScore", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  167. [global::System.ComponentModel.DefaultValue(default(int))]
  168. public int maxScore
  169. {
  170. get { return _maxScore; }
  171. set { _maxScore = value; }
  172. }
  173. private int _currScore = default(int);
  174. /// <summary>
  175. /// 当前项当前成就点
  176. /// <summary>
  177. [global::ProtoBuf.ServiceModel.ProtoComment("当前项当前成就点")]
  178. [global::ProtoBuf.ProtoMember(3, IsRequired = false, Name=@"currScore", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  179. [global::System.ComponentModel.DefaultValue(default(int))]
  180. public int currScore
  181. {
  182. get { return _currScore; }
  183. set { _currScore = value; }
  184. }
  185. private test.DataEnum _dataType = test.DataEnum.TYPEA;
  186. /// <summary>
  187. /// 数据类型
  188. /// <summary>
  189. [global::ProtoBuf.ServiceModel.ProtoComment("数据类型")]
  190. [global::ProtoBuf.ProtoMember(4, IsRequired = false, Name=@"dataType", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  191. [global::System.ComponentModel.DefaultValue(test.DataEnum.TYPEA)]
  192. public test.DataEnum dataType
  193. {
  194. get { return _dataType; }
  195. set { _dataType = value; }
  196. }
  197. private global::ProtoBuf.IExtension extensionObject;
  198. global::ProtoBuf.IExtension global::ProtoBuf.IExtensible.GetExtensionObject(bool createIfMissing)
  199. { return global::ProtoBuf.Extensible.GetExtensionObject(ref extensionObject, createIfMissing); }
  200. }
  201. //---------------------------------------------------------------------------------------
  202. [global::System.Serializable, global::ProtoBuf.ProtoContract(Name=@"AchievementGetAllResponse")]
  203. public partial class AchievementGetAllResponse : global::ProtoBuf.IExtensible
  204. {
  205. public AchievementGetAllResponse() {}
  206. private int _s2c_code;
  207. [global::ProtoBuf.ProtoMember(1, IsRequired = true, Name=@"s2c_code", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  208. public int s2c_code
  209. {
  210. get { return _s2c_code; }
  211. set { _s2c_code = value; }
  212. }
  213. private string _s2c_msg = "";
  214. [global::ProtoBuf.ProtoMember(2, IsRequired = false, Name=@"s2c_msg", DataFormat = global::ProtoBuf.DataFormat.Default)]
  215. [global::System.ComponentModel.DefaultValue("")]
  216. public string s2c_msg
  217. {
  218. get { return _s2c_msg; }
  219. set { _s2c_msg = value; }
  220. }
  221. private readonly global::System.Collections.Generic.List<test.AchievementType> _s2c_achievementTypes = new global::System.Collections.Generic.List<test.AchievementType>();
  222. [global::ProtoBuf.ProtoMember(3, Name=@"s2c_achievementTypes", DataFormat = global::ProtoBuf.DataFormat.Default)]
  223. public global::System.Collections.Generic.List<test.AchievementType> s2c_achievementTypes
  224. {
  225. get { return _s2c_achievementTypes; }
  226. }
  227. private readonly global::System.Collections.Generic.List<test.Achievement> _s2c_achievements = new global::System.Collections.Generic.List<test.Achievement>();
  228. [global::ProtoBuf.ProtoMember(4, Name=@"s2c_achievements", DataFormat = global::ProtoBuf.DataFormat.Default)]
  229. public global::System.Collections.Generic.List<test.Achievement> s2c_achievements
  230. {
  231. get { return _s2c_achievements; }
  232. }
  233. private global::ProtoBuf.IExtension extensionObject;
  234. global::ProtoBuf.IExtension global::ProtoBuf.IExtensible.GetExtensionObject(bool createIfMissing)
  235. { return global::ProtoBuf.Extensible.GetExtensionObject(ref extensionObject, createIfMissing); }
  236. }
  237. //---------------------------------------------------------------------------------------
  238. [global::System.Serializable, global::ProtoBuf.ProtoContract(Name=@"AchievementGetTypesResponse")]
  239. public partial class AchievementGetTypesResponse : global::ProtoBuf.IExtensible
  240. {
  241. public AchievementGetTypesResponse() {}
  242. private int _s2c_code;
  243. [global::ProtoBuf.ProtoMember(1, IsRequired = true, Name=@"s2c_code", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  244. public int s2c_code
  245. {
  246. get { return _s2c_code; }
  247. set { _s2c_code = value; }
  248. }
  249. private string _s2c_msg = "";
  250. [global::ProtoBuf.ProtoMember(2, IsRequired = false, Name=@"s2c_msg", DataFormat = global::ProtoBuf.DataFormat.Default)]
  251. [global::System.ComponentModel.DefaultValue("")]
  252. public string s2c_msg
  253. {
  254. get { return _s2c_msg; }
  255. set { _s2c_msg = value; }
  256. }
  257. private readonly global::System.Collections.Generic.List<test.AchievementType> _s2c_achievementTypes = new global::System.Collections.Generic.List<test.AchievementType>();
  258. [global::ProtoBuf.ProtoMember(3, Name=@"s2c_achievementTypes", DataFormat = global::ProtoBuf.DataFormat.Default)]
  259. public global::System.Collections.Generic.List<test.AchievementType> s2c_achievementTypes
  260. {
  261. get { return _s2c_achievementTypes; }
  262. }
  263. private int _s2c_totalScore = default(int);
  264. [global::ProtoBuf.ProtoMember(4, IsRequired = false, Name=@"s2c_totalScore", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  265. [global::System.ComponentModel.DefaultValue(default(int))]
  266. public int s2c_totalScore
  267. {
  268. get { return _s2c_totalScore; }
  269. set { _s2c_totalScore = value; }
  270. }
  271. private int _s2c_leader = default(int);
  272. [global::ProtoBuf.ProtoMember(5, IsRequired = false, Name=@"s2c_leader", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  273. [global::System.ComponentModel.DefaultValue(default(int))]
  274. public int s2c_leader
  275. {
  276. get { return _s2c_leader; }
  277. set { _s2c_leader = value; }
  278. }
  279. private readonly global::System.Collections.Generic.List<int> _s2c_rewardCount = new global::System.Collections.Generic.List<int>();
  280. [global::ProtoBuf.ProtoMember(6, Name=@"s2c_rewardCount", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  281. public global::System.Collections.Generic.List<int> s2c_rewardCount
  282. {
  283. get { return _s2c_rewardCount; }
  284. }
  285. private global::ProtoBuf.IExtension extensionObject;
  286. global::ProtoBuf.IExtension global::ProtoBuf.IExtensible.GetExtensionObject(bool createIfMissing)
  287. { return global::ProtoBuf.Extensible.GetExtensionObject(ref extensionObject, createIfMissing); }
  288. }
  289. //---------------------------------------------------------------------------------------
  290. [global::System.Serializable, global::ProtoBuf.ProtoContract(Name=@"AchievementGetTypeElementResponse")]
  291. public partial class AchievementGetTypeElementResponse : global::ProtoBuf.IExtensible
  292. {
  293. public AchievementGetTypeElementResponse() {}
  294. private int _s2c_code;
  295. [global::ProtoBuf.ProtoMember(1, IsRequired = true, Name=@"s2c_code", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  296. public int s2c_code
  297. {
  298. get { return _s2c_code; }
  299. set { _s2c_code = value; }
  300. }
  301. private string _s2c_msg = "";
  302. [global::ProtoBuf.ProtoMember(2, IsRequired = false, Name=@"s2c_msg", DataFormat = global::ProtoBuf.DataFormat.Default)]
  303. [global::System.ComponentModel.DefaultValue("")]
  304. public string s2c_msg
  305. {
  306. get { return _s2c_msg; }
  307. set { _s2c_msg = value; }
  308. }
  309. private readonly global::System.Collections.Generic.List<test.Achievement> _s2c_achievements = new global::System.Collections.Generic.List<test.Achievement>();
  310. [global::ProtoBuf.ProtoMember(3, Name=@"s2c_achievements", DataFormat = global::ProtoBuf.DataFormat.Default)]
  311. public global::System.Collections.Generic.List<test.Achievement> s2c_achievements
  312. {
  313. get { return _s2c_achievements; }
  314. }
  315. private readonly global::System.Collections.Generic.List<int> _s2c_rewardCount = new global::System.Collections.Generic.List<int>();
  316. [global::ProtoBuf.ProtoMember(4, Name=@"s2c_rewardCount", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  317. public global::System.Collections.Generic.List<int> s2c_rewardCount
  318. {
  319. get { return _s2c_rewardCount; }
  320. }
  321. private global::ProtoBuf.IExtension extensionObject;
  322. global::ProtoBuf.IExtension global::ProtoBuf.IExtensible.GetExtensionObject(bool createIfMissing)
  323. { return global::ProtoBuf.Extensible.GetExtensionObject(ref extensionObject, createIfMissing); }
  324. }
  325. //---------------------------------------------------------------------------------------
  326. [global::System.Serializable, global::ProtoBuf.ProtoContract(Name=@"AchievementGetAwardResponse")]
  327. public partial class AchievementGetAwardResponse : global::ProtoBuf.IExtensible
  328. {
  329. public AchievementGetAwardResponse() {}
  330. private int _s2c_code;
  331. [global::ProtoBuf.ProtoMember(1, IsRequired = true, Name=@"s2c_code", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  332. public int s2c_code
  333. {
  334. get { return _s2c_code; }
  335. set { _s2c_code = value; }
  336. }
  337. private string _s2c_msg = "";
  338. [global::ProtoBuf.ProtoMember(2, IsRequired = false, Name=@"s2c_msg", DataFormat = global::ProtoBuf.DataFormat.Default)]
  339. [global::System.ComponentModel.DefaultValue("")]
  340. public string s2c_msg
  341. {
  342. get { return _s2c_msg; }
  343. set { _s2c_msg = value; }
  344. }
  345. private global::ProtoBuf.IExtension extensionObject;
  346. global::ProtoBuf.IExtension global::ProtoBuf.IExtensible.GetExtensionObject(bool createIfMissing)
  347. { return global::ProtoBuf.Extensible.GetExtensionObject(ref extensionObject, createIfMissing); }
  348. }
  349. //---------------------------------------------------------------------------------------
  350. [global::System.Serializable, global::ProtoBuf.ProtoContract(Name=@"OnAchievementPush")]
  351. public partial class OnAchievementPush : global::ProtoBuf.IExtensible
  352. {
  353. public OnAchievementPush() {}
  354. private int _s2c_code;
  355. [global::ProtoBuf.ProtoMember(1, IsRequired = true, Name=@"s2c_code", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  356. public int s2c_code
  357. {
  358. get { return _s2c_code; }
  359. set { _s2c_code = value; }
  360. }
  361. private int _s2c_id = default(int);
  362. [global::ProtoBuf.ProtoMember(2, IsRequired = false, Name=@"s2c_id", DataFormat = global::ProtoBuf.DataFormat.TwosComplement)]
  363. [global::System.ComponentModel.DefaultValue(default(int))]
  364. public int s2c_id
  365. {
  366. get { return _s2c_id; }
  367. set { _s2c_id = value; }
  368. }
  369. private readonly global::System.Collections.Generic.List<test.Achievement> _s2c_achievements = new global::System.Collections.Generic.List<test.Achievement>();
  370. [global::ProtoBuf.ProtoMember(3, Name=@"s2c_achievements", DataFormat = global::ProtoBuf.DataFormat.Default)]
  371. public global::System.Collections.Generic.List<test.Achievement> s2c_achievements
  372. {
  373. get { return _s2c_achievements; }
  374. }
  375. private global::ProtoBuf.IExtension extensionObject;
  376. global::ProtoBuf.IExtension global::ProtoBuf.IExtensible.GetExtensionObject(bool createIfMissing)
  377. { return global::ProtoBuf.Extensible.GetExtensionObject(ref extensionObject, createIfMissing); }
  378. }
  379. //---------------------------------------------------------------------------------------
  380. /// <summary>
  381. /// 数据类型
  382. /// <summary>
  383. [global::ProtoBuf.ServiceModel.ProtoComment("数据类型")]
  384. [global::ProtoBuf.ProtoContract(Name=@"DataEnum")]
  385. public enum DataEnum
  386. {
  387. /// <summary>
  388. /// 类型A
  389. /// <summary>
  390. [global::ProtoBuf.ServiceModel.ProtoComment("类型A")]
  391. [global::ProtoBuf.ProtoEnum(Name=@"TYPEA", Value=1)]
  392. TYPEA = 1,
  393. /// <summary>
  394. /// 类型B
  395. /// <summary>
  396. [global::ProtoBuf.ServiceModel.ProtoComment("类型B")]
  397. [global::ProtoBuf.ProtoEnum(Name=@"TYPEB", Value=2)]
  398. TYPEB = 2
  399. }
  400. //---------------------------------------------------------------------------------------
  401. /// <summary>
  402. /// 成就处理器
  403. /// <summary>
  404. [global::ProtoBuf.ServiceModel.ProtoComment("成就处理器")]
  405. public interface IachievementHandler
  406. {
  407. /// <summary>
  408. /// 请求成就信息
  409. /// <summary>
  410. [global::ProtoBuf.ServiceModel.ProtoComment("请求成就信息")]
  411. test.AchievementGetTypesResponse achievementGetTypesRequest(test.AchievementGetTypesRequest request);
  412. /// <summary>
  413. /// 请求对于项的成就
  414. /// <summary>
  415. [global::ProtoBuf.ServiceModel.ProtoComment("请求对于项的成就")]
  416. test.AchievementGetTypeElementResponse achievementGetTypeElementRequest(test.AchievementGetTypeElementRequest request);
  417. /// <summary>
  418. /// 请求奖励
  419. /// <summary>
  420. [global::ProtoBuf.ServiceModel.ProtoComment("请求奖励")]
  421. test.AchievementGetAwardResponse achievementGetAwardRequest(test.AchievementGetAwardRequest request);
  422. }
  423. //---------------------------------------------------------------------------------------
  424. public interface IachievementPush
  425. {
  426. test.Void onAchievementPush(test.OnAchievementPush request);
  427. }
  428. }