Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 1 | // Code generated by protoc-gen-go. DO NOT EDIT. |
| 2 | // source: reflect/protoregistry/testprotos/test.proto |
| 3 | |
| 4 | package testprotos |
| 5 | |
| 6 | import ( |
| 7 | proto "github.com/golang/protobuf/proto" |
| 8 | protoreflect "github.com/golang/protobuf/v2/reflect/protoreflect" |
| 9 | prototype "github.com/golang/protobuf/v2/reflect/prototype" |
| 10 | protoimpl "github.com/golang/protobuf/v2/runtime/protoimpl" |
| 11 | ) |
| 12 | |
| 13 | // This is a compile-time assertion to ensure that this generated file |
| 14 | // is compatible with the proto package it is being compiled against. |
| 15 | // A compilation error at this line likely means your copy of the |
| 16 | // proto package needs to be updated. |
| 17 | const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package |
| 18 | |
| 19 | type Enum1 int32 |
| 20 | |
| 21 | const ( |
| 22 | Enum1_ONE Enum1 = 1 |
| 23 | ) |
| 24 | |
Damien Neil | a8593ba | 2019-01-08 16:18:07 -0800 | [diff] [blame] | 25 | func (e Enum1) Type() protoreflect.EnumType { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 26 | return xxx_Test_protoFile_EnumTypes[0] |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 27 | } |
Damien Neil | a8593ba | 2019-01-08 16:18:07 -0800 | [diff] [blame] | 28 | func (e Enum1) Number() protoreflect.EnumNumber { |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 29 | return protoreflect.EnumNumber(e) |
| 30 | } |
| 31 | |
| 32 | var Enum1_name = map[int32]string{ |
| 33 | 1: "ONE", |
| 34 | } |
| 35 | |
| 36 | var Enum1_value = map[string]int32{ |
| 37 | "ONE": 1, |
| 38 | } |
| 39 | |
| 40 | func (x Enum1) Enum() *Enum1 { |
| 41 | p := new(Enum1) |
| 42 | *p = x |
| 43 | return p |
| 44 | } |
| 45 | |
| 46 | func (x Enum1) String() string { |
| 47 | return proto.EnumName(Enum1_name, int32(x)) |
| 48 | } |
| 49 | |
| 50 | func (x *Enum1) UnmarshalJSON(data []byte) error { |
| 51 | value, err := proto.UnmarshalJSONEnum(Enum1_value, data, "Enum1") |
| 52 | if err != nil { |
| 53 | return err |
| 54 | } |
| 55 | *x = Enum1(value) |
| 56 | return nil |
| 57 | } |
| 58 | |
| 59 | func (Enum1) EnumDescriptor() ([]byte, []int) { |
| 60 | return fileDescriptor_3628d63611f7063d, []int{0} |
| 61 | } |
| 62 | |
| 63 | type Enum2 int32 |
| 64 | |
| 65 | const ( |
| 66 | Enum2_UNO Enum2 = 1 |
| 67 | ) |
| 68 | |
Damien Neil | a8593ba | 2019-01-08 16:18:07 -0800 | [diff] [blame] | 69 | func (e Enum2) Type() protoreflect.EnumType { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 70 | return xxx_Test_protoFile_EnumTypes[1] |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 71 | } |
Damien Neil | a8593ba | 2019-01-08 16:18:07 -0800 | [diff] [blame] | 72 | func (e Enum2) Number() protoreflect.EnumNumber { |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 73 | return protoreflect.EnumNumber(e) |
| 74 | } |
| 75 | |
| 76 | var Enum2_name = map[int32]string{ |
| 77 | 1: "UNO", |
| 78 | } |
| 79 | |
| 80 | var Enum2_value = map[string]int32{ |
| 81 | "UNO": 1, |
| 82 | } |
| 83 | |
| 84 | func (x Enum2) Enum() *Enum2 { |
| 85 | p := new(Enum2) |
| 86 | *p = x |
| 87 | return p |
| 88 | } |
| 89 | |
| 90 | func (x Enum2) String() string { |
| 91 | return proto.EnumName(Enum2_name, int32(x)) |
| 92 | } |
| 93 | |
| 94 | func (x *Enum2) UnmarshalJSON(data []byte) error { |
| 95 | value, err := proto.UnmarshalJSONEnum(Enum2_value, data, "Enum2") |
| 96 | if err != nil { |
| 97 | return err |
| 98 | } |
| 99 | *x = Enum2(value) |
| 100 | return nil |
| 101 | } |
| 102 | |
| 103 | func (Enum2) EnumDescriptor() ([]byte, []int) { |
| 104 | return fileDescriptor_3628d63611f7063d, []int{1} |
| 105 | } |
| 106 | |
| 107 | type Enum3 int32 |
| 108 | |
| 109 | const ( |
| 110 | Enum3_YI Enum3 = 1 |
| 111 | ) |
| 112 | |
Damien Neil | a8593ba | 2019-01-08 16:18:07 -0800 | [diff] [blame] | 113 | func (e Enum3) Type() protoreflect.EnumType { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 114 | return xxx_Test_protoFile_EnumTypes[2] |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 115 | } |
Damien Neil | a8593ba | 2019-01-08 16:18:07 -0800 | [diff] [blame] | 116 | func (e Enum3) Number() protoreflect.EnumNumber { |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 117 | return protoreflect.EnumNumber(e) |
| 118 | } |
| 119 | |
| 120 | var Enum3_name = map[int32]string{ |
| 121 | 1: "YI", |
| 122 | } |
| 123 | |
| 124 | var Enum3_value = map[string]int32{ |
| 125 | "YI": 1, |
| 126 | } |
| 127 | |
| 128 | func (x Enum3) Enum() *Enum3 { |
| 129 | p := new(Enum3) |
| 130 | *p = x |
| 131 | return p |
| 132 | } |
| 133 | |
| 134 | func (x Enum3) String() string { |
| 135 | return proto.EnumName(Enum3_name, int32(x)) |
| 136 | } |
| 137 | |
| 138 | func (x *Enum3) UnmarshalJSON(data []byte) error { |
| 139 | value, err := proto.UnmarshalJSONEnum(Enum3_value, data, "Enum3") |
| 140 | if err != nil { |
| 141 | return err |
| 142 | } |
| 143 | *x = Enum3(value) |
| 144 | return nil |
| 145 | } |
| 146 | |
| 147 | func (Enum3) EnumDescriptor() ([]byte, []int) { |
| 148 | return fileDescriptor_3628d63611f7063d, []int{2} |
| 149 | } |
| 150 | |
| 151 | type Message1 struct { |
| 152 | XXX_NoUnkeyedLiteral struct{} `json:"-"` |
| 153 | proto.XXX_InternalExtensions `json:"-"` |
| 154 | XXX_unrecognized []byte `json:"-"` |
| 155 | XXX_sizecache int32 `json:"-"` |
| 156 | } |
| 157 | |
| 158 | type xxx_Message1 struct{ m *Message1 } |
| 159 | |
| 160 | func (m *Message1) ProtoReflect() protoreflect.Message { |
| 161 | return xxx_Message1{m} |
| 162 | } |
| 163 | func (m xxx_Message1) Type() protoreflect.MessageType { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 164 | return xxx_Test_protoFile_MessageTypes[0].Type |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 165 | } |
| 166 | func (m xxx_Message1) KnownFields() protoreflect.KnownFields { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 167 | return xxx_Test_protoFile_MessageTypes[0].KnownFieldsOf(m.m) |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 168 | } |
| 169 | func (m xxx_Message1) UnknownFields() protoreflect.UnknownFields { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 170 | return xxx_Test_protoFile_MessageTypes[0].UnknownFieldsOf(m.m) |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 171 | } |
| 172 | func (m xxx_Message1) Interface() protoreflect.ProtoMessage { |
| 173 | return m.m |
| 174 | } |
| 175 | |
| 176 | func (m *Message1) Reset() { *m = Message1{} } |
| 177 | func (m *Message1) String() string { return proto.CompactTextString(m) } |
| 178 | func (*Message1) ProtoMessage() {} |
| 179 | func (*Message1) Descriptor() ([]byte, []int) { |
| 180 | return fileDescriptor_3628d63611f7063d, []int{0} |
| 181 | } |
| 182 | |
| 183 | var extRange_Message1 = []proto.ExtensionRange{ |
| 184 | {Start: 10, End: 536870911}, |
| 185 | } |
| 186 | |
| 187 | func (*Message1) ExtensionRangeArray() []proto.ExtensionRange { |
| 188 | return extRange_Message1 |
| 189 | } |
| 190 | |
| 191 | func (m *Message1) XXX_Unmarshal(b []byte) error { |
| 192 | return xxx_messageInfo_Message1.Unmarshal(m, b) |
| 193 | } |
| 194 | func (m *Message1) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { |
| 195 | return xxx_messageInfo_Message1.Marshal(b, m, deterministic) |
| 196 | } |
| 197 | func (m *Message1) XXX_Merge(src proto.Message) { |
| 198 | xxx_messageInfo_Message1.Merge(m, src) |
| 199 | } |
| 200 | func (m *Message1) XXX_Size() int { |
| 201 | return xxx_messageInfo_Message1.Size(m) |
| 202 | } |
| 203 | func (m *Message1) XXX_DiscardUnknown() { |
| 204 | xxx_messageInfo_Message1.DiscardUnknown(m) |
| 205 | } |
| 206 | |
| 207 | var xxx_messageInfo_Message1 proto.InternalMessageInfo |
| 208 | |
| 209 | type Message2 struct { |
| 210 | XXX_NoUnkeyedLiteral struct{} `json:"-"` |
| 211 | XXX_unrecognized []byte `json:"-"` |
| 212 | XXX_sizecache int32 `json:"-"` |
| 213 | } |
| 214 | |
| 215 | type xxx_Message2 struct{ m *Message2 } |
| 216 | |
| 217 | func (m *Message2) ProtoReflect() protoreflect.Message { |
| 218 | return xxx_Message2{m} |
| 219 | } |
| 220 | func (m xxx_Message2) Type() protoreflect.MessageType { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 221 | return xxx_Test_protoFile_MessageTypes[1].Type |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 222 | } |
| 223 | func (m xxx_Message2) KnownFields() protoreflect.KnownFields { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 224 | return xxx_Test_protoFile_MessageTypes[1].KnownFieldsOf(m.m) |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 225 | } |
| 226 | func (m xxx_Message2) UnknownFields() protoreflect.UnknownFields { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 227 | return xxx_Test_protoFile_MessageTypes[1].UnknownFieldsOf(m.m) |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 228 | } |
| 229 | func (m xxx_Message2) Interface() protoreflect.ProtoMessage { |
| 230 | return m.m |
| 231 | } |
| 232 | |
| 233 | func (m *Message2) Reset() { *m = Message2{} } |
| 234 | func (m *Message2) String() string { return proto.CompactTextString(m) } |
| 235 | func (*Message2) ProtoMessage() {} |
| 236 | func (*Message2) Descriptor() ([]byte, []int) { |
| 237 | return fileDescriptor_3628d63611f7063d, []int{1} |
| 238 | } |
| 239 | |
| 240 | func (m *Message2) XXX_Unmarshal(b []byte) error { |
| 241 | return xxx_messageInfo_Message2.Unmarshal(m, b) |
| 242 | } |
| 243 | func (m *Message2) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { |
| 244 | return xxx_messageInfo_Message2.Marshal(b, m, deterministic) |
| 245 | } |
| 246 | func (m *Message2) XXX_Merge(src proto.Message) { |
| 247 | xxx_messageInfo_Message2.Merge(m, src) |
| 248 | } |
| 249 | func (m *Message2) XXX_Size() int { |
| 250 | return xxx_messageInfo_Message2.Size(m) |
| 251 | } |
| 252 | func (m *Message2) XXX_DiscardUnknown() { |
| 253 | xxx_messageInfo_Message2.DiscardUnknown(m) |
| 254 | } |
| 255 | |
| 256 | var xxx_messageInfo_Message2 proto.InternalMessageInfo |
| 257 | |
| 258 | type Message3 struct { |
| 259 | XXX_NoUnkeyedLiteral struct{} `json:"-"` |
| 260 | XXX_unrecognized []byte `json:"-"` |
| 261 | XXX_sizecache int32 `json:"-"` |
| 262 | } |
| 263 | |
| 264 | type xxx_Message3 struct{ m *Message3 } |
| 265 | |
| 266 | func (m *Message3) ProtoReflect() protoreflect.Message { |
| 267 | return xxx_Message3{m} |
| 268 | } |
| 269 | func (m xxx_Message3) Type() protoreflect.MessageType { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 270 | return xxx_Test_protoFile_MessageTypes[2].Type |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 271 | } |
| 272 | func (m xxx_Message3) KnownFields() protoreflect.KnownFields { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 273 | return xxx_Test_protoFile_MessageTypes[2].KnownFieldsOf(m.m) |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 274 | } |
| 275 | func (m xxx_Message3) UnknownFields() protoreflect.UnknownFields { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 276 | return xxx_Test_protoFile_MessageTypes[2].UnknownFieldsOf(m.m) |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 277 | } |
| 278 | func (m xxx_Message3) Interface() protoreflect.ProtoMessage { |
| 279 | return m.m |
| 280 | } |
| 281 | |
| 282 | func (m *Message3) Reset() { *m = Message3{} } |
| 283 | func (m *Message3) String() string { return proto.CompactTextString(m) } |
| 284 | func (*Message3) ProtoMessage() {} |
| 285 | func (*Message3) Descriptor() ([]byte, []int) { |
| 286 | return fileDescriptor_3628d63611f7063d, []int{2} |
| 287 | } |
| 288 | |
| 289 | func (m *Message3) XXX_Unmarshal(b []byte) error { |
| 290 | return xxx_messageInfo_Message3.Unmarshal(m, b) |
| 291 | } |
| 292 | func (m *Message3) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { |
| 293 | return xxx_messageInfo_Message3.Marshal(b, m, deterministic) |
| 294 | } |
| 295 | func (m *Message3) XXX_Merge(src proto.Message) { |
| 296 | xxx_messageInfo_Message3.Merge(m, src) |
| 297 | } |
| 298 | func (m *Message3) XXX_Size() int { |
| 299 | return xxx_messageInfo_Message3.Size(m) |
| 300 | } |
| 301 | func (m *Message3) XXX_DiscardUnknown() { |
| 302 | xxx_messageInfo_Message3.DiscardUnknown(m) |
| 303 | } |
| 304 | |
| 305 | var xxx_messageInfo_Message3 proto.InternalMessageInfo |
| 306 | |
| 307 | type Message4 struct { |
| 308 | BoolField *bool `protobuf:"varint,30,opt,name=bool_field,json=boolField" json:"bool_field,omitempty"` |
| 309 | XXX_NoUnkeyedLiteral struct{} `json:"-"` |
| 310 | XXX_unrecognized []byte `json:"-"` |
| 311 | XXX_sizecache int32 `json:"-"` |
| 312 | } |
| 313 | |
| 314 | type xxx_Message4 struct{ m *Message4 } |
| 315 | |
| 316 | func (m *Message4) ProtoReflect() protoreflect.Message { |
| 317 | return xxx_Message4{m} |
| 318 | } |
| 319 | func (m xxx_Message4) Type() protoreflect.MessageType { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 320 | return xxx_Test_protoFile_MessageTypes[3].Type |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 321 | } |
| 322 | func (m xxx_Message4) KnownFields() protoreflect.KnownFields { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 323 | return xxx_Test_protoFile_MessageTypes[3].KnownFieldsOf(m.m) |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 324 | } |
| 325 | func (m xxx_Message4) UnknownFields() protoreflect.UnknownFields { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 326 | return xxx_Test_protoFile_MessageTypes[3].UnknownFieldsOf(m.m) |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 327 | } |
| 328 | func (m xxx_Message4) Interface() protoreflect.ProtoMessage { |
| 329 | return m.m |
| 330 | } |
| 331 | |
| 332 | func (m *Message4) Reset() { *m = Message4{} } |
| 333 | func (m *Message4) String() string { return proto.CompactTextString(m) } |
| 334 | func (*Message4) ProtoMessage() {} |
| 335 | func (*Message4) Descriptor() ([]byte, []int) { |
| 336 | return fileDescriptor_3628d63611f7063d, []int{3} |
| 337 | } |
| 338 | |
| 339 | func (m *Message4) XXX_Unmarshal(b []byte) error { |
| 340 | return xxx_messageInfo_Message4.Unmarshal(m, b) |
| 341 | } |
| 342 | func (m *Message4) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { |
| 343 | return xxx_messageInfo_Message4.Marshal(b, m, deterministic) |
| 344 | } |
| 345 | func (m *Message4) XXX_Merge(src proto.Message) { |
| 346 | xxx_messageInfo_Message4.Merge(m, src) |
| 347 | } |
| 348 | func (m *Message4) XXX_Size() int { |
| 349 | return xxx_messageInfo_Message4.Size(m) |
| 350 | } |
| 351 | func (m *Message4) XXX_DiscardUnknown() { |
| 352 | xxx_messageInfo_Message4.DiscardUnknown(m) |
| 353 | } |
| 354 | |
| 355 | var xxx_messageInfo_Message4 proto.InternalMessageInfo |
| 356 | |
| 357 | func (m *Message4) GetBoolField() bool { |
| 358 | if m != nil && m.BoolField != nil { |
| 359 | return *m.BoolField |
| 360 | } |
| 361 | return false |
| 362 | } |
| 363 | |
| 364 | var E_StringField = &proto.ExtensionDesc{ |
| 365 | ExtendedType: (*Message1)(nil), |
| 366 | ExtensionType: (*string)(nil), |
| 367 | Field: 11, |
| 368 | Name: "testprotos.string_field", |
| 369 | Tag: "bytes,11,opt,name=string_field", |
| 370 | Filename: "reflect/protoregistry/testprotos/test.proto", |
| 371 | } |
| 372 | |
| 373 | var E_EnumField = &proto.ExtensionDesc{ |
| 374 | ExtendedType: (*Message1)(nil), |
| 375 | ExtensionType: (*Enum1)(nil), |
| 376 | Field: 12, |
| 377 | Name: "testprotos.enum_field", |
| 378 | Tag: "varint,12,opt,name=enum_field,enum=testprotos.Enum1", |
| 379 | Filename: "reflect/protoregistry/testprotos/test.proto", |
| 380 | } |
| 381 | |
| 382 | var E_MessageField = &proto.ExtensionDesc{ |
| 383 | ExtendedType: (*Message1)(nil), |
| 384 | ExtensionType: (*Message2)(nil), |
| 385 | Field: 13, |
| 386 | Name: "testprotos.message_field", |
| 387 | Tag: "bytes,13,opt,name=message_field", |
| 388 | Filename: "reflect/protoregistry/testprotos/test.proto", |
| 389 | } |
| 390 | |
| 391 | var E_Message4_MessageField = &proto.ExtensionDesc{ |
| 392 | ExtendedType: (*Message1)(nil), |
| 393 | ExtensionType: (*Message2)(nil), |
| 394 | Field: 21, |
| 395 | Name: "testprotos.Message4.message_field", |
| 396 | Tag: "bytes,21,opt,name=message_field", |
| 397 | Filename: "reflect/protoregistry/testprotos/test.proto", |
| 398 | } |
| 399 | |
| 400 | var E_Message4_EnumField = &proto.ExtensionDesc{ |
| 401 | ExtendedType: (*Message1)(nil), |
| 402 | ExtensionType: (*Enum1)(nil), |
| 403 | Field: 22, |
| 404 | Name: "testprotos.Message4.enum_field", |
| 405 | Tag: "varint,22,opt,name=enum_field,enum=testprotos.Enum1", |
| 406 | Filename: "reflect/protoregistry/testprotos/test.proto", |
| 407 | } |
| 408 | |
| 409 | var E_Message4_StringField = &proto.ExtensionDesc{ |
| 410 | ExtendedType: (*Message1)(nil), |
| 411 | ExtensionType: (*string)(nil), |
| 412 | Field: 23, |
| 413 | Name: "testprotos.Message4.string_field", |
| 414 | Tag: "bytes,23,opt,name=string_field", |
| 415 | Filename: "reflect/protoregistry/testprotos/test.proto", |
| 416 | } |
| 417 | |
| 418 | func init() { |
| 419 | proto.RegisterFile("reflect/protoregistry/testprotos/test.proto", fileDescriptor_3628d63611f7063d) |
| 420 | proto.RegisterEnum("testprotos.Enum1", Enum1_name, Enum1_value) |
| 421 | proto.RegisterEnum("testprotos.Enum2", Enum2_name, Enum2_value) |
| 422 | proto.RegisterEnum("testprotos.Enum3", Enum3_name, Enum3_value) |
| 423 | proto.RegisterType((*Message1)(nil), "testprotos.Message1") |
| 424 | proto.RegisterType((*Message2)(nil), "testprotos.Message2") |
| 425 | proto.RegisterType((*Message3)(nil), "testprotos.Message3") |
| 426 | proto.RegisterType((*Message4)(nil), "testprotos.Message4") |
| 427 | proto.RegisterExtension(E_StringField) |
| 428 | proto.RegisterExtension(E_EnumField) |
| 429 | proto.RegisterExtension(E_MessageField) |
| 430 | proto.RegisterExtension(E_Message4_MessageField) |
| 431 | proto.RegisterExtension(E_Message4_EnumField) |
| 432 | proto.RegisterExtension(E_Message4_StringField) |
| 433 | } |
| 434 | |
| 435 | var fileDescriptor_3628d63611f7063d = []byte{ |
| 436 | // 304 bytes of a gzipped FileDescriptorProto |
| 437 | 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x2e, 0x4a, 0x4d, 0xcb, |
| 438 | 0x49, 0x4d, 0x2e, 0xd1, 0x2f, 0x28, 0xca, 0x2f, 0xc9, 0x2f, 0x4a, 0x4d, 0xcf, 0x2c, 0x2e, 0x29, |
| 439 | 0xaa, 0xd4, 0x2f, 0x49, 0x2d, 0x2e, 0x01, 0x8b, 0x14, 0x83, 0x99, 0x7a, 0x60, 0xb6, 0x10, 0x17, |
| 440 | 0x42, 0x58, 0x49, 0x84, 0x8b, 0xc3, 0x37, 0xb5, 0xb8, 0x38, 0x31, 0x3d, 0xd5, 0x50, 0x8b, 0x83, |
| 441 | 0x83, 0x4b, 0xa0, 0xa1, 0xa1, 0xa1, 0x81, 0x49, 0x89, 0x0b, 0x2e, 0x6a, 0x84, 0xc4, 0x36, 0x56, |
| 442 | 0xfa, 0xcd, 0x08, 0xe7, 0x98, 0x08, 0xc9, 0x72, 0x71, 0x25, 0xe5, 0xe7, 0xe7, 0xc4, 0xa7, 0x65, |
| 443 | 0xa6, 0xe6, 0xa4, 0x48, 0xc8, 0x29, 0x30, 0x6a, 0x70, 0x04, 0x71, 0x82, 0x44, 0xdc, 0x40, 0x02, |
| 444 | 0x46, 0xfe, 0x5c, 0xbc, 0xb9, 0x10, 0xa5, 0x10, 0x15, 0x42, 0x22, 0x7a, 0x08, 0x7b, 0xf5, 0x60, |
| 445 | 0x96, 0x4a, 0x88, 0x2a, 0x30, 0x6a, 0x70, 0x1b, 0x61, 0x93, 0x33, 0x0a, 0xe2, 0x81, 0x1a, 0x00, |
| 446 | 0x31, 0xd0, 0x8d, 0x8b, 0x2b, 0x35, 0xaf, 0x34, 0x17, 0xaf, 0x69, 0x62, 0x0a, 0x8c, 0x1a, 0x7c, |
| 447 | 0x46, 0x82, 0xc8, 0x72, 0xae, 0x79, 0xa5, 0xb9, 0x86, 0x41, 0x9c, 0x20, 0xad, 0x10, 0x73, 0xcc, |
| 448 | 0xb9, 0x78, 0x8a, 0x4b, 0x8a, 0x32, 0xf3, 0xd2, 0xf1, 0x9a, 0x24, 0xae, 0xc0, 0xa8, 0xc1, 0x19, |
| 449 | 0xc4, 0x0d, 0x51, 0x09, 0xd6, 0xa8, 0x25, 0xc0, 0xc5, 0x0a, 0x36, 0x4c, 0x88, 0x9d, 0x8b, 0xd9, |
| 450 | 0xdf, 0xcf, 0x55, 0x80, 0x11, 0x26, 0x62, 0x04, 0x12, 0x09, 0xf5, 0xf3, 0x17, 0x60, 0xd4, 0xe2, |
| 451 | 0x87, 0x88, 0x18, 0x0b, 0xb1, 0x71, 0x31, 0x45, 0x7a, 0x0a, 0x30, 0x5a, 0x11, 0x67, 0x1b, 0x37, |
| 452 | 0x86, 0x6d, 0x56, 0xc4, 0x78, 0x97, 0x87, 0xb0, 0x77, 0xad, 0x88, 0x8c, 0x07, 0x5e, 0x62, 0xe3, |
| 453 | 0xc1, 0xc9, 0x21, 0xca, 0x2e, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0x3f, |
| 454 | 0x3d, 0x3f, 0x27, 0x31, 0x2f, 0x1d, 0x92, 0xee, 0x92, 0x4a, 0xd3, 0xf4, 0xcb, 0x8c, 0xf4, 0x09, |
| 455 | 0xa5, 0x45, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x76, 0x64, 0x81, 0x59, 0xae, 0x02, 0x00, 0x00, |
| 456 | } |
| 457 | |
| 458 | func init() { |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 459 | xxx_Test_protoFile_FileDesc.Enums = xxx_Test_protoFile_EnumDescs[0:3] |
| 460 | xxx_Test_protoFile_FileDesc.Messages = xxx_Test_protoFile_MessageDescs[0:4] |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 461 | var err error |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 462 | Test_protoFile, err = prototype.NewFile(&xxx_Test_protoFile_FileDesc) |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 463 | if err != nil { |
| 464 | panic(err) |
| 465 | } |
| 466 | } |
| 467 | |
| 468 | const _ = protoimpl.EnforceVersion(protoimpl.Version - 0) |
| 469 | |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 470 | var Test_protoFile protoreflect.FileDescriptor |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 471 | |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 472 | var xxx_Test_protoFile_FileDesc = prototype.File{ |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 473 | Syntax: protoreflect.Proto2, |
| 474 | Path: "reflect/protoregistry/testprotos/test.proto", |
| 475 | Package: "testprotos", |
| 476 | } |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 477 | var xxx_Test_protoFile_EnumTypes = [3]protoreflect.EnumType{ |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 478 | prototype.GoEnum( |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 479 | xxx_Test_protoFile_EnumDescs[0].Reference(), |
Damien Neil | a8593ba | 2019-01-08 16:18:07 -0800 | [diff] [blame] | 480 | func(_ protoreflect.EnumType, n protoreflect.EnumNumber) protoreflect.Enum { |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 481 | return Enum1(n) |
| 482 | }, |
| 483 | ), |
| 484 | prototype.GoEnum( |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 485 | xxx_Test_protoFile_EnumDescs[1].Reference(), |
Damien Neil | a8593ba | 2019-01-08 16:18:07 -0800 | [diff] [blame] | 486 | func(_ protoreflect.EnumType, n protoreflect.EnumNumber) protoreflect.Enum { |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 487 | return Enum2(n) |
| 488 | }, |
| 489 | ), |
| 490 | prototype.GoEnum( |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 491 | xxx_Test_protoFile_EnumDescs[2].Reference(), |
Damien Neil | a8593ba | 2019-01-08 16:18:07 -0800 | [diff] [blame] | 492 | func(_ protoreflect.EnumType, n protoreflect.EnumNumber) protoreflect.Enum { |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 493 | return Enum3(n) |
| 494 | }, |
| 495 | ), |
| 496 | } |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 497 | var xxx_Test_protoFile_EnumDescs = [3]prototype.Enum{ |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 498 | { |
| 499 | Name: "Enum1", |
| 500 | Values: []prototype.EnumValue{ |
| 501 | {Name: "ONE", Number: 1}, |
| 502 | }, |
| 503 | }, |
| 504 | { |
| 505 | Name: "Enum2", |
| 506 | Values: []prototype.EnumValue{ |
| 507 | {Name: "UNO", Number: 1}, |
| 508 | }, |
| 509 | }, |
| 510 | { |
| 511 | Name: "Enum3", |
| 512 | Values: []prototype.EnumValue{ |
| 513 | {Name: "YI", Number: 1}, |
| 514 | }, |
| 515 | }, |
| 516 | } |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 517 | var xxx_Test_protoFile_MessageTypes = [4]protoimpl.MessageType{ |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 518 | {Type: prototype.GoMessage( |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 519 | xxx_Test_protoFile_MessageDescs[0].Reference(), |
Joe Tsai | 3bc7d6f | 2019-01-09 02:57:13 -0800 | [diff] [blame] | 520 | func(protoreflect.MessageType) protoreflect.Message { |
| 521 | return xxx_Message1{new(Message1)} |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 522 | }, |
| 523 | )}, |
| 524 | {Type: prototype.GoMessage( |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 525 | xxx_Test_protoFile_MessageDescs[1].Reference(), |
Joe Tsai | 3bc7d6f | 2019-01-09 02:57:13 -0800 | [diff] [blame] | 526 | func(protoreflect.MessageType) protoreflect.Message { |
| 527 | return xxx_Message2{new(Message2)} |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 528 | }, |
| 529 | )}, |
| 530 | {Type: prototype.GoMessage( |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 531 | xxx_Test_protoFile_MessageDescs[2].Reference(), |
Joe Tsai | 3bc7d6f | 2019-01-09 02:57:13 -0800 | [diff] [blame] | 532 | func(protoreflect.MessageType) protoreflect.Message { |
| 533 | return xxx_Message3{new(Message3)} |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 534 | }, |
| 535 | )}, |
| 536 | {Type: prototype.GoMessage( |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 537 | xxx_Test_protoFile_MessageDescs[3].Reference(), |
Joe Tsai | 3bc7d6f | 2019-01-09 02:57:13 -0800 | [diff] [blame] | 538 | func(protoreflect.MessageType) protoreflect.Message { |
| 539 | return xxx_Message4{new(Message4)} |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 540 | }, |
| 541 | )}, |
| 542 | } |
Joe Tsai | 5681bb2 | 2019-01-09 21:31:15 -0800 | [diff] [blame^] | 543 | var xxx_Test_protoFile_MessageDescs = [4]prototype.Message{ |
Herbie Ong | 6e67a1d | 2018-12-26 15:57:16 -0800 | [diff] [blame] | 544 | { |
| 545 | Name: "Message1", |
| 546 | ExtensionRanges: [][2]protoreflect.FieldNumber{{10, 536870912}}, |
| 547 | }, |
| 548 | { |
| 549 | Name: "Message2", |
| 550 | }, |
| 551 | { |
| 552 | Name: "Message3", |
| 553 | }, |
| 554 | { |
| 555 | Name: "Message4", |
| 556 | Fields: []prototype.Field{ |
| 557 | { |
| 558 | Name: "bool_field", |
| 559 | Number: 30, |
| 560 | Cardinality: protoreflect.Optional, |
| 561 | Kind: protoreflect.BoolKind, |
| 562 | JSONName: "boolField", |
| 563 | IsPacked: prototype.False, |
| 564 | }, |
| 565 | }, |
| 566 | }, |
| 567 | } |