test.pb.go 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // source: irregular/test.proto
  3. package irregular
  4. import (
  5. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  6. protoregistry "google.golang.org/protobuf/reflect/protoregistry"
  7. protoiface "google.golang.org/protobuf/runtime/protoiface"
  8. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  9. sync "sync"
  10. )
  11. const (
  12. // Verify that runtime/protoimpl is sufficiently up-to-date.
  13. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 0)
  14. // Verify that this generated code is sufficiently up-to-date.
  15. _ = protoimpl.EnforceVersion(0 - protoimpl.MinVersion)
  16. )
  17. type Message struct {
  18. OptionalMessage *IrregularMessage `protobuf:"bytes,1,opt,name=optional_message,json=optionalMessage" json:"optional_message,omitempty"`
  19. RepeatedMessage []*IrregularMessage `protobuf:"bytes,2,rep,name=repeated_message,json=repeatedMessage" json:"repeated_message,omitempty"`
  20. RequiredMessage *IrregularMessage `protobuf:"bytes,3,req,name=required_message,json=requiredMessage" json:"required_message,omitempty"`
  21. MapMessage map[string]*IrregularMessage `protobuf:"bytes,4,rep,name=map_message,json=mapMessage" json:"map_message,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
  22. // Types that are valid to be assigned to Union:
  23. // *Message_OneofMessage
  24. Union isMessage_Union `protobuf_oneof:"union"`
  25. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  26. XXX_unrecognized protoimpl.UnknownFields `json:"-"`
  27. XXX_sizecache protoimpl.SizeCache `json:"-"`
  28. }
  29. func (x *Message) Reset() {
  30. *x = Message{}
  31. }
  32. func (x *Message) String() string {
  33. return protoimpl.X.MessageStringOf(x)
  34. }
  35. func (*Message) ProtoMessage() {}
  36. func (x *Message) ProtoReflect() protoreflect.Message {
  37. return file_irregular_test_proto_msgTypes[0].MessageOf(x)
  38. }
  39. func (m *Message) XXX_Methods() *protoiface.Methods {
  40. return file_irregular_test_proto_msgTypes[0].Methods()
  41. }
  42. // Deprecated: Use Message.ProtoReflect.Type instead.
  43. func (*Message) Descriptor() ([]byte, []int) {
  44. return file_irregular_test_proto_rawDescGZIP(), []int{0}
  45. }
  46. func (x *Message) GetOptionalMessage() *IrregularMessage {
  47. if x != nil {
  48. return x.OptionalMessage
  49. }
  50. return nil
  51. }
  52. func (x *Message) GetRepeatedMessage() []*IrregularMessage {
  53. if x != nil {
  54. return x.RepeatedMessage
  55. }
  56. return nil
  57. }
  58. func (x *Message) GetRequiredMessage() *IrregularMessage {
  59. if x != nil {
  60. return x.RequiredMessage
  61. }
  62. return nil
  63. }
  64. func (x *Message) GetMapMessage() map[string]*IrregularMessage {
  65. if x != nil {
  66. return x.MapMessage
  67. }
  68. return nil
  69. }
  70. func (m *Message) GetUnion() isMessage_Union {
  71. if m != nil {
  72. return m.Union
  73. }
  74. return nil
  75. }
  76. func (x *Message) GetOneofMessage() *IrregularMessage {
  77. if x, ok := x.GetUnion().(*Message_OneofMessage); ok {
  78. return x.OneofMessage
  79. }
  80. return nil
  81. }
  82. // XXX_OneofWrappers is for the internal use of the proto package.
  83. func (*Message) XXX_OneofWrappers() []interface{} {
  84. return []interface{}{
  85. (*Message_OneofMessage)(nil),
  86. }
  87. }
  88. type isMessage_Union interface {
  89. isMessage_Union()
  90. }
  91. type Message_OneofMessage struct {
  92. OneofMessage *IrregularMessage `protobuf:"bytes,5,opt,name=oneof_message,json=oneofMessage,oneof"`
  93. }
  94. func (*Message_OneofMessage) isMessage_Union() {}
  95. var File_irregular_test_proto protoreflect.FileDescriptor
  96. var file_irregular_test_proto_rawDesc = []byte{
  97. 0x0a, 0x14, 0x69, 0x72, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x2f, 0x74, 0x65, 0x73, 0x74,
  98. 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x17, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e,
  99. 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x69, 0x72, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x1a,
  100. 0x19, 0x69, 0x72, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x2f, 0x69, 0x72, 0x72, 0x65, 0x67,
  101. 0x75, 0x6c, 0x61, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xa3, 0x04, 0x0a, 0x07, 0x4d,
  102. 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x54, 0x0a, 0x10, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e,
  103. 0x61, 0x6c, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b,
  104. 0x32, 0x29, 0x2e, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
  105. 0x2e, 0x69, 0x72, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x2e, 0x49, 0x72, 0x72, 0x65, 0x67,
  106. 0x75, 0x6c, 0x61, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x0f, 0x6f, 0x70, 0x74,
  107. 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x54, 0x0a, 0x10,
  108. 0x72, 0x65, 0x70, 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65,
  109. 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f,
  110. 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x69, 0x72, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72,
  111. 0x2e, 0x49, 0x72, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67,
  112. 0x65, 0x52, 0x0f, 0x72, 0x65, 0x70, 0x65, 0x61, 0x74, 0x65, 0x64, 0x4d, 0x65, 0x73, 0x73, 0x61,
  113. 0x67, 0x65, 0x12, 0x54, 0x0a, 0x10, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x5f, 0x6d,
  114. 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x02, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x67,
  115. 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x69, 0x72, 0x72,
  116. 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x2e, 0x49, 0x72, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72,
  117. 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x0f, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65,
  118. 0x64, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x51, 0x0a, 0x0b, 0x6d, 0x61, 0x70, 0x5f,
  119. 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x30, 0x2e,
  120. 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x69, 0x72,
  121. 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x2e, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x2e,
  122. 0x4d, 0x61, 0x70, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52,
  123. 0x0a, 0x6d, 0x61, 0x70, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x50, 0x0a, 0x0d, 0x6f,
  124. 0x6e, 0x65, 0x6f, 0x66, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x05, 0x20, 0x01,
  125. 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x70, 0x72, 0x6f,
  126. 0x74, 0x6f, 0x2e, 0x69, 0x72, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x2e, 0x49, 0x72, 0x72,
  127. 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x48, 0x00, 0x52,
  128. 0x0c, 0x6f, 0x6e, 0x65, 0x6f, 0x66, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x68, 0x0a,
  129. 0x0f, 0x4d, 0x61, 0x70, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79,
  130. 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b,
  131. 0x65, 0x79, 0x12, 0x3f, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
  132. 0x0b, 0x32, 0x29, 0x2e, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74,
  133. 0x6f, 0x2e, 0x69, 0x72, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x2e, 0x49, 0x72, 0x72, 0x65,
  134. 0x67, 0x75, 0x6c, 0x61, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x05, 0x76, 0x61,
  135. 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x42, 0x07, 0x0a, 0x05, 0x75, 0x6e, 0x69, 0x6f, 0x6e,
  136. 0x42, 0x3a, 0x5a, 0x38, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e,
  137. 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x69,
  138. 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x70, 0x72, 0x6f, 0x74,
  139. 0x6f, 0x73, 0x2f, 0x69, 0x72, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72,
  140. }
  141. var (
  142. file_irregular_test_proto_rawDescOnce sync.Once
  143. file_irregular_test_proto_rawDescData = file_irregular_test_proto_rawDesc
  144. )
  145. func file_irregular_test_proto_rawDescGZIP() []byte {
  146. file_irregular_test_proto_rawDescOnce.Do(func() {
  147. file_irregular_test_proto_rawDescData = protoimpl.X.CompressGZIP(file_irregular_test_proto_rawDescData)
  148. })
  149. return file_irregular_test_proto_rawDescData
  150. }
  151. var file_irregular_test_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
  152. var file_irregular_test_proto_goTypes = []interface{}{
  153. (*Message)(nil), // 0: goproto.proto.irregular.Message
  154. nil, // 1: goproto.proto.irregular.Message.MapMessageEntry
  155. (*IrregularMessage)(nil), // 2: goproto.proto.irregular.IrregularMessage
  156. }
  157. var file_irregular_test_proto_depIdxs = []int32{
  158. 2, // goproto.proto.irregular.Message.optional_message:type_name -> goproto.proto.irregular.IrregularMessage
  159. 2, // goproto.proto.irregular.Message.repeated_message:type_name -> goproto.proto.irregular.IrregularMessage
  160. 2, // goproto.proto.irregular.Message.required_message:type_name -> goproto.proto.irregular.IrregularMessage
  161. 1, // goproto.proto.irregular.Message.map_message:type_name -> goproto.proto.irregular.Message.MapMessageEntry
  162. 2, // goproto.proto.irregular.Message.oneof_message:type_name -> goproto.proto.irregular.IrregularMessage
  163. 2, // goproto.proto.irregular.Message.MapMessageEntry.value:type_name -> goproto.proto.irregular.IrregularMessage
  164. }
  165. func init() { file_irregular_test_proto_init() }
  166. func file_irregular_test_proto_init() {
  167. if File_irregular_test_proto != nil {
  168. return
  169. }
  170. file_irregular_irregular_proto_init()
  171. File_irregular_test_proto = protoimpl.FileBuilder{
  172. RawDescriptor: file_irregular_test_proto_rawDesc,
  173. GoTypes: file_irregular_test_proto_goTypes,
  174. DependencyIndexes: file_irregular_test_proto_depIdxs,
  175. MessageOutputTypes: file_irregular_test_proto_msgTypes,
  176. FilesRegistry: protoregistry.GlobalFiles,
  177. TypesRegistry: protoregistry.GlobalTypes,
  178. }.Init()
  179. file_irregular_test_proto_rawDesc = nil
  180. file_irregular_test_proto_goTypes = nil
  181. file_irregular_test_proto_depIdxs = nil
  182. }