MessageProto.cs 7.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229
  1. // <auto-generated>
  2. // Generated by the protocol buffer compiler. DO NOT EDIT!
  3. // source: MessageProto.proto
  4. // </auto-generated>
  5. #pragma warning disable 1591, 0612, 3021
  6. #region Designer generated code
  7. using pb = global::Google.Protobuf;
  8. using pbc = global::Google.Protobuf.Collections;
  9. using pbr = global::Google.Protobuf.Reflection;
  10. using scg = global::System.Collections.Generic;
  11. namespace Cn.Sagacloud.Proto {
  12. /// <summary>Holder for reflection information generated from MessageProto.proto</summary>
  13. public static partial class MessageProtoReflection {
  14. #region Descriptor
  15. /// <summary>File descriptor for MessageProto.proto</summary>
  16. public static pbr::FileDescriptor Descriptor {
  17. get { return descriptor; }
  18. }
  19. private static pbr::FileDescriptor descriptor;
  20. static MessageProtoReflection() {
  21. byte[] descriptorData = global::System.Convert.FromBase64String(
  22. string.Concat(
  23. "ChJNZXNzYWdlUHJvdG8ucHJvdG8SEmNuLnNhZ2FjbG91ZC5wcm90byI3CgdN",
  24. "ZXNzYWdlEgsKA2NtZBgBIAEoCRIOCgZ0YXNrSWQYAiABKAkSDwoHY29udGVu",
  25. "dBgDIAEoCUITQg9NZXNzYWdlUHJvdG9TdHJIAWIGcHJvdG8z"));
  26. descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
  27. new pbr::FileDescriptor[] { },
  28. new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] {
  29. new pbr::GeneratedClrTypeInfo(typeof(global::Cn.Sagacloud.Proto.Message), global::Cn.Sagacloud.Proto.Message.Parser, new[]{ "Cmd", "TaskId", "Content" }, null, null, null)
  30. }));
  31. }
  32. #endregion
  33. }
  34. #region Messages
  35. public sealed partial class Message : pb::IMessage<Message> {
  36. private static readonly pb::MessageParser<Message> _parser = new pb::MessageParser<Message>(() => new Message());
  37. private pb::UnknownFieldSet _unknownFields;
  38. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  39. public static pb::MessageParser<Message> Parser { get { return _parser; } }
  40. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  41. public static pbr::MessageDescriptor Descriptor {
  42. get { return global::Cn.Sagacloud.Proto.MessageProtoReflection.Descriptor.MessageTypes[0]; }
  43. }
  44. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  45. pbr::MessageDescriptor pb::IMessage.Descriptor {
  46. get { return Descriptor; }
  47. }
  48. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  49. public Message() {
  50. OnConstruction();
  51. }
  52. partial void OnConstruction();
  53. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  54. public Message(Message other) : this() {
  55. cmd_ = other.cmd_;
  56. taskId_ = other.taskId_;
  57. content_ = other.content_;
  58. _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
  59. }
  60. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  61. public Message Clone() {
  62. return new Message(this);
  63. }
  64. /// <summary>Field number for the "cmd" field.</summary>
  65. public const int CmdFieldNumber = 1;
  66. private string cmd_ = "";
  67. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  68. public string Cmd {
  69. get { return cmd_; }
  70. set {
  71. cmd_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
  72. }
  73. }
  74. /// <summary>Field number for the "taskId" field.</summary>
  75. public const int TaskIdFieldNumber = 2;
  76. private string taskId_ = "";
  77. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  78. public string TaskId {
  79. get { return taskId_; }
  80. set {
  81. taskId_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
  82. }
  83. }
  84. /// <summary>Field number for the "content" field.</summary>
  85. public const int ContentFieldNumber = 3;
  86. private string content_ = "";
  87. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  88. public string Content {
  89. get { return content_; }
  90. set {
  91. content_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
  92. }
  93. }
  94. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  95. public override bool Equals(object other) {
  96. return Equals(other as Message);
  97. }
  98. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  99. public bool Equals(Message other) {
  100. if (ReferenceEquals(other, null)) {
  101. return false;
  102. }
  103. if (ReferenceEquals(other, this)) {
  104. return true;
  105. }
  106. if (Cmd != other.Cmd) return false;
  107. if (TaskId != other.TaskId) return false;
  108. if (Content != other.Content) return false;
  109. return Equals(_unknownFields, other._unknownFields);
  110. }
  111. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  112. public override int GetHashCode() {
  113. int hash = 1;
  114. if (Cmd.Length != 0) hash ^= Cmd.GetHashCode();
  115. if (TaskId.Length != 0) hash ^= TaskId.GetHashCode();
  116. if (Content.Length != 0) hash ^= Content.GetHashCode();
  117. if (_unknownFields != null) {
  118. hash ^= _unknownFields.GetHashCode();
  119. }
  120. return hash;
  121. }
  122. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  123. public override string ToString() {
  124. return pb::JsonFormatter.ToDiagnosticString(this);
  125. }
  126. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  127. public void WriteTo(pb::CodedOutputStream output) {
  128. if (Cmd.Length != 0) {
  129. output.WriteRawTag(10);
  130. output.WriteString(Cmd);
  131. }
  132. if (TaskId.Length != 0) {
  133. output.WriteRawTag(18);
  134. output.WriteString(TaskId);
  135. }
  136. if (Content.Length != 0) {
  137. output.WriteRawTag(26);
  138. output.WriteString(Content);
  139. }
  140. if (_unknownFields != null) {
  141. _unknownFields.WriteTo(output);
  142. }
  143. }
  144. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  145. public int CalculateSize() {
  146. int size = 0;
  147. if (Cmd.Length != 0) {
  148. size += 1 + pb::CodedOutputStream.ComputeStringSize(Cmd);
  149. }
  150. if (TaskId.Length != 0) {
  151. size += 1 + pb::CodedOutputStream.ComputeStringSize(TaskId);
  152. }
  153. if (Content.Length != 0) {
  154. size += 1 + pb::CodedOutputStream.ComputeStringSize(Content);
  155. }
  156. if (_unknownFields != null) {
  157. size += _unknownFields.CalculateSize();
  158. }
  159. return size;
  160. }
  161. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  162. public void MergeFrom(Message other) {
  163. if (other == null) {
  164. return;
  165. }
  166. if (other.Cmd.Length != 0) {
  167. Cmd = other.Cmd;
  168. }
  169. if (other.TaskId.Length != 0) {
  170. TaskId = other.TaskId;
  171. }
  172. if (other.Content.Length != 0) {
  173. Content = other.Content;
  174. }
  175. _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
  176. }
  177. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  178. public void MergeFrom(pb::CodedInputStream input) {
  179. uint tag;
  180. while ((tag = input.ReadTag()) != 0) {
  181. switch(tag) {
  182. default:
  183. _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input);
  184. break;
  185. case 10: {
  186. Cmd = input.ReadString();
  187. break;
  188. }
  189. case 18: {
  190. TaskId = input.ReadString();
  191. break;
  192. }
  193. case 26: {
  194. Content = input.ReadString();
  195. break;
  196. }
  197. }
  198. }
  199. }
  200. }
  201. #endregion
  202. }
  203. #endregion Designer generated code