User.cs 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982
  1. // Generated by the protocol buffer compiler. DO NOT EDIT!
  2. // source: user.proto
  3. #pragma warning disable 1591, 0612, 3021
  4. #region Designer generated code
  5. using pb = global::Google.Protobuf;
  6. using pbc = global::Google.Protobuf.Collections;
  7. using pbr = global::Google.Protobuf.Reflection;
  8. using scg = global::System.Collections.Generic;
  9. namespace Protos {
  10. /// <summary>Holder for reflection information generated from user.proto</summary>
  11. public static partial class UserReflection {
  12. #region Descriptor
  13. /// <summary>File descriptor for user.proto</summary>
  14. public static pbr::FileDescriptor Descriptor {
  15. get { return descriptor; }
  16. }
  17. private static pbr::FileDescriptor descriptor;
  18. static UserReflection() {
  19. byte[] descriptorData = global::System.Convert.FromBase64String(
  20. string.Concat(
  21. "Cgp1c2VyLnByb3RvEgZwcm90b3MaDnVzZXJpbmZvLnByb3RvGgxyZXN1bHQu",
  22. "cHJvdG8iBQoDU1lOIg0KC0Nsb3NlTm90aWZ5IhsKCWNsb3NlUHVzaBIOCgZy",
  23. "ZWFzb24YASABKAUiIAoQSGVhcnRiZWF0UmVxdWVzdBIMCgRQaW5nGAEgASgN",
  24. "IjMKEUhlYXJ0YmVhdFJlc3BvbnNlEh4KBlJlc3VsdBgBIAEoCzIOLnByb3Rv",
  25. "cy5SZXN1bHQiMgoMTG9naW5SZXF1ZXN0EiIKCFVzZXJJbmZvGAEgASgLMhAu",
  26. "cHJvdG9zLlVzZXJJbmZvIoEBCg1Mb2dpblJlc3BvbnNlEh4KBlJlc3VsdBgB",
  27. "IAEoCzIOLnByb3Rvcy5SZXN1bHQSDwoHTG9iYnlJRBgCIAEoDRIOCgZSb29t",
  28. "SUQYAyABKA0SFAoMU3luY0ludGVydmFsGAQgASgNEgkKAU4YBSABKA0SDgoG",
  29. "RXJybXNnGAYgASgJYgZwcm90bzM="));
  30. descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
  31. new pbr::FileDescriptor[] { global::Protos.UserinfoReflection.Descriptor, global::Protos.ResultReflection.Descriptor, },
  32. new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] {
  33. new pbr::GeneratedClrTypeInfo(typeof(global::Protos.SYN), global::Protos.SYN.Parser, null, null, null, null),
  34. new pbr::GeneratedClrTypeInfo(typeof(global::Protos.CloseNotify), global::Protos.CloseNotify.Parser, null, null, null, null),
  35. new pbr::GeneratedClrTypeInfo(typeof(global::Protos.closePush), global::Protos.closePush.Parser, new[]{ "Reason" }, null, null, null),
  36. new pbr::GeneratedClrTypeInfo(typeof(global::Protos.HeartbeatRequest), global::Protos.HeartbeatRequest.Parser, new[]{ "Ping" }, null, null, null),
  37. new pbr::GeneratedClrTypeInfo(typeof(global::Protos.HeartbeatResponse), global::Protos.HeartbeatResponse.Parser, new[]{ "Result" }, null, null, null),
  38. new pbr::GeneratedClrTypeInfo(typeof(global::Protos.LoginRequest), global::Protos.LoginRequest.Parser, new[]{ "UserInfo" }, null, null, null),
  39. new pbr::GeneratedClrTypeInfo(typeof(global::Protos.LoginResponse), global::Protos.LoginResponse.Parser, new[]{ "Result", "LobbyID", "RoomID", "SyncInterval", "N", "Errmsg" }, null, null, null)
  40. }));
  41. }
  42. #endregion
  43. }
  44. #region Messages
  45. public sealed partial class SYN : pb::IMessage<SYN> {
  46. private static readonly pb::MessageParser<SYN> _parser = new pb::MessageParser<SYN>(() => new SYN());
  47. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  48. public static pb::MessageParser<SYN> Parser { get { return _parser; } }
  49. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  50. public static pbr::MessageDescriptor Descriptor {
  51. get { return global::Protos.UserReflection.Descriptor.MessageTypes[0]; }
  52. }
  53. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  54. pbr::MessageDescriptor pb::IMessage.Descriptor {
  55. get { return Descriptor; }
  56. }
  57. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  58. public SYN() {
  59. OnConstruction();
  60. }
  61. partial void OnConstruction();
  62. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  63. public SYN(SYN other) : this() {
  64. }
  65. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  66. public SYN Clone() {
  67. return new SYN(this);
  68. }
  69. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  70. public override bool Equals(object other) {
  71. return Equals(other as SYN);
  72. }
  73. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  74. public bool Equals(SYN other) {
  75. if (ReferenceEquals(other, null)) {
  76. return false;
  77. }
  78. if (ReferenceEquals(other, this)) {
  79. return true;
  80. }
  81. return true;
  82. }
  83. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  84. public override int GetHashCode() {
  85. int hash = 1;
  86. return hash;
  87. }
  88. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  89. public override string ToString() {
  90. return pb::JsonFormatter.ToDiagnosticString(this);
  91. }
  92. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  93. public void WriteTo(pb::CodedOutputStream output) {
  94. }
  95. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  96. public int CalculateSize() {
  97. int size = 0;
  98. return size;
  99. }
  100. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  101. public void MergeFrom(SYN other) {
  102. if (other == null) {
  103. return;
  104. }
  105. }
  106. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  107. public void MergeFrom(pb::CodedInputStream input) {
  108. uint tag;
  109. while ((tag = input.ReadTag()) != 0) {
  110. switch(tag) {
  111. default:
  112. input.SkipLastField();
  113. break;
  114. }
  115. }
  116. }
  117. }
  118. public sealed partial class CloseNotify : pb::IMessage<CloseNotify> {
  119. private static readonly pb::MessageParser<CloseNotify> _parser = new pb::MessageParser<CloseNotify>(() => new CloseNotify());
  120. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  121. public static pb::MessageParser<CloseNotify> Parser { get { return _parser; } }
  122. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  123. public static pbr::MessageDescriptor Descriptor {
  124. get { return global::Protos.UserReflection.Descriptor.MessageTypes[1]; }
  125. }
  126. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  127. pbr::MessageDescriptor pb::IMessage.Descriptor {
  128. get { return Descriptor; }
  129. }
  130. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  131. public CloseNotify() {
  132. OnConstruction();
  133. }
  134. partial void OnConstruction();
  135. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  136. public CloseNotify(CloseNotify other) : this() {
  137. }
  138. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  139. public CloseNotify Clone() {
  140. return new CloseNotify(this);
  141. }
  142. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  143. public override bool Equals(object other) {
  144. return Equals(other as CloseNotify);
  145. }
  146. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  147. public bool Equals(CloseNotify other) {
  148. if (ReferenceEquals(other, null)) {
  149. return false;
  150. }
  151. if (ReferenceEquals(other, this)) {
  152. return true;
  153. }
  154. return true;
  155. }
  156. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  157. public override int GetHashCode() {
  158. int hash = 1;
  159. return hash;
  160. }
  161. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  162. public override string ToString() {
  163. return pb::JsonFormatter.ToDiagnosticString(this);
  164. }
  165. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  166. public void WriteTo(pb::CodedOutputStream output) {
  167. }
  168. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  169. public int CalculateSize() {
  170. int size = 0;
  171. return size;
  172. }
  173. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  174. public void MergeFrom(CloseNotify other) {
  175. if (other == null) {
  176. return;
  177. }
  178. }
  179. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  180. public void MergeFrom(pb::CodedInputStream input) {
  181. uint tag;
  182. while ((tag = input.ReadTag()) != 0) {
  183. switch(tag) {
  184. default:
  185. input.SkipLastField();
  186. break;
  187. }
  188. }
  189. }
  190. }
  191. public sealed partial class closePush : pb::IMessage<closePush> {
  192. private static readonly pb::MessageParser<closePush> _parser = new pb::MessageParser<closePush>(() => new closePush());
  193. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  194. public static pb::MessageParser<closePush> Parser { get { return _parser; } }
  195. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  196. public static pbr::MessageDescriptor Descriptor {
  197. get { return global::Protos.UserReflection.Descriptor.MessageTypes[2]; }
  198. }
  199. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  200. pbr::MessageDescriptor pb::IMessage.Descriptor {
  201. get { return Descriptor; }
  202. }
  203. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  204. public closePush() {
  205. OnConstruction();
  206. }
  207. partial void OnConstruction();
  208. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  209. public closePush(closePush other) : this() {
  210. reason_ = other.reason_;
  211. }
  212. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  213. public closePush Clone() {
  214. return new closePush(this);
  215. }
  216. /// <summary>Field number for the "reason" field.</summary>
  217. public const int ReasonFieldNumber = 1;
  218. private int reason_;
  219. /// <summary>
  220. /// 关闭原因
  221. /// </summary>
  222. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  223. public int Reason {
  224. get { return reason_; }
  225. set {
  226. reason_ = value;
  227. }
  228. }
  229. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  230. public override bool Equals(object other) {
  231. return Equals(other as closePush);
  232. }
  233. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  234. public bool Equals(closePush other) {
  235. if (ReferenceEquals(other, null)) {
  236. return false;
  237. }
  238. if (ReferenceEquals(other, this)) {
  239. return true;
  240. }
  241. if (Reason != other.Reason) return false;
  242. return true;
  243. }
  244. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  245. public override int GetHashCode() {
  246. int hash = 1;
  247. if (Reason != 0) hash ^= Reason.GetHashCode();
  248. return hash;
  249. }
  250. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  251. public override string ToString() {
  252. return pb::JsonFormatter.ToDiagnosticString(this);
  253. }
  254. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  255. public void WriteTo(pb::CodedOutputStream output) {
  256. if (Reason != 0) {
  257. output.WriteRawTag(8);
  258. output.WriteInt32(Reason);
  259. }
  260. }
  261. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  262. public int CalculateSize() {
  263. int size = 0;
  264. if (Reason != 0) {
  265. size += 1 + pb::CodedOutputStream.ComputeInt32Size(Reason);
  266. }
  267. return size;
  268. }
  269. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  270. public void MergeFrom(closePush other) {
  271. if (other == null) {
  272. return;
  273. }
  274. if (other.Reason != 0) {
  275. Reason = other.Reason;
  276. }
  277. }
  278. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  279. public void MergeFrom(pb::CodedInputStream input) {
  280. uint tag;
  281. while ((tag = input.ReadTag()) != 0) {
  282. switch(tag) {
  283. default:
  284. input.SkipLastField();
  285. break;
  286. case 8: {
  287. Reason = input.ReadInt32();
  288. break;
  289. }
  290. }
  291. }
  292. }
  293. }
  294. public sealed partial class HeartbeatRequest : pb::IMessage<HeartbeatRequest> {
  295. private static readonly pb::MessageParser<HeartbeatRequest> _parser = new pb::MessageParser<HeartbeatRequest>(() => new HeartbeatRequest());
  296. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  297. public static pb::MessageParser<HeartbeatRequest> Parser { get { return _parser; } }
  298. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  299. public static pbr::MessageDescriptor Descriptor {
  300. get { return global::Protos.UserReflection.Descriptor.MessageTypes[3]; }
  301. }
  302. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  303. pbr::MessageDescriptor pb::IMessage.Descriptor {
  304. get { return Descriptor; }
  305. }
  306. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  307. public HeartbeatRequest() {
  308. OnConstruction();
  309. }
  310. partial void OnConstruction();
  311. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  312. public HeartbeatRequest(HeartbeatRequest other) : this() {
  313. ping_ = other.ping_;
  314. }
  315. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  316. public HeartbeatRequest Clone() {
  317. return new HeartbeatRequest(this);
  318. }
  319. /// <summary>Field number for the "Ping" field.</summary>
  320. public const int PingFieldNumber = 1;
  321. private uint ping_;
  322. /// <summary>
  323. /// ping值, 单位毫秒
  324. /// </summary>
  325. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  326. public uint Ping {
  327. get { return ping_; }
  328. set {
  329. ping_ = value;
  330. }
  331. }
  332. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  333. public override bool Equals(object other) {
  334. return Equals(other as HeartbeatRequest);
  335. }
  336. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  337. public bool Equals(HeartbeatRequest other) {
  338. if (ReferenceEquals(other, null)) {
  339. return false;
  340. }
  341. if (ReferenceEquals(other, this)) {
  342. return true;
  343. }
  344. if (Ping != other.Ping) return false;
  345. return true;
  346. }
  347. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  348. public override int GetHashCode() {
  349. int hash = 1;
  350. if (Ping != 0) hash ^= Ping.GetHashCode();
  351. return hash;
  352. }
  353. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  354. public override string ToString() {
  355. return pb::JsonFormatter.ToDiagnosticString(this);
  356. }
  357. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  358. public void WriteTo(pb::CodedOutputStream output) {
  359. if (Ping != 0) {
  360. output.WriteRawTag(8);
  361. output.WriteUInt32(Ping);
  362. }
  363. }
  364. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  365. public int CalculateSize() {
  366. int size = 0;
  367. if (Ping != 0) {
  368. size += 1 + pb::CodedOutputStream.ComputeUInt32Size(Ping);
  369. }
  370. return size;
  371. }
  372. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  373. public void MergeFrom(HeartbeatRequest other) {
  374. if (other == null) {
  375. return;
  376. }
  377. if (other.Ping != 0) {
  378. Ping = other.Ping;
  379. }
  380. }
  381. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  382. public void MergeFrom(pb::CodedInputStream input) {
  383. uint tag;
  384. while ((tag = input.ReadTag()) != 0) {
  385. switch(tag) {
  386. default:
  387. input.SkipLastField();
  388. break;
  389. case 8: {
  390. Ping = input.ReadUInt32();
  391. break;
  392. }
  393. }
  394. }
  395. }
  396. }
  397. public sealed partial class HeartbeatResponse : pb::IMessage<HeartbeatResponse> {
  398. private static readonly pb::MessageParser<HeartbeatResponse> _parser = new pb::MessageParser<HeartbeatResponse>(() => new HeartbeatResponse());
  399. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  400. public static pb::MessageParser<HeartbeatResponse> Parser { get { return _parser; } }
  401. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  402. public static pbr::MessageDescriptor Descriptor {
  403. get { return global::Protos.UserReflection.Descriptor.MessageTypes[4]; }
  404. }
  405. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  406. pbr::MessageDescriptor pb::IMessage.Descriptor {
  407. get { return Descriptor; }
  408. }
  409. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  410. public HeartbeatResponse() {
  411. OnConstruction();
  412. }
  413. partial void OnConstruction();
  414. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  415. public HeartbeatResponse(HeartbeatResponse other) : this() {
  416. Result = other.result_ != null ? other.Result.Clone() : null;
  417. }
  418. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  419. public HeartbeatResponse Clone() {
  420. return new HeartbeatResponse(this);
  421. }
  422. /// <summary>Field number for the "Result" field.</summary>
  423. public const int ResultFieldNumber = 1;
  424. private global::Protos.Result result_;
  425. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  426. public global::Protos.Result Result {
  427. get { return result_; }
  428. set {
  429. result_ = value;
  430. }
  431. }
  432. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  433. public override bool Equals(object other) {
  434. return Equals(other as HeartbeatResponse);
  435. }
  436. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  437. public bool Equals(HeartbeatResponse other) {
  438. if (ReferenceEquals(other, null)) {
  439. return false;
  440. }
  441. if (ReferenceEquals(other, this)) {
  442. return true;
  443. }
  444. if (!object.Equals(Result, other.Result)) return false;
  445. return true;
  446. }
  447. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  448. public override int GetHashCode() {
  449. int hash = 1;
  450. if (result_ != null) hash ^= Result.GetHashCode();
  451. return hash;
  452. }
  453. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  454. public override string ToString() {
  455. return pb::JsonFormatter.ToDiagnosticString(this);
  456. }
  457. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  458. public void WriteTo(pb::CodedOutputStream output) {
  459. if (result_ != null) {
  460. output.WriteRawTag(10);
  461. output.WriteMessage(Result);
  462. }
  463. }
  464. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  465. public int CalculateSize() {
  466. int size = 0;
  467. if (result_ != null) {
  468. size += 1 + pb::CodedOutputStream.ComputeMessageSize(Result);
  469. }
  470. return size;
  471. }
  472. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  473. public void MergeFrom(HeartbeatResponse other) {
  474. if (other == null) {
  475. return;
  476. }
  477. if (other.result_ != null) {
  478. if (result_ == null) {
  479. result_ = new global::Protos.Result();
  480. }
  481. Result.MergeFrom(other.Result);
  482. }
  483. }
  484. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  485. public void MergeFrom(pb::CodedInputStream input) {
  486. uint tag;
  487. while ((tag = input.ReadTag()) != 0) {
  488. switch(tag) {
  489. default:
  490. input.SkipLastField();
  491. break;
  492. case 10: {
  493. if (result_ == null) {
  494. result_ = new global::Protos.Result();
  495. }
  496. input.ReadMessage(result_);
  497. break;
  498. }
  499. }
  500. }
  501. }
  502. }
  503. public sealed partial class LoginRequest : pb::IMessage<LoginRequest> {
  504. private static readonly pb::MessageParser<LoginRequest> _parser = new pb::MessageParser<LoginRequest>(() => new LoginRequest());
  505. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  506. public static pb::MessageParser<LoginRequest> Parser { get { return _parser; } }
  507. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  508. public static pbr::MessageDescriptor Descriptor {
  509. get { return global::Protos.UserReflection.Descriptor.MessageTypes[5]; }
  510. }
  511. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  512. pbr::MessageDescriptor pb::IMessage.Descriptor {
  513. get { return Descriptor; }
  514. }
  515. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  516. public LoginRequest() {
  517. OnConstruction();
  518. }
  519. partial void OnConstruction();
  520. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  521. public LoginRequest(LoginRequest other) : this() {
  522. UserInfo = other.userInfo_ != null ? other.UserInfo.Clone() : null;
  523. }
  524. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  525. public LoginRequest Clone() {
  526. return new LoginRequest(this);
  527. }
  528. /// <summary>Field number for the "UserInfo" field.</summary>
  529. public const int UserInfoFieldNumber = 1;
  530. private global::Protos.UserInfo userInfo_;
  531. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  532. public global::Protos.UserInfo UserInfo {
  533. get { return userInfo_; }
  534. set {
  535. userInfo_ = value;
  536. }
  537. }
  538. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  539. public override bool Equals(object other) {
  540. return Equals(other as LoginRequest);
  541. }
  542. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  543. public bool Equals(LoginRequest other) {
  544. if (ReferenceEquals(other, null)) {
  545. return false;
  546. }
  547. if (ReferenceEquals(other, this)) {
  548. return true;
  549. }
  550. if (!object.Equals(UserInfo, other.UserInfo)) return false;
  551. return true;
  552. }
  553. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  554. public override int GetHashCode() {
  555. int hash = 1;
  556. if (userInfo_ != null) hash ^= UserInfo.GetHashCode();
  557. return hash;
  558. }
  559. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  560. public override string ToString() {
  561. return pb::JsonFormatter.ToDiagnosticString(this);
  562. }
  563. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  564. public void WriteTo(pb::CodedOutputStream output) {
  565. if (userInfo_ != null) {
  566. output.WriteRawTag(10);
  567. output.WriteMessage(UserInfo);
  568. }
  569. }
  570. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  571. public int CalculateSize() {
  572. int size = 0;
  573. if (userInfo_ != null) {
  574. size += 1 + pb::CodedOutputStream.ComputeMessageSize(UserInfo);
  575. }
  576. return size;
  577. }
  578. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  579. public void MergeFrom(LoginRequest other) {
  580. if (other == null) {
  581. return;
  582. }
  583. if (other.userInfo_ != null) {
  584. if (userInfo_ == null) {
  585. userInfo_ = new global::Protos.UserInfo();
  586. }
  587. UserInfo.MergeFrom(other.UserInfo);
  588. }
  589. }
  590. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  591. public void MergeFrom(pb::CodedInputStream input) {
  592. uint tag;
  593. while ((tag = input.ReadTag()) != 0) {
  594. switch(tag) {
  595. default:
  596. input.SkipLastField();
  597. break;
  598. case 10: {
  599. if (userInfo_ == null) {
  600. userInfo_ = new global::Protos.UserInfo();
  601. }
  602. input.ReadMessage(userInfo_);
  603. break;
  604. }
  605. }
  606. }
  607. }
  608. }
  609. public sealed partial class LoginResponse : pb::IMessage<LoginResponse> {
  610. private static readonly pb::MessageParser<LoginResponse> _parser = new pb::MessageParser<LoginResponse>(() => new LoginResponse());
  611. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  612. public static pb::MessageParser<LoginResponse> Parser { get { return _parser; } }
  613. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  614. public static pbr::MessageDescriptor Descriptor {
  615. get { return global::Protos.UserReflection.Descriptor.MessageTypes[6]; }
  616. }
  617. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  618. pbr::MessageDescriptor pb::IMessage.Descriptor {
  619. get { return Descriptor; }
  620. }
  621. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  622. public LoginResponse() {
  623. OnConstruction();
  624. }
  625. partial void OnConstruction();
  626. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  627. public LoginResponse(LoginResponse other) : this() {
  628. Result = other.result_ != null ? other.Result.Clone() : null;
  629. lobbyID_ = other.lobbyID_;
  630. roomID_ = other.roomID_;
  631. syncInterval_ = other.syncInterval_;
  632. n_ = other.n_;
  633. errmsg_ = other.errmsg_;
  634. }
  635. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  636. public LoginResponse Clone() {
  637. return new LoginResponse(this);
  638. }
  639. /// <summary>Field number for the "Result" field.</summary>
  640. public const int ResultFieldNumber = 1;
  641. private global::Protos.Result result_;
  642. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  643. public global::Protos.Result Result {
  644. get { return result_; }
  645. set {
  646. result_ = value;
  647. }
  648. }
  649. /// <summary>Field number for the "LobbyID" field.</summary>
  650. public const int LobbyIDFieldNumber = 2;
  651. private uint lobbyID_;
  652. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  653. public uint LobbyID {
  654. get { return lobbyID_; }
  655. set {
  656. lobbyID_ = value;
  657. }
  658. }
  659. /// <summary>Field number for the "RoomID" field.</summary>
  660. public const int RoomIDFieldNumber = 3;
  661. private uint roomID_;
  662. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  663. public uint RoomID {
  664. get { return roomID_; }
  665. set {
  666. roomID_ = value;
  667. }
  668. }
  669. /// <summary>Field number for the "SyncInterval" field.</summary>
  670. public const int SyncIntervalFieldNumber = 4;
  671. private uint syncInterval_;
  672. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  673. public uint SyncInterval {
  674. get { return syncInterval_; }
  675. set {
  676. syncInterval_ = value;
  677. }
  678. }
  679. /// <summary>Field number for the "N" field.</summary>
  680. public const int NFieldNumber = 5;
  681. private uint n_;
  682. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  683. public uint N {
  684. get { return n_; }
  685. set {
  686. n_ = value;
  687. }
  688. }
  689. /// <summary>Field number for the "Errmsg" field.</summary>
  690. public const int ErrmsgFieldNumber = 6;
  691. private string errmsg_ = "";
  692. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  693. public string Errmsg {
  694. get { return errmsg_; }
  695. set {
  696. errmsg_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
  697. }
  698. }
  699. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  700. public override bool Equals(object other) {
  701. return Equals(other as LoginResponse);
  702. }
  703. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  704. public bool Equals(LoginResponse other) {
  705. if (ReferenceEquals(other, null)) {
  706. return false;
  707. }
  708. if (ReferenceEquals(other, this)) {
  709. return true;
  710. }
  711. if (!object.Equals(Result, other.Result)) return false;
  712. if (LobbyID != other.LobbyID) return false;
  713. if (RoomID != other.RoomID) return false;
  714. if (SyncInterval != other.SyncInterval) return false;
  715. if (N != other.N) return false;
  716. if (Errmsg != other.Errmsg) return false;
  717. return true;
  718. }
  719. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  720. public override int GetHashCode() {
  721. int hash = 1;
  722. if (result_ != null) hash ^= Result.GetHashCode();
  723. if (LobbyID != 0) hash ^= LobbyID.GetHashCode();
  724. if (RoomID != 0) hash ^= RoomID.GetHashCode();
  725. if (SyncInterval != 0) hash ^= SyncInterval.GetHashCode();
  726. if (N != 0) hash ^= N.GetHashCode();
  727. if (Errmsg.Length != 0) hash ^= Errmsg.GetHashCode();
  728. return hash;
  729. }
  730. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  731. public override string ToString() {
  732. return pb::JsonFormatter.ToDiagnosticString(this);
  733. }
  734. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  735. public void WriteTo(pb::CodedOutputStream output) {
  736. if (result_ != null) {
  737. output.WriteRawTag(10);
  738. output.WriteMessage(Result);
  739. }
  740. if (LobbyID != 0) {
  741. output.WriteRawTag(16);
  742. output.WriteUInt32(LobbyID);
  743. }
  744. if (RoomID != 0) {
  745. output.WriteRawTag(24);
  746. output.WriteUInt32(RoomID);
  747. }
  748. if (SyncInterval != 0) {
  749. output.WriteRawTag(32);
  750. output.WriteUInt32(SyncInterval);
  751. }
  752. if (N != 0) {
  753. output.WriteRawTag(40);
  754. output.WriteUInt32(N);
  755. }
  756. if (Errmsg.Length != 0) {
  757. output.WriteRawTag(50);
  758. output.WriteString(Errmsg);
  759. }
  760. }
  761. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  762. public int CalculateSize() {
  763. int size = 0;
  764. if (result_ != null) {
  765. size += 1 + pb::CodedOutputStream.ComputeMessageSize(Result);
  766. }
  767. if (LobbyID != 0) {
  768. size += 1 + pb::CodedOutputStream.ComputeUInt32Size(LobbyID);
  769. }
  770. if (RoomID != 0) {
  771. size += 1 + pb::CodedOutputStream.ComputeUInt32Size(RoomID);
  772. }
  773. if (SyncInterval != 0) {
  774. size += 1 + pb::CodedOutputStream.ComputeUInt32Size(SyncInterval);
  775. }
  776. if (N != 0) {
  777. size += 1 + pb::CodedOutputStream.ComputeUInt32Size(N);
  778. }
  779. if (Errmsg.Length != 0) {
  780. size += 1 + pb::CodedOutputStream.ComputeStringSize(Errmsg);
  781. }
  782. return size;
  783. }
  784. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  785. public void MergeFrom(LoginResponse other) {
  786. if (other == null) {
  787. return;
  788. }
  789. if (other.result_ != null) {
  790. if (result_ == null) {
  791. result_ = new global::Protos.Result();
  792. }
  793. Result.MergeFrom(other.Result);
  794. }
  795. if (other.LobbyID != 0) {
  796. LobbyID = other.LobbyID;
  797. }
  798. if (other.RoomID != 0) {
  799. RoomID = other.RoomID;
  800. }
  801. if (other.SyncInterval != 0) {
  802. SyncInterval = other.SyncInterval;
  803. }
  804. if (other.N != 0) {
  805. N = other.N;
  806. }
  807. if (other.Errmsg.Length != 0) {
  808. Errmsg = other.Errmsg;
  809. }
  810. }
  811. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  812. public void MergeFrom(pb::CodedInputStream input) {
  813. uint tag;
  814. while ((tag = input.ReadTag()) != 0) {
  815. switch(tag) {
  816. default:
  817. input.SkipLastField();
  818. break;
  819. case 10: {
  820. if (result_ == null) {
  821. result_ = new global::Protos.Result();
  822. }
  823. input.ReadMessage(result_);
  824. break;
  825. }
  826. case 16: {
  827. LobbyID = input.ReadUInt32();
  828. break;
  829. }
  830. case 24: {
  831. RoomID = input.ReadUInt32();
  832. break;
  833. }
  834. case 32: {
  835. SyncInterval = input.ReadUInt32();
  836. break;
  837. }
  838. case 40: {
  839. N = input.ReadUInt32();
  840. break;
  841. }
  842. case 50: {
  843. Errmsg = input.ReadString();
  844. break;
  845. }
  846. }
  847. }
  848. }
  849. }
  850. #endregion
  851. }
  852. #endregion Designer generated code