github.com/RomiChan/protobuf@v0.1.1-0.20230204044148-2ed269a2e54d/internal/benchmark/bench.pb.go (about) 1 // Code generated by protoc-gen-go. DO NOT EDIT. 2 // versions: 3 // protoc-gen-go v1.26.0 4 // protoc v3.17.1 5 // source: bench.proto 6 7 package benchmark 8 9 import ( 10 protoreflect "google.golang.org/protobuf/reflect/protoreflect" 11 protoimpl "google.golang.org/protobuf/runtime/protoimpl" 12 reflect "reflect" 13 sync "sync" 14 ) 15 16 const ( 17 // Verify that this generated code is sufficiently up-to-date. 18 _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) 19 // Verify that runtime/protoimpl is sufficiently up-to-date. 20 _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) 21 ) 22 23 type BenchSmall struct { 24 state protoimpl.MessageState 25 sizeCache protoimpl.SizeCache 26 unknownFields protoimpl.UnknownFields 27 28 Action *string `protobuf:"bytes,1,opt,name=action" json:"action,omitempty"` 29 Key []byte `protobuf:"bytes,2,opt,name=key" json:"key,omitempty"` 30 } 31 32 func (x *BenchSmall) Reset() { 33 *x = BenchSmall{} 34 if protoimpl.UnsafeEnabled { 35 mi := &file_bench_proto_msgTypes[0] 36 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 37 ms.StoreMessageInfo(mi) 38 } 39 } 40 41 func (x *BenchSmall) String() string { 42 return protoimpl.X.MessageStringOf(x) 43 } 44 45 func (*BenchSmall) ProtoMessage() {} 46 47 func (x *BenchSmall) ProtoReflect() protoreflect.Message { 48 mi := &file_bench_proto_msgTypes[0] 49 if protoimpl.UnsafeEnabled && x != nil { 50 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 51 if ms.LoadMessageInfo() == nil { 52 ms.StoreMessageInfo(mi) 53 } 54 return ms 55 } 56 return mi.MessageOf(x) 57 } 58 59 // Deprecated: Use BenchSmall.ProtoReflect.Descriptor instead. 60 func (*BenchSmall) Descriptor() ([]byte, []int) { 61 return file_bench_proto_rawDescGZIP(), []int{0} 62 } 63 64 func (x *BenchSmall) GetAction() string { 65 if x != nil && x.Action != nil { 66 return *x.Action 67 } 68 return "" 69 } 70 71 func (x *BenchSmall) GetKey() []byte { 72 if x != nil { 73 return x.Key 74 } 75 return nil 76 } 77 78 type BenchMedium struct { 79 state protoimpl.MessageState 80 sizeCache protoimpl.SizeCache 81 unknownFields protoimpl.UnknownFields 82 83 Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` 84 Age *int64 `protobuf:"varint,2,opt,name=age" json:"age,omitempty"` 85 Height *float32 `protobuf:"fixed32,3,opt,name=height" json:"height,omitempty"` 86 Weight *float64 `protobuf:"fixed64,4,opt,name=weight" json:"weight,omitempty"` 87 Alive *bool `protobuf:"varint,5,opt,name=alive" json:"alive,omitempty"` 88 Desc []byte `protobuf:"bytes,6,opt,name=desc" json:"desc,omitempty"` 89 } 90 91 func (x *BenchMedium) Reset() { 92 *x = BenchMedium{} 93 if protoimpl.UnsafeEnabled { 94 mi := &file_bench_proto_msgTypes[1] 95 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 96 ms.StoreMessageInfo(mi) 97 } 98 } 99 100 func (x *BenchMedium) String() string { 101 return protoimpl.X.MessageStringOf(x) 102 } 103 104 func (*BenchMedium) ProtoMessage() {} 105 106 func (x *BenchMedium) ProtoReflect() protoreflect.Message { 107 mi := &file_bench_proto_msgTypes[1] 108 if protoimpl.UnsafeEnabled && x != nil { 109 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 110 if ms.LoadMessageInfo() == nil { 111 ms.StoreMessageInfo(mi) 112 } 113 return ms 114 } 115 return mi.MessageOf(x) 116 } 117 118 // Deprecated: Use BenchMedium.ProtoReflect.Descriptor instead. 119 func (*BenchMedium) Descriptor() ([]byte, []int) { 120 return file_bench_proto_rawDescGZIP(), []int{1} 121 } 122 123 func (x *BenchMedium) GetName() string { 124 if x != nil && x.Name != nil { 125 return *x.Name 126 } 127 return "" 128 } 129 130 func (x *BenchMedium) GetAge() int64 { 131 if x != nil && x.Age != nil { 132 return *x.Age 133 } 134 return 0 135 } 136 137 func (x *BenchMedium) GetHeight() float32 { 138 if x != nil && x.Height != nil { 139 return *x.Height 140 } 141 return 0 142 } 143 144 func (x *BenchMedium) GetWeight() float64 { 145 if x != nil && x.Weight != nil { 146 return *x.Weight 147 } 148 return 0 149 } 150 151 func (x *BenchMedium) GetAlive() bool { 152 if x != nil && x.Alive != nil { 153 return *x.Alive 154 } 155 return false 156 } 157 158 func (x *BenchMedium) GetDesc() []byte { 159 if x != nil { 160 return x.Desc 161 } 162 return nil 163 } 164 165 type BenchLarge struct { 166 state protoimpl.MessageState 167 sizeCache protoimpl.SizeCache 168 unknownFields protoimpl.UnknownFields 169 170 Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` 171 Age *int64 `protobuf:"varint,2,opt,name=age" json:"age,omitempty"` 172 Height *float32 `protobuf:"fixed32,3,opt,name=height" json:"height,omitempty"` 173 Weight *float64 `protobuf:"fixed64,4,opt,name=weight" json:"weight,omitempty"` 174 Alive *bool `protobuf:"varint,5,opt,name=alive" json:"alive,omitempty"` 175 Desc []byte `protobuf:"bytes,6,opt,name=desc" json:"desc,omitempty"` 176 Nickname *string `protobuf:"bytes,7,opt,name=nickname" json:"nickname,omitempty"` 177 Num *int64 `protobuf:"varint,8,opt,name=num" json:"num,omitempty"` 178 Flt *float32 `protobuf:"fixed32,9,opt,name=flt" json:"flt,omitempty"` 179 Dbl *float64 `protobuf:"fixed64,10,opt,name=dbl" json:"dbl,omitempty"` 180 Tru *bool `protobuf:"varint,11,opt,name=tru" json:"tru,omitempty"` 181 Data []byte `protobuf:"bytes,12,opt,name=data" json:"data,omitempty"` 182 } 183 184 func (x *BenchLarge) Reset() { 185 *x = BenchLarge{} 186 if protoimpl.UnsafeEnabled { 187 mi := &file_bench_proto_msgTypes[2] 188 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 189 ms.StoreMessageInfo(mi) 190 } 191 } 192 193 func (x *BenchLarge) String() string { 194 return protoimpl.X.MessageStringOf(x) 195 } 196 197 func (*BenchLarge) ProtoMessage() {} 198 199 func (x *BenchLarge) ProtoReflect() protoreflect.Message { 200 mi := &file_bench_proto_msgTypes[2] 201 if protoimpl.UnsafeEnabled && x != nil { 202 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 203 if ms.LoadMessageInfo() == nil { 204 ms.StoreMessageInfo(mi) 205 } 206 return ms 207 } 208 return mi.MessageOf(x) 209 } 210 211 // Deprecated: Use BenchLarge.ProtoReflect.Descriptor instead. 212 func (*BenchLarge) Descriptor() ([]byte, []int) { 213 return file_bench_proto_rawDescGZIP(), []int{2} 214 } 215 216 func (x *BenchLarge) GetName() string { 217 if x != nil && x.Name != nil { 218 return *x.Name 219 } 220 return "" 221 } 222 223 func (x *BenchLarge) GetAge() int64 { 224 if x != nil && x.Age != nil { 225 return *x.Age 226 } 227 return 0 228 } 229 230 func (x *BenchLarge) GetHeight() float32 { 231 if x != nil && x.Height != nil { 232 return *x.Height 233 } 234 return 0 235 } 236 237 func (x *BenchLarge) GetWeight() float64 { 238 if x != nil && x.Weight != nil { 239 return *x.Weight 240 } 241 return 0 242 } 243 244 func (x *BenchLarge) GetAlive() bool { 245 if x != nil && x.Alive != nil { 246 return *x.Alive 247 } 248 return false 249 } 250 251 func (x *BenchLarge) GetDesc() []byte { 252 if x != nil { 253 return x.Desc 254 } 255 return nil 256 } 257 258 func (x *BenchLarge) GetNickname() string { 259 if x != nil && x.Nickname != nil { 260 return *x.Nickname 261 } 262 return "" 263 } 264 265 func (x *BenchLarge) GetNum() int64 { 266 if x != nil && x.Num != nil { 267 return *x.Num 268 } 269 return 0 270 } 271 272 func (x *BenchLarge) GetFlt() float32 { 273 if x != nil && x.Flt != nil { 274 return *x.Flt 275 } 276 return 0 277 } 278 279 func (x *BenchLarge) GetDbl() float64 { 280 if x != nil && x.Dbl != nil { 281 return *x.Dbl 282 } 283 return 0 284 } 285 286 func (x *BenchLarge) GetTru() bool { 287 if x != nil && x.Tru != nil { 288 return *x.Tru 289 } 290 return false 291 } 292 293 func (x *BenchLarge) GetData() []byte { 294 if x != nil { 295 return x.Data 296 } 297 return nil 298 } 299 300 type BenchNested struct { 301 state protoimpl.MessageState 302 sizeCache protoimpl.SizeCache 303 unknownFields protoimpl.UnknownFields 304 305 Small *BenchSmall `protobuf:"bytes,1,opt,name=small" json:"small,omitempty"` 306 Medium *BenchMedium `protobuf:"bytes,2,opt,name=medium" json:"medium,omitempty"` 307 Large *BenchLarge `protobuf:"bytes,3,opt,name=large" json:"large,omitempty"` 308 } 309 310 func (x *BenchNested) Reset() { 311 *x = BenchNested{} 312 if protoimpl.UnsafeEnabled { 313 mi := &file_bench_proto_msgTypes[3] 314 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 315 ms.StoreMessageInfo(mi) 316 } 317 } 318 319 func (x *BenchNested) String() string { 320 return protoimpl.X.MessageStringOf(x) 321 } 322 323 func (*BenchNested) ProtoMessage() {} 324 325 func (x *BenchNested) ProtoReflect() protoreflect.Message { 326 mi := &file_bench_proto_msgTypes[3] 327 if protoimpl.UnsafeEnabled && x != nil { 328 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 329 if ms.LoadMessageInfo() == nil { 330 ms.StoreMessageInfo(mi) 331 } 332 return ms 333 } 334 return mi.MessageOf(x) 335 } 336 337 // Deprecated: Use BenchNested.ProtoReflect.Descriptor instead. 338 func (*BenchNested) Descriptor() ([]byte, []int) { 339 return file_bench_proto_rawDescGZIP(), []int{3} 340 } 341 342 func (x *BenchNested) GetSmall() *BenchSmall { 343 if x != nil { 344 return x.Small 345 } 346 return nil 347 } 348 349 func (x *BenchNested) GetMedium() *BenchMedium { 350 if x != nil { 351 return x.Medium 352 } 353 return nil 354 } 355 356 func (x *BenchNested) GetLarge() *BenchLarge { 357 if x != nil { 358 return x.Large 359 } 360 return nil 361 } 362 363 var File_bench_proto protoreflect.FileDescriptor 364 365 var file_bench_proto_rawDesc = []byte{ 366 0x0a, 0x0b, 0x62, 0x65, 0x6e, 0x63, 0x68, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x02, 0x70, 367 0x62, 0x22, 0x36, 0x0a, 0x0a, 0x42, 0x65, 0x6e, 0x63, 0x68, 0x53, 0x6d, 0x61, 0x6c, 0x6c, 0x12, 368 0x16, 0x0a, 0x06, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 369 0x06, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x02, 370 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x22, 0x8d, 0x01, 0x0a, 0x0b, 0x42, 0x65, 371 0x6e, 0x63, 0x68, 0x4d, 0x65, 0x64, 0x69, 0x75, 0x6d, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 372 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x10, 0x0a, 373 0x03, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x61, 0x67, 0x65, 0x12, 374 0x16, 0x0a, 0x06, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x02, 0x52, 375 0x06, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x77, 0x65, 0x69, 0x67, 0x68, 376 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x01, 0x52, 0x06, 0x77, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, 377 0x14, 0x0a, 0x05, 0x61, 0x6c, 0x69, 0x76, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 378 0x61, 0x6c, 0x69, 0x76, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x65, 0x73, 0x63, 0x18, 0x06, 0x20, 379 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x65, 0x73, 0x63, 0x22, 0x84, 0x02, 0x0a, 0x0a, 0x42, 0x65, 380 0x6e, 0x63, 0x68, 0x4c, 0x61, 0x72, 0x67, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 381 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 382 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x61, 0x67, 0x65, 0x12, 0x16, 383 0x0a, 0x06, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x02, 0x52, 0x06, 384 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x77, 0x65, 0x69, 0x67, 0x68, 0x74, 385 0x18, 0x04, 0x20, 0x01, 0x28, 0x01, 0x52, 0x06, 0x77, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, 0x14, 386 0x0a, 0x05, 0x61, 0x6c, 0x69, 0x76, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x61, 387 0x6c, 0x69, 0x76, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x65, 0x73, 0x63, 0x18, 0x06, 0x20, 0x01, 388 0x28, 0x0c, 0x52, 0x04, 0x64, 0x65, 0x73, 0x63, 0x12, 0x1a, 0x0a, 0x08, 0x6e, 0x69, 0x63, 0x6b, 389 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6e, 0x69, 0x63, 0x6b, 390 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6e, 0x75, 0x6d, 0x18, 0x08, 0x20, 0x01, 0x28, 391 0x03, 0x52, 0x03, 0x6e, 0x75, 0x6d, 0x12, 0x10, 0x0a, 0x03, 0x66, 0x6c, 0x74, 0x18, 0x09, 0x20, 392 0x01, 0x28, 0x02, 0x52, 0x03, 0x66, 0x6c, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x64, 0x62, 0x6c, 0x18, 393 0x0a, 0x20, 0x01, 0x28, 0x01, 0x52, 0x03, 0x64, 0x62, 0x6c, 0x12, 0x10, 0x0a, 0x03, 0x74, 0x72, 394 0x75, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x08, 0x52, 0x03, 0x74, 0x72, 0x75, 0x12, 0x12, 0x0a, 0x04, 395 0x64, 0x61, 0x74, 0x61, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 396 0x22, 0x82, 0x01, 0x0a, 0x0b, 0x42, 0x65, 0x6e, 0x63, 0x68, 0x4e, 0x65, 0x73, 0x74, 0x65, 0x64, 397 0x12, 0x24, 0x0a, 0x05, 0x73, 0x6d, 0x61, 0x6c, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 398 0x0e, 0x2e, 0x70, 0x62, 0x2e, 0x42, 0x65, 0x6e, 0x63, 0x68, 0x53, 0x6d, 0x61, 0x6c, 0x6c, 0x52, 399 0x05, 0x73, 0x6d, 0x61, 0x6c, 0x6c, 0x12, 0x27, 0x0a, 0x06, 0x6d, 0x65, 0x64, 0x69, 0x75, 0x6d, 400 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x70, 0x62, 0x2e, 0x42, 0x65, 0x6e, 0x63, 401 0x68, 0x4d, 0x65, 0x64, 0x69, 0x75, 0x6d, 0x52, 0x06, 0x6d, 0x65, 0x64, 0x69, 0x75, 0x6d, 0x12, 402 0x24, 0x0a, 0x05, 0x6c, 0x61, 0x72, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 403 0x2e, 0x70, 0x62, 0x2e, 0x42, 0x65, 0x6e, 0x63, 0x68, 0x4c, 0x61, 0x72, 0x67, 0x65, 0x52, 0x05, 404 0x6c, 0x61, 0x72, 0x67, 0x65, 0x42, 0x0e, 0x5a, 0x0c, 0x2e, 0x2f, 0x3b, 0x62, 0x65, 0x6e, 0x63, 405 0x68, 0x6d, 0x61, 0x72, 0x6b, 406 } 407 408 var ( 409 file_bench_proto_rawDescOnce sync.Once 410 file_bench_proto_rawDescData = file_bench_proto_rawDesc 411 ) 412 413 func file_bench_proto_rawDescGZIP() []byte { 414 file_bench_proto_rawDescOnce.Do(func() { 415 file_bench_proto_rawDescData = protoimpl.X.CompressGZIP(file_bench_proto_rawDescData) 416 }) 417 return file_bench_proto_rawDescData 418 } 419 420 var file_bench_proto_msgTypes = make([]protoimpl.MessageInfo, 4) 421 var file_bench_proto_goTypes = []interface{}{ 422 (*BenchSmall)(nil), // 0: pb.BenchSmall 423 (*BenchMedium)(nil), // 1: pb.BenchMedium 424 (*BenchLarge)(nil), // 2: pb.BenchLarge 425 (*BenchNested)(nil), // 3: pb.BenchNested 426 } 427 var file_bench_proto_depIdxs = []int32{ 428 0, // 0: pb.BenchNested.small:type_name -> pb.BenchSmall 429 1, // 1: pb.BenchNested.medium:type_name -> pb.BenchMedium 430 2, // 2: pb.BenchNested.large:type_name -> pb.BenchLarge 431 3, // [3:3] is the sub-list for method output_type 432 3, // [3:3] is the sub-list for method input_type 433 3, // [3:3] is the sub-list for extension type_name 434 3, // [3:3] is the sub-list for extension extendee 435 0, // [0:3] is the sub-list for field type_name 436 } 437 438 func init() { file_bench_proto_init() } 439 func file_bench_proto_init() { 440 if File_bench_proto != nil { 441 return 442 } 443 if !protoimpl.UnsafeEnabled { 444 file_bench_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { 445 switch v := v.(*BenchSmall); i { 446 case 0: 447 return &v.state 448 case 1: 449 return &v.sizeCache 450 case 2: 451 return &v.unknownFields 452 default: 453 return nil 454 } 455 } 456 file_bench_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { 457 switch v := v.(*BenchMedium); i { 458 case 0: 459 return &v.state 460 case 1: 461 return &v.sizeCache 462 case 2: 463 return &v.unknownFields 464 default: 465 return nil 466 } 467 } 468 file_bench_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { 469 switch v := v.(*BenchLarge); i { 470 case 0: 471 return &v.state 472 case 1: 473 return &v.sizeCache 474 case 2: 475 return &v.unknownFields 476 default: 477 return nil 478 } 479 } 480 file_bench_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { 481 switch v := v.(*BenchNested); i { 482 case 0: 483 return &v.state 484 case 1: 485 return &v.sizeCache 486 case 2: 487 return &v.unknownFields 488 default: 489 return nil 490 } 491 } 492 } 493 type x struct{} 494 out := protoimpl.TypeBuilder{ 495 File: protoimpl.DescBuilder{ 496 GoPackagePath: reflect.TypeOf(x{}).PkgPath(), 497 RawDescriptor: file_bench_proto_rawDesc, 498 NumEnums: 0, 499 NumMessages: 4, 500 NumExtensions: 0, 501 NumServices: 0, 502 }, 503 GoTypes: file_bench_proto_goTypes, 504 DependencyIndexes: file_bench_proto_depIdxs, 505 MessageInfos: file_bench_proto_msgTypes, 506 }.Build() 507 File_bench_proto = out.File 508 file_bench_proto_rawDesc = nil 509 file_bench_proto_goTypes = nil 510 file_bench_proto_depIdxs = nil 511 }