github.com/cloudwan/edgelq-sdk@v1.15.4/alerting/client/v1/alert/alert_service.pb.descriptors.go (about) 1 // Code generated by protoc-gen-goten-client 2 // API: AlertService 3 // DO NOT EDIT!!! 4 5 package alert_client 6 7 import ( 8 "google.golang.org/protobuf/proto" 9 10 gotenclient "github.com/cloudwan/goten-sdk/runtime/client" 11 gotenresource "github.com/cloudwan/goten-sdk/runtime/resource" 12 ) 13 14 // proto imports 15 import ( 16 alert "github.com/cloudwan/edgelq-sdk/alerting/resources/v1/alert" 17 emptypb "google.golang.org/protobuf/types/known/emptypb" 18 ) 19 20 // Reference imports to suppress errors if they are not otherwise used. 21 var ( 22 _ = new(proto.Message) 23 _ = new(gotenclient.MethodDescriptor) 24 _ = gotenresource.WildcardId 25 ) 26 27 // make sure we're using proto imports 28 var ( 29 _ = &alert.Alert{} 30 _ = &emptypb.Empty{} 31 ) 32 33 var ( 34 descriptorsInitialized bool 35 alertServiceDescriptor *AlertServiceDescriptor 36 getAlertDescriptor *GetAlertDescriptor 37 batchGetAlertsDescriptor *BatchGetAlertsDescriptor 38 listAlertsDescriptor *ListAlertsDescriptor 39 watchAlertDescriptor *WatchAlertDescriptor 40 watchAlertsDescriptor *WatchAlertsDescriptor 41 createAlertDescriptor *CreateAlertDescriptor 42 updateAlertDescriptor *UpdateAlertDescriptor 43 deleteAlertDescriptor *DeleteAlertDescriptor 44 bulkSaveAlertsDescriptor *BulkSaveAlertsDescriptor 45 bulkMarkAsNotifiedDescriptor *BulkMarkAsNotifiedDescriptor 46 ) 47 48 type GetAlertDescriptor struct{} 49 50 type GetAlertDescriptorClientMsgHandle struct{} 51 52 type GetAlertDescriptorServerMsgHandle struct{} 53 54 func (d *GetAlertDescriptor) NewEmptyClientMsg() proto.Message { 55 return &GetAlertRequest{} 56 } 57 58 func (d *GetAlertDescriptor) NewEmptyServerMsg() proto.Message { 59 return &alert.Alert{} 60 } 61 62 func (d *GetAlertDescriptor) IsUnary() bool { 63 return true 64 } 65 66 func (d *GetAlertDescriptor) IsClientStream() bool { 67 return false 68 } 69 70 func (d *GetAlertDescriptor) IsServerStream() bool { 71 return false 72 } 73 74 func (d *GetAlertDescriptor) IsCollection() bool { 75 return false 76 } 77 78 func (d *GetAlertDescriptor) IsPlural() bool { 79 return false 80 } 81 82 func (d *GetAlertDescriptor) HasResource() bool { 83 return true 84 } 85 86 func (d *GetAlertDescriptor) RequestHasResourceBody() bool { 87 return false 88 } 89 90 func (d *GetAlertDescriptor) GetVerb() string { 91 return "get" 92 } 93 94 func (d *GetAlertDescriptor) GetMethodName() string { 95 return "GetAlert" 96 } 97 98 func (d *GetAlertDescriptor) GetFullMethodName() string { 99 return "/ntt.alerting.v1.AlertService/GetAlert" 100 } 101 102 func (d *GetAlertDescriptor) GetProtoPkgName() string { 103 return "ntt.alerting.v1" 104 } 105 106 func (d *GetAlertDescriptor) GetApiName() string { 107 return "AlertService" 108 } 109 110 func (d *GetAlertDescriptor) GetServiceDomain() string { 111 return "alerting.edgelq.com" 112 } 113 114 func (d *GetAlertDescriptor) GetServiceVersion() string { 115 return "v1" 116 } 117 118 func (d *GetAlertDescriptor) GetApiDescriptor() gotenclient.ApiDescriptor { 119 return alertServiceDescriptor 120 } 121 122 func (d *GetAlertDescriptor) GetResourceDescriptor() gotenresource.Descriptor { 123 return alert.GetDescriptor() 124 } 125 126 func (d *GetAlertDescriptor) GetClientMsgReflectHandle() gotenclient.MethodMsgHandle { 127 return &GetAlertDescriptorClientMsgHandle{} 128 } 129 130 func (d *GetAlertDescriptor) GetServerMsgReflectHandle() gotenclient.MethodMsgHandle { 131 return &GetAlertDescriptorServerMsgHandle{} 132 } 133 134 func (h *GetAlertDescriptorClientMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 135 typedMsg := msg.(*GetAlertRequest) 136 var asInterface interface{} = h 137 override, ok := asInterface.(interface { 138 OverrideExtractResourceName(*GetAlertRequest) *alert.Name 139 }) 140 if ok { 141 return override.OverrideExtractResourceName(typedMsg) 142 } 143 { 144 if name := typedMsg.GetName(); name != nil { 145 return name 146 } 147 } 148 return (*alert.Name)(nil) 149 } 150 151 func (h *GetAlertDescriptorClientMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 152 typedMsg := msg.(*GetAlertRequest) 153 var asInterface interface{} = h 154 override, ok := asInterface.(interface { 155 OverrideExtractResourceNames(*GetAlertRequest) []*alert.Name 156 }) 157 if ok { 158 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 159 } 160 return nil 161 } 162 163 func (h *GetAlertDescriptorClientMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 164 typedMsg := msg.(*GetAlertRequest) 165 var asInterface interface{} = h 166 override, ok := asInterface.(interface { 167 OverrideExtractCollectionName(*GetAlertRequest) *alert.ParentName 168 }) 169 if ok { 170 return override.OverrideExtractCollectionName(typedMsg) 171 } 172 return nil 173 } 174 175 func (h *GetAlertDescriptorClientMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 176 typedMsg := msg.(*GetAlertRequest) 177 var asInterface interface{} = h 178 override, ok := asInterface.(interface { 179 OverrideExtractResourceBody(*GetAlertRequest) *alert.Alert 180 }) 181 if ok { 182 return override.OverrideExtractResourceBody(typedMsg) 183 } 184 return nil 185 } 186 187 func (h *GetAlertDescriptorClientMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 188 typedMsg := msg.(*GetAlertRequest) 189 var asInterface interface{} = h 190 override, ok := asInterface.(interface { 191 OverrideExtractResourceBodies(*GetAlertRequest) []*alert.Alert 192 }) 193 if ok { 194 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 195 } 196 return nil 197 } 198 199 func (h *GetAlertDescriptorServerMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 200 typedMsg := msg.(*alert.Alert) 201 var asInterface interface{} = h 202 override, ok := asInterface.(interface { 203 OverrideExtractResourceName(*alert.Alert) *alert.Name 204 }) 205 if ok { 206 return override.OverrideExtractResourceName(typedMsg) 207 } 208 { 209 if name := typedMsg.GetName(); name != nil { 210 return name 211 } 212 } 213 return (*alert.Name)(nil) 214 } 215 216 func (h *GetAlertDescriptorServerMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 217 typedMsg := msg.(*alert.Alert) 218 var asInterface interface{} = h 219 override, ok := asInterface.(interface { 220 OverrideExtractResourceNames(*alert.Alert) []*alert.Name 221 }) 222 if ok { 223 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 224 } 225 return nil 226 } 227 228 func (h *GetAlertDescriptorServerMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 229 typedMsg := msg.(*alert.Alert) 230 var asInterface interface{} = h 231 override, ok := asInterface.(interface { 232 OverrideExtractCollectionName(*alert.Alert) *alert.ParentName 233 }) 234 if ok { 235 return override.OverrideExtractCollectionName(typedMsg) 236 } 237 return nil 238 } 239 240 func (h *GetAlertDescriptorServerMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 241 return msg.(*alert.Alert) 242 } 243 244 func (h *GetAlertDescriptorServerMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 245 typedMsg := msg.(*alert.Alert) 246 var asInterface interface{} = h 247 override, ok := asInterface.(interface { 248 OverrideExtractResourceBodies(*alert.Alert) []*alert.Alert 249 }) 250 if ok { 251 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 252 } 253 return nil 254 } 255 256 func GetGetAlertDescriptor() *GetAlertDescriptor { 257 return getAlertDescriptor 258 } 259 260 type BatchGetAlertsDescriptor struct{} 261 262 type BatchGetAlertsDescriptorClientMsgHandle struct{} 263 264 type BatchGetAlertsDescriptorServerMsgHandle struct{} 265 266 func (d *BatchGetAlertsDescriptor) NewEmptyClientMsg() proto.Message { 267 return &BatchGetAlertsRequest{} 268 } 269 270 func (d *BatchGetAlertsDescriptor) NewEmptyServerMsg() proto.Message { 271 return &BatchGetAlertsResponse{} 272 } 273 274 func (d *BatchGetAlertsDescriptor) IsUnary() bool { 275 return true 276 } 277 278 func (d *BatchGetAlertsDescriptor) IsClientStream() bool { 279 return false 280 } 281 282 func (d *BatchGetAlertsDescriptor) IsServerStream() bool { 283 return false 284 } 285 286 func (d *BatchGetAlertsDescriptor) IsCollection() bool { 287 return false 288 } 289 290 func (d *BatchGetAlertsDescriptor) IsPlural() bool { 291 return true 292 } 293 294 func (d *BatchGetAlertsDescriptor) HasResource() bool { 295 return true 296 } 297 298 func (d *BatchGetAlertsDescriptor) RequestHasResourceBody() bool { 299 return false 300 } 301 302 func (d *BatchGetAlertsDescriptor) GetVerb() string { 303 return "batchGet" 304 } 305 306 func (d *BatchGetAlertsDescriptor) GetMethodName() string { 307 return "BatchGetAlerts" 308 } 309 310 func (d *BatchGetAlertsDescriptor) GetFullMethodName() string { 311 return "/ntt.alerting.v1.AlertService/BatchGetAlerts" 312 } 313 314 func (d *BatchGetAlertsDescriptor) GetProtoPkgName() string { 315 return "ntt.alerting.v1" 316 } 317 318 func (d *BatchGetAlertsDescriptor) GetApiName() string { 319 return "AlertService" 320 } 321 322 func (d *BatchGetAlertsDescriptor) GetServiceDomain() string { 323 return "alerting.edgelq.com" 324 } 325 326 func (d *BatchGetAlertsDescriptor) GetServiceVersion() string { 327 return "v1" 328 } 329 330 func (d *BatchGetAlertsDescriptor) GetApiDescriptor() gotenclient.ApiDescriptor { 331 return alertServiceDescriptor 332 } 333 334 func (d *BatchGetAlertsDescriptor) GetResourceDescriptor() gotenresource.Descriptor { 335 return alert.GetDescriptor() 336 } 337 338 func (d *BatchGetAlertsDescriptor) GetClientMsgReflectHandle() gotenclient.MethodMsgHandle { 339 return &BatchGetAlertsDescriptorClientMsgHandle{} 340 } 341 342 func (d *BatchGetAlertsDescriptor) GetServerMsgReflectHandle() gotenclient.MethodMsgHandle { 343 return &BatchGetAlertsDescriptorServerMsgHandle{} 344 } 345 346 func (h *BatchGetAlertsDescriptorClientMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 347 typedMsg := msg.(*BatchGetAlertsRequest) 348 var asInterface interface{} = h 349 override, ok := asInterface.(interface { 350 OverrideExtractResourceName(*BatchGetAlertsRequest) *alert.Name 351 }) 352 if ok { 353 return override.OverrideExtractResourceName(typedMsg) 354 } 355 return nil 356 } 357 358 func (h *BatchGetAlertsDescriptorClientMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 359 typedMsg := msg.(*BatchGetAlertsRequest) 360 var asInterface interface{} = h 361 override, ok := asInterface.(interface { 362 OverrideExtractResourceNames(*BatchGetAlertsRequest) []*alert.Name 363 }) 364 if ok { 365 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 366 } 367 { 368 if names := typedMsg.GetNames(); len(names) > 0 { 369 return alert.AlertNameList(names) 370 } 371 } 372 return (alert.AlertNameList)(nil) 373 } 374 375 func (h *BatchGetAlertsDescriptorClientMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 376 typedMsg := msg.(*BatchGetAlertsRequest) 377 var asInterface interface{} = h 378 override, ok := asInterface.(interface { 379 OverrideExtractCollectionName(*BatchGetAlertsRequest) *alert.ParentName 380 }) 381 if ok { 382 return override.OverrideExtractCollectionName(typedMsg) 383 } 384 return nil 385 } 386 387 func (h *BatchGetAlertsDescriptorClientMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 388 typedMsg := msg.(*BatchGetAlertsRequest) 389 var asInterface interface{} = h 390 override, ok := asInterface.(interface { 391 OverrideExtractResourceBody(*BatchGetAlertsRequest) *alert.Alert 392 }) 393 if ok { 394 return override.OverrideExtractResourceBody(typedMsg) 395 } 396 return nil 397 } 398 399 func (h *BatchGetAlertsDescriptorClientMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 400 typedMsg := msg.(*BatchGetAlertsRequest) 401 var asInterface interface{} = h 402 override, ok := asInterface.(interface { 403 OverrideExtractResourceBodies(*BatchGetAlertsRequest) []*alert.Alert 404 }) 405 if ok { 406 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 407 } 408 return nil 409 } 410 411 func (h *BatchGetAlertsDescriptorServerMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 412 typedMsg := msg.(*BatchGetAlertsResponse) 413 var asInterface interface{} = h 414 override, ok := asInterface.(interface { 415 OverrideExtractResourceName(*BatchGetAlertsResponse) *alert.Name 416 }) 417 if ok { 418 return override.OverrideExtractResourceName(typedMsg) 419 } 420 return nil 421 } 422 423 func (h *BatchGetAlertsDescriptorServerMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 424 typedMsg := msg.(*BatchGetAlertsResponse) 425 var asInterface interface{} = h 426 override, ok := asInterface.(interface { 427 OverrideExtractResourceNames(*BatchGetAlertsResponse) []*alert.Name 428 }) 429 if ok { 430 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 431 } 432 { 433 if resources := typedMsg.GetAlerts(); len(resources) > 0 { 434 list := make(alert.AlertNameList, 0, len(resources)) 435 for _, res := range resources { 436 list = append(list, res.GetName()) 437 } 438 return list 439 } 440 } 441 return (alert.AlertNameList)(nil) 442 } 443 444 func (h *BatchGetAlertsDescriptorServerMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 445 typedMsg := msg.(*BatchGetAlertsResponse) 446 var asInterface interface{} = h 447 override, ok := asInterface.(interface { 448 OverrideExtractCollectionName(*BatchGetAlertsResponse) *alert.ParentName 449 }) 450 if ok { 451 return override.OverrideExtractCollectionName(typedMsg) 452 } 453 return nil 454 } 455 456 func (h *BatchGetAlertsDescriptorServerMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 457 typedMsg := msg.(*BatchGetAlertsResponse) 458 var asInterface interface{} = h 459 override, ok := asInterface.(interface { 460 OverrideExtractResourceBody(*BatchGetAlertsResponse) *alert.Alert 461 }) 462 if ok { 463 return override.OverrideExtractResourceBody(typedMsg) 464 } 465 return nil 466 } 467 468 func (h *BatchGetAlertsDescriptorServerMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 469 typedMsg := msg.(*BatchGetAlertsResponse) 470 var asInterface interface{} = h 471 override, ok := asInterface.(interface { 472 OverrideExtractResourceBodies(*BatchGetAlertsResponse) []*alert.Alert 473 }) 474 if ok { 475 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 476 } 477 { 478 if resources := typedMsg.GetAlerts(); len(resources) > 0 { 479 return alert.AlertList(resources) 480 } 481 } 482 return (alert.AlertList)(nil) 483 } 484 485 func GetBatchGetAlertsDescriptor() *BatchGetAlertsDescriptor { 486 return batchGetAlertsDescriptor 487 } 488 489 type ListAlertsDescriptor struct{} 490 491 type ListAlertsDescriptorClientMsgHandle struct{} 492 493 type ListAlertsDescriptorServerMsgHandle struct{} 494 495 func (d *ListAlertsDescriptor) NewEmptyClientMsg() proto.Message { 496 return &ListAlertsRequest{} 497 } 498 499 func (d *ListAlertsDescriptor) NewEmptyServerMsg() proto.Message { 500 return &ListAlertsResponse{} 501 } 502 503 func (d *ListAlertsDescriptor) IsUnary() bool { 504 return true 505 } 506 507 func (d *ListAlertsDescriptor) IsClientStream() bool { 508 return false 509 } 510 511 func (d *ListAlertsDescriptor) IsServerStream() bool { 512 return false 513 } 514 515 func (d *ListAlertsDescriptor) IsCollection() bool { 516 return true 517 } 518 519 func (d *ListAlertsDescriptor) IsPlural() bool { 520 return true 521 } 522 523 func (d *ListAlertsDescriptor) HasResource() bool { 524 return true 525 } 526 527 func (d *ListAlertsDescriptor) RequestHasResourceBody() bool { 528 return false 529 } 530 531 func (d *ListAlertsDescriptor) GetVerb() string { 532 return "list" 533 } 534 535 func (d *ListAlertsDescriptor) GetMethodName() string { 536 return "ListAlerts" 537 } 538 539 func (d *ListAlertsDescriptor) GetFullMethodName() string { 540 return "/ntt.alerting.v1.AlertService/ListAlerts" 541 } 542 543 func (d *ListAlertsDescriptor) GetProtoPkgName() string { 544 return "ntt.alerting.v1" 545 } 546 547 func (d *ListAlertsDescriptor) GetApiName() string { 548 return "AlertService" 549 } 550 551 func (d *ListAlertsDescriptor) GetServiceDomain() string { 552 return "alerting.edgelq.com" 553 } 554 555 func (d *ListAlertsDescriptor) GetServiceVersion() string { 556 return "v1" 557 } 558 559 func (d *ListAlertsDescriptor) GetApiDescriptor() gotenclient.ApiDescriptor { 560 return alertServiceDescriptor 561 } 562 563 func (d *ListAlertsDescriptor) GetResourceDescriptor() gotenresource.Descriptor { 564 return alert.GetDescriptor() 565 } 566 567 func (d *ListAlertsDescriptor) GetClientMsgReflectHandle() gotenclient.MethodMsgHandle { 568 return &ListAlertsDescriptorClientMsgHandle{} 569 } 570 571 func (d *ListAlertsDescriptor) GetServerMsgReflectHandle() gotenclient.MethodMsgHandle { 572 return &ListAlertsDescriptorServerMsgHandle{} 573 } 574 575 func (h *ListAlertsDescriptorClientMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 576 typedMsg := msg.(*ListAlertsRequest) 577 var asInterface interface{} = h 578 override, ok := asInterface.(interface { 579 OverrideExtractResourceName(*ListAlertsRequest) *alert.Name 580 }) 581 if ok { 582 return override.OverrideExtractResourceName(typedMsg) 583 } 584 return nil 585 } 586 587 func (h *ListAlertsDescriptorClientMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 588 typedMsg := msg.(*ListAlertsRequest) 589 var asInterface interface{} = h 590 override, ok := asInterface.(interface { 591 OverrideExtractResourceNames(*ListAlertsRequest) []*alert.Name 592 }) 593 if ok { 594 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 595 } 596 return nil 597 } 598 599 func (h *ListAlertsDescriptorClientMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 600 typedMsg := msg.(*ListAlertsRequest) 601 var asInterface interface{} = h 602 override, ok := asInterface.(interface { 603 OverrideExtractCollectionName(*ListAlertsRequest) *alert.ParentName 604 }) 605 if ok { 606 return override.OverrideExtractCollectionName(typedMsg) 607 } 608 { 609 if parentName := typedMsg.GetParent(); parentName != nil { 610 return parentName 611 } 612 } 613 return (*alert.ParentName)(nil) 614 } 615 616 func (h *ListAlertsDescriptorClientMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 617 typedMsg := msg.(*ListAlertsRequest) 618 var asInterface interface{} = h 619 override, ok := asInterface.(interface { 620 OverrideExtractResourceBody(*ListAlertsRequest) *alert.Alert 621 }) 622 if ok { 623 return override.OverrideExtractResourceBody(typedMsg) 624 } 625 return nil 626 } 627 628 func (h *ListAlertsDescriptorClientMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 629 typedMsg := msg.(*ListAlertsRequest) 630 var asInterface interface{} = h 631 override, ok := asInterface.(interface { 632 OverrideExtractResourceBodies(*ListAlertsRequest) []*alert.Alert 633 }) 634 if ok { 635 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 636 } 637 return nil 638 } 639 640 func (h *ListAlertsDescriptorServerMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 641 typedMsg := msg.(*ListAlertsResponse) 642 var asInterface interface{} = h 643 override, ok := asInterface.(interface { 644 OverrideExtractResourceName(*ListAlertsResponse) *alert.Name 645 }) 646 if ok { 647 return override.OverrideExtractResourceName(typedMsg) 648 } 649 return nil 650 } 651 652 func (h *ListAlertsDescriptorServerMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 653 typedMsg := msg.(*ListAlertsResponse) 654 var asInterface interface{} = h 655 override, ok := asInterface.(interface { 656 OverrideExtractResourceNames(*ListAlertsResponse) []*alert.Name 657 }) 658 if ok { 659 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 660 } 661 { 662 if resources := typedMsg.GetAlerts(); len(resources) > 0 { 663 list := make(alert.AlertNameList, 0, len(resources)) 664 for _, res := range resources { 665 list = append(list, res.GetName()) 666 } 667 return list 668 } 669 } 670 return (alert.AlertNameList)(nil) 671 } 672 673 func (h *ListAlertsDescriptorServerMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 674 typedMsg := msg.(*ListAlertsResponse) 675 var asInterface interface{} = h 676 override, ok := asInterface.(interface { 677 OverrideExtractCollectionName(*ListAlertsResponse) *alert.ParentName 678 }) 679 if ok { 680 return override.OverrideExtractCollectionName(typedMsg) 681 } 682 return nil 683 } 684 685 func (h *ListAlertsDescriptorServerMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 686 typedMsg := msg.(*ListAlertsResponse) 687 var asInterface interface{} = h 688 override, ok := asInterface.(interface { 689 OverrideExtractResourceBody(*ListAlertsResponse) *alert.Alert 690 }) 691 if ok { 692 return override.OverrideExtractResourceBody(typedMsg) 693 } 694 return nil 695 } 696 697 func (h *ListAlertsDescriptorServerMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 698 typedMsg := msg.(*ListAlertsResponse) 699 var asInterface interface{} = h 700 override, ok := asInterface.(interface { 701 OverrideExtractResourceBodies(*ListAlertsResponse) []*alert.Alert 702 }) 703 if ok { 704 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 705 } 706 { 707 if resources := typedMsg.GetAlerts(); len(resources) > 0 { 708 return alert.AlertList(resources) 709 } 710 } 711 return (alert.AlertList)(nil) 712 } 713 714 func GetListAlertsDescriptor() *ListAlertsDescriptor { 715 return listAlertsDescriptor 716 } 717 718 type WatchAlertDescriptor struct{} 719 720 type WatchAlertDescriptorClientMsgHandle struct{} 721 722 type WatchAlertDescriptorServerMsgHandle struct{} 723 724 func (d *WatchAlertDescriptor) NewEmptyClientMsg() proto.Message { 725 return &WatchAlertRequest{} 726 } 727 728 func (d *WatchAlertDescriptor) NewEmptyServerMsg() proto.Message { 729 return &WatchAlertResponse{} 730 } 731 732 func (d *WatchAlertDescriptor) IsUnary() bool { 733 return false 734 } 735 736 func (d *WatchAlertDescriptor) IsClientStream() bool { 737 return false 738 } 739 740 func (d *WatchAlertDescriptor) IsServerStream() bool { 741 return true 742 } 743 744 func (d *WatchAlertDescriptor) IsCollection() bool { 745 return false 746 } 747 748 func (d *WatchAlertDescriptor) IsPlural() bool { 749 return false 750 } 751 752 func (d *WatchAlertDescriptor) HasResource() bool { 753 return true 754 } 755 756 func (d *WatchAlertDescriptor) RequestHasResourceBody() bool { 757 return false 758 } 759 760 func (d *WatchAlertDescriptor) GetVerb() string { 761 return "watch" 762 } 763 764 func (d *WatchAlertDescriptor) GetMethodName() string { 765 return "WatchAlert" 766 } 767 768 func (d *WatchAlertDescriptor) GetFullMethodName() string { 769 return "/ntt.alerting.v1.AlertService/WatchAlert" 770 } 771 772 func (d *WatchAlertDescriptor) GetProtoPkgName() string { 773 return "ntt.alerting.v1" 774 } 775 776 func (d *WatchAlertDescriptor) GetApiName() string { 777 return "AlertService" 778 } 779 780 func (d *WatchAlertDescriptor) GetServiceDomain() string { 781 return "alerting.edgelq.com" 782 } 783 784 func (d *WatchAlertDescriptor) GetServiceVersion() string { 785 return "v1" 786 } 787 788 func (d *WatchAlertDescriptor) GetApiDescriptor() gotenclient.ApiDescriptor { 789 return alertServiceDescriptor 790 } 791 792 func (d *WatchAlertDescriptor) GetResourceDescriptor() gotenresource.Descriptor { 793 return alert.GetDescriptor() 794 } 795 796 func (d *WatchAlertDescriptor) GetClientMsgReflectHandle() gotenclient.MethodMsgHandle { 797 return &WatchAlertDescriptorClientMsgHandle{} 798 } 799 800 func (d *WatchAlertDescriptor) GetServerMsgReflectHandle() gotenclient.MethodMsgHandle { 801 return &WatchAlertDescriptorServerMsgHandle{} 802 } 803 804 func (h *WatchAlertDescriptorClientMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 805 typedMsg := msg.(*WatchAlertRequest) 806 var asInterface interface{} = h 807 override, ok := asInterface.(interface { 808 OverrideExtractResourceName(*WatchAlertRequest) *alert.Name 809 }) 810 if ok { 811 return override.OverrideExtractResourceName(typedMsg) 812 } 813 { 814 if name := typedMsg.GetName(); name != nil { 815 return name 816 } 817 } 818 return (*alert.Name)(nil) 819 } 820 821 func (h *WatchAlertDescriptorClientMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 822 typedMsg := msg.(*WatchAlertRequest) 823 var asInterface interface{} = h 824 override, ok := asInterface.(interface { 825 OverrideExtractResourceNames(*WatchAlertRequest) []*alert.Name 826 }) 827 if ok { 828 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 829 } 830 return nil 831 } 832 833 func (h *WatchAlertDescriptorClientMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 834 typedMsg := msg.(*WatchAlertRequest) 835 var asInterface interface{} = h 836 override, ok := asInterface.(interface { 837 OverrideExtractCollectionName(*WatchAlertRequest) *alert.ParentName 838 }) 839 if ok { 840 return override.OverrideExtractCollectionName(typedMsg) 841 } 842 return nil 843 } 844 845 func (h *WatchAlertDescriptorClientMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 846 typedMsg := msg.(*WatchAlertRequest) 847 var asInterface interface{} = h 848 override, ok := asInterface.(interface { 849 OverrideExtractResourceBody(*WatchAlertRequest) *alert.Alert 850 }) 851 if ok { 852 return override.OverrideExtractResourceBody(typedMsg) 853 } 854 return nil 855 } 856 857 func (h *WatchAlertDescriptorClientMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 858 typedMsg := msg.(*WatchAlertRequest) 859 var asInterface interface{} = h 860 override, ok := asInterface.(interface { 861 OverrideExtractResourceBodies(*WatchAlertRequest) []*alert.Alert 862 }) 863 if ok { 864 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 865 } 866 return nil 867 } 868 869 func (h *WatchAlertDescriptorServerMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 870 typedMsg := msg.(*WatchAlertResponse) 871 var asInterface interface{} = h 872 override, ok := asInterface.(interface { 873 OverrideExtractResourceName(*WatchAlertResponse) *alert.Name 874 }) 875 if ok { 876 return override.OverrideExtractResourceName(typedMsg) 877 } 878 { 879 if resChange := typedMsg.GetChange(); resChange != nil { 880 switch tResChange := resChange.ChangeType.(type) { 881 case *alert.AlertChange_Added_: 882 return tResChange.Added.GetAlert().GetName() 883 case *alert.AlertChange_Modified_: 884 return tResChange.Modified.GetName() 885 case *alert.AlertChange_Removed_: 886 return tResChange.Removed.GetName() 887 case *alert.AlertChange_Current_: 888 return tResChange.Current.GetAlert().GetName() 889 } 890 } 891 } 892 return (*alert.Name)(nil) 893 } 894 895 func (h *WatchAlertDescriptorServerMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 896 typedMsg := msg.(*WatchAlertResponse) 897 var asInterface interface{} = h 898 override, ok := asInterface.(interface { 899 OverrideExtractResourceNames(*WatchAlertResponse) []*alert.Name 900 }) 901 if ok { 902 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 903 } 904 return nil 905 } 906 907 func (h *WatchAlertDescriptorServerMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 908 typedMsg := msg.(*WatchAlertResponse) 909 var asInterface interface{} = h 910 override, ok := asInterface.(interface { 911 OverrideExtractCollectionName(*WatchAlertResponse) *alert.ParentName 912 }) 913 if ok { 914 return override.OverrideExtractCollectionName(typedMsg) 915 } 916 return nil 917 } 918 919 func (h *WatchAlertDescriptorServerMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 920 typedMsg := msg.(*WatchAlertResponse) 921 var asInterface interface{} = h 922 override, ok := asInterface.(interface { 923 OverrideExtractResourceBody(*WatchAlertResponse) *alert.Alert 924 }) 925 if ok { 926 return override.OverrideExtractResourceBody(typedMsg) 927 } 928 { 929 if resChange := typedMsg.GetChange(); resChange != nil { 930 switch tResChange := resChange.ChangeType.(type) { 931 case *alert.AlertChange_Added_: 932 return tResChange.Added.GetAlert() 933 case *alert.AlertChange_Modified_: 934 return tResChange.Modified.GetAlert() 935 case *alert.AlertChange_Current_: 936 return tResChange.Current.GetAlert() 937 } 938 } 939 } 940 return (*alert.Alert)(nil) 941 } 942 943 func (h *WatchAlertDescriptorServerMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 944 typedMsg := msg.(*WatchAlertResponse) 945 var asInterface interface{} = h 946 override, ok := asInterface.(interface { 947 OverrideExtractResourceBodies(*WatchAlertResponse) []*alert.Alert 948 }) 949 if ok { 950 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 951 } 952 return nil 953 } 954 955 func GetWatchAlertDescriptor() *WatchAlertDescriptor { 956 return watchAlertDescriptor 957 } 958 959 type WatchAlertsDescriptor struct{} 960 961 type WatchAlertsDescriptorClientMsgHandle struct{} 962 963 type WatchAlertsDescriptorServerMsgHandle struct{} 964 965 func (d *WatchAlertsDescriptor) NewEmptyClientMsg() proto.Message { 966 return &WatchAlertsRequest{} 967 } 968 969 func (d *WatchAlertsDescriptor) NewEmptyServerMsg() proto.Message { 970 return &WatchAlertsResponse{} 971 } 972 973 func (d *WatchAlertsDescriptor) IsUnary() bool { 974 return false 975 } 976 977 func (d *WatchAlertsDescriptor) IsClientStream() bool { 978 return false 979 } 980 981 func (d *WatchAlertsDescriptor) IsServerStream() bool { 982 return true 983 } 984 985 func (d *WatchAlertsDescriptor) IsCollection() bool { 986 return true 987 } 988 989 func (d *WatchAlertsDescriptor) IsPlural() bool { 990 return true 991 } 992 993 func (d *WatchAlertsDescriptor) HasResource() bool { 994 return true 995 } 996 997 func (d *WatchAlertsDescriptor) RequestHasResourceBody() bool { 998 return false 999 } 1000 1001 func (d *WatchAlertsDescriptor) GetVerb() string { 1002 return "watch" 1003 } 1004 1005 func (d *WatchAlertsDescriptor) GetMethodName() string { 1006 return "WatchAlerts" 1007 } 1008 1009 func (d *WatchAlertsDescriptor) GetFullMethodName() string { 1010 return "/ntt.alerting.v1.AlertService/WatchAlerts" 1011 } 1012 1013 func (d *WatchAlertsDescriptor) GetProtoPkgName() string { 1014 return "ntt.alerting.v1" 1015 } 1016 1017 func (d *WatchAlertsDescriptor) GetApiName() string { 1018 return "AlertService" 1019 } 1020 1021 func (d *WatchAlertsDescriptor) GetServiceDomain() string { 1022 return "alerting.edgelq.com" 1023 } 1024 1025 func (d *WatchAlertsDescriptor) GetServiceVersion() string { 1026 return "v1" 1027 } 1028 1029 func (d *WatchAlertsDescriptor) GetApiDescriptor() gotenclient.ApiDescriptor { 1030 return alertServiceDescriptor 1031 } 1032 1033 func (d *WatchAlertsDescriptor) GetResourceDescriptor() gotenresource.Descriptor { 1034 return alert.GetDescriptor() 1035 } 1036 1037 func (d *WatchAlertsDescriptor) GetClientMsgReflectHandle() gotenclient.MethodMsgHandle { 1038 return &WatchAlertsDescriptorClientMsgHandle{} 1039 } 1040 1041 func (d *WatchAlertsDescriptor) GetServerMsgReflectHandle() gotenclient.MethodMsgHandle { 1042 return &WatchAlertsDescriptorServerMsgHandle{} 1043 } 1044 1045 func (h *WatchAlertsDescriptorClientMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 1046 typedMsg := msg.(*WatchAlertsRequest) 1047 var asInterface interface{} = h 1048 override, ok := asInterface.(interface { 1049 OverrideExtractResourceName(*WatchAlertsRequest) *alert.Name 1050 }) 1051 if ok { 1052 return override.OverrideExtractResourceName(typedMsg) 1053 } 1054 return nil 1055 } 1056 1057 func (h *WatchAlertsDescriptorClientMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 1058 typedMsg := msg.(*WatchAlertsRequest) 1059 var asInterface interface{} = h 1060 override, ok := asInterface.(interface { 1061 OverrideExtractResourceNames(*WatchAlertsRequest) []*alert.Name 1062 }) 1063 if ok { 1064 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 1065 } 1066 return nil 1067 } 1068 1069 func (h *WatchAlertsDescriptorClientMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 1070 typedMsg := msg.(*WatchAlertsRequest) 1071 var asInterface interface{} = h 1072 override, ok := asInterface.(interface { 1073 OverrideExtractCollectionName(*WatchAlertsRequest) *alert.ParentName 1074 }) 1075 if ok { 1076 return override.OverrideExtractCollectionName(typedMsg) 1077 } 1078 { 1079 if parentName := typedMsg.GetParent(); parentName != nil { 1080 return parentName 1081 } 1082 } 1083 return (*alert.ParentName)(nil) 1084 } 1085 1086 func (h *WatchAlertsDescriptorClientMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 1087 typedMsg := msg.(*WatchAlertsRequest) 1088 var asInterface interface{} = h 1089 override, ok := asInterface.(interface { 1090 OverrideExtractResourceBody(*WatchAlertsRequest) *alert.Alert 1091 }) 1092 if ok { 1093 return override.OverrideExtractResourceBody(typedMsg) 1094 } 1095 return nil 1096 } 1097 1098 func (h *WatchAlertsDescriptorClientMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 1099 typedMsg := msg.(*WatchAlertsRequest) 1100 var asInterface interface{} = h 1101 override, ok := asInterface.(interface { 1102 OverrideExtractResourceBodies(*WatchAlertsRequest) []*alert.Alert 1103 }) 1104 if ok { 1105 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 1106 } 1107 return nil 1108 } 1109 1110 func (h *WatchAlertsDescriptorServerMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 1111 typedMsg := msg.(*WatchAlertsResponse) 1112 var asInterface interface{} = h 1113 override, ok := asInterface.(interface { 1114 OverrideExtractResourceName(*WatchAlertsResponse) *alert.Name 1115 }) 1116 if ok { 1117 return override.OverrideExtractResourceName(typedMsg) 1118 } 1119 return nil 1120 } 1121 1122 func (h *WatchAlertsDescriptorServerMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 1123 typedMsg := msg.(*WatchAlertsResponse) 1124 var asInterface interface{} = h 1125 override, ok := asInterface.(interface { 1126 OverrideExtractResourceNames(*WatchAlertsResponse) []*alert.Name 1127 }) 1128 if ok { 1129 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 1130 } 1131 { 1132 if resChanges := typedMsg.GetAlertChanges(); len(resChanges) > 0 { 1133 list := make(alert.AlertNameList, 0, len(resChanges)) 1134 for _, resChange := range resChanges { 1135 switch tResChange := resChange.ChangeType.(type) { 1136 case *alert.AlertChange_Added_: 1137 list = append(list, tResChange.Added.GetAlert().GetName()) 1138 case *alert.AlertChange_Modified_: 1139 list = append(list, tResChange.Modified.GetName()) 1140 case *alert.AlertChange_Removed_: 1141 list = append(list, tResChange.Removed.GetName()) 1142 case *alert.AlertChange_Current_: 1143 list = append(list, tResChange.Current.GetAlert().GetName()) 1144 } 1145 } 1146 return list 1147 } 1148 } 1149 return (alert.AlertNameList)(nil) 1150 } 1151 1152 func (h *WatchAlertsDescriptorServerMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 1153 typedMsg := msg.(*WatchAlertsResponse) 1154 var asInterface interface{} = h 1155 override, ok := asInterface.(interface { 1156 OverrideExtractCollectionName(*WatchAlertsResponse) *alert.ParentName 1157 }) 1158 if ok { 1159 return override.OverrideExtractCollectionName(typedMsg) 1160 } 1161 return nil 1162 } 1163 1164 func (h *WatchAlertsDescriptorServerMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 1165 typedMsg := msg.(*WatchAlertsResponse) 1166 var asInterface interface{} = h 1167 override, ok := asInterface.(interface { 1168 OverrideExtractResourceBody(*WatchAlertsResponse) *alert.Alert 1169 }) 1170 if ok { 1171 return override.OverrideExtractResourceBody(typedMsg) 1172 } 1173 return nil 1174 } 1175 1176 func (h *WatchAlertsDescriptorServerMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 1177 typedMsg := msg.(*WatchAlertsResponse) 1178 var asInterface interface{} = h 1179 override, ok := asInterface.(interface { 1180 OverrideExtractResourceBodies(*WatchAlertsResponse) []*alert.Alert 1181 }) 1182 if ok { 1183 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 1184 } 1185 { 1186 if resChanges := typedMsg.GetAlertChanges(); len(resChanges) > 0 { 1187 list := make(alert.AlertList, 0, len(resChanges)) 1188 for _, resChange := range resChanges { 1189 switch tResChange := resChange.ChangeType.(type) { 1190 case *alert.AlertChange_Added_: 1191 list = append(list, tResChange.Added.GetAlert()) 1192 case *alert.AlertChange_Modified_: 1193 list = append(list, tResChange.Modified.GetAlert()) 1194 case *alert.AlertChange_Current_: 1195 list = append(list, tResChange.Current.GetAlert()) 1196 } 1197 } 1198 return list 1199 } 1200 } 1201 return (alert.AlertList)(nil) 1202 } 1203 1204 func GetWatchAlertsDescriptor() *WatchAlertsDescriptor { 1205 return watchAlertsDescriptor 1206 } 1207 1208 type CreateAlertDescriptor struct{} 1209 1210 type CreateAlertDescriptorClientMsgHandle struct{} 1211 1212 type CreateAlertDescriptorServerMsgHandle struct{} 1213 1214 func (d *CreateAlertDescriptor) NewEmptyClientMsg() proto.Message { 1215 return &CreateAlertRequest{} 1216 } 1217 1218 func (d *CreateAlertDescriptor) NewEmptyServerMsg() proto.Message { 1219 return &alert.Alert{} 1220 } 1221 1222 func (d *CreateAlertDescriptor) IsUnary() bool { 1223 return true 1224 } 1225 1226 func (d *CreateAlertDescriptor) IsClientStream() bool { 1227 return false 1228 } 1229 1230 func (d *CreateAlertDescriptor) IsServerStream() bool { 1231 return false 1232 } 1233 1234 func (d *CreateAlertDescriptor) IsCollection() bool { 1235 return true 1236 } 1237 1238 func (d *CreateAlertDescriptor) IsPlural() bool { 1239 return false 1240 } 1241 1242 func (d *CreateAlertDescriptor) HasResource() bool { 1243 return true 1244 } 1245 1246 func (d *CreateAlertDescriptor) RequestHasResourceBody() bool { 1247 return true 1248 } 1249 1250 func (d *CreateAlertDescriptor) GetVerb() string { 1251 return "create" 1252 } 1253 1254 func (d *CreateAlertDescriptor) GetMethodName() string { 1255 return "CreateAlert" 1256 } 1257 1258 func (d *CreateAlertDescriptor) GetFullMethodName() string { 1259 return "/ntt.alerting.v1.AlertService/CreateAlert" 1260 } 1261 1262 func (d *CreateAlertDescriptor) GetProtoPkgName() string { 1263 return "ntt.alerting.v1" 1264 } 1265 1266 func (d *CreateAlertDescriptor) GetApiName() string { 1267 return "AlertService" 1268 } 1269 1270 func (d *CreateAlertDescriptor) GetServiceDomain() string { 1271 return "alerting.edgelq.com" 1272 } 1273 1274 func (d *CreateAlertDescriptor) GetServiceVersion() string { 1275 return "v1" 1276 } 1277 1278 func (d *CreateAlertDescriptor) GetApiDescriptor() gotenclient.ApiDescriptor { 1279 return alertServiceDescriptor 1280 } 1281 1282 func (d *CreateAlertDescriptor) GetResourceDescriptor() gotenresource.Descriptor { 1283 return alert.GetDescriptor() 1284 } 1285 1286 func (d *CreateAlertDescriptor) GetClientMsgReflectHandle() gotenclient.MethodMsgHandle { 1287 return &CreateAlertDescriptorClientMsgHandle{} 1288 } 1289 1290 func (d *CreateAlertDescriptor) GetServerMsgReflectHandle() gotenclient.MethodMsgHandle { 1291 return &CreateAlertDescriptorServerMsgHandle{} 1292 } 1293 1294 func (h *CreateAlertDescriptorClientMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 1295 typedMsg := msg.(*CreateAlertRequest) 1296 var asInterface interface{} = h 1297 override, ok := asInterface.(interface { 1298 OverrideExtractResourceName(*CreateAlertRequest) *alert.Name 1299 }) 1300 if ok { 1301 return override.OverrideExtractResourceName(typedMsg) 1302 } 1303 { 1304 res := typedMsg.GetAlert() 1305 if name := res.GetName(); name != nil { 1306 return name 1307 } 1308 } 1309 return (*alert.Name)(nil) 1310 } 1311 1312 func (h *CreateAlertDescriptorClientMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 1313 typedMsg := msg.(*CreateAlertRequest) 1314 var asInterface interface{} = h 1315 override, ok := asInterface.(interface { 1316 OverrideExtractResourceNames(*CreateAlertRequest) []*alert.Name 1317 }) 1318 if ok { 1319 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 1320 } 1321 return nil 1322 } 1323 1324 func (h *CreateAlertDescriptorClientMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 1325 typedMsg := msg.(*CreateAlertRequest) 1326 var asInterface interface{} = h 1327 override, ok := asInterface.(interface { 1328 OverrideExtractCollectionName(*CreateAlertRequest) *alert.ParentName 1329 }) 1330 if ok { 1331 return override.OverrideExtractCollectionName(typedMsg) 1332 } 1333 { 1334 if parentName := typedMsg.GetParent(); parentName != nil { 1335 return parentName 1336 } 1337 } 1338 return (*alert.ParentName)(nil) 1339 } 1340 1341 func (h *CreateAlertDescriptorClientMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 1342 typedMsg := msg.(*CreateAlertRequest) 1343 var asInterface interface{} = h 1344 override, ok := asInterface.(interface { 1345 OverrideExtractResourceBody(*CreateAlertRequest) *alert.Alert 1346 }) 1347 if ok { 1348 return override.OverrideExtractResourceBody(typedMsg) 1349 } 1350 { 1351 return typedMsg.GetAlert() 1352 } 1353 return (*alert.Alert)(nil) 1354 } 1355 1356 func (h *CreateAlertDescriptorClientMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 1357 typedMsg := msg.(*CreateAlertRequest) 1358 var asInterface interface{} = h 1359 override, ok := asInterface.(interface { 1360 OverrideExtractResourceBodies(*CreateAlertRequest) []*alert.Alert 1361 }) 1362 if ok { 1363 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 1364 } 1365 return nil 1366 } 1367 1368 func (h *CreateAlertDescriptorServerMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 1369 typedMsg := msg.(*alert.Alert) 1370 var asInterface interface{} = h 1371 override, ok := asInterface.(interface { 1372 OverrideExtractResourceName(*alert.Alert) *alert.Name 1373 }) 1374 if ok { 1375 return override.OverrideExtractResourceName(typedMsg) 1376 } 1377 { 1378 if name := typedMsg.GetName(); name != nil { 1379 return name 1380 } 1381 } 1382 return (*alert.Name)(nil) 1383 } 1384 1385 func (h *CreateAlertDescriptorServerMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 1386 typedMsg := msg.(*alert.Alert) 1387 var asInterface interface{} = h 1388 override, ok := asInterface.(interface { 1389 OverrideExtractResourceNames(*alert.Alert) []*alert.Name 1390 }) 1391 if ok { 1392 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 1393 } 1394 return nil 1395 } 1396 1397 func (h *CreateAlertDescriptorServerMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 1398 typedMsg := msg.(*alert.Alert) 1399 var asInterface interface{} = h 1400 override, ok := asInterface.(interface { 1401 OverrideExtractCollectionName(*alert.Alert) *alert.ParentName 1402 }) 1403 if ok { 1404 return override.OverrideExtractCollectionName(typedMsg) 1405 } 1406 return nil 1407 } 1408 1409 func (h *CreateAlertDescriptorServerMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 1410 return msg.(*alert.Alert) 1411 } 1412 1413 func (h *CreateAlertDescriptorServerMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 1414 typedMsg := msg.(*alert.Alert) 1415 var asInterface interface{} = h 1416 override, ok := asInterface.(interface { 1417 OverrideExtractResourceBodies(*alert.Alert) []*alert.Alert 1418 }) 1419 if ok { 1420 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 1421 } 1422 return nil 1423 } 1424 1425 func GetCreateAlertDescriptor() *CreateAlertDescriptor { 1426 return createAlertDescriptor 1427 } 1428 1429 type UpdateAlertDescriptor struct{} 1430 1431 type UpdateAlertDescriptorClientMsgHandle struct{} 1432 1433 type UpdateAlertDescriptorServerMsgHandle struct{} 1434 1435 func (d *UpdateAlertDescriptor) NewEmptyClientMsg() proto.Message { 1436 return &UpdateAlertRequest{} 1437 } 1438 1439 func (d *UpdateAlertDescriptor) NewEmptyServerMsg() proto.Message { 1440 return &alert.Alert{} 1441 } 1442 1443 func (d *UpdateAlertDescriptor) IsUnary() bool { 1444 return true 1445 } 1446 1447 func (d *UpdateAlertDescriptor) IsClientStream() bool { 1448 return false 1449 } 1450 1451 func (d *UpdateAlertDescriptor) IsServerStream() bool { 1452 return false 1453 } 1454 1455 func (d *UpdateAlertDescriptor) IsCollection() bool { 1456 return false 1457 } 1458 1459 func (d *UpdateAlertDescriptor) IsPlural() bool { 1460 return false 1461 } 1462 1463 func (d *UpdateAlertDescriptor) HasResource() bool { 1464 return true 1465 } 1466 1467 func (d *UpdateAlertDescriptor) RequestHasResourceBody() bool { 1468 return true 1469 } 1470 1471 func (d *UpdateAlertDescriptor) GetVerb() string { 1472 return "update" 1473 } 1474 1475 func (d *UpdateAlertDescriptor) GetMethodName() string { 1476 return "UpdateAlert" 1477 } 1478 1479 func (d *UpdateAlertDescriptor) GetFullMethodName() string { 1480 return "/ntt.alerting.v1.AlertService/UpdateAlert" 1481 } 1482 1483 func (d *UpdateAlertDescriptor) GetProtoPkgName() string { 1484 return "ntt.alerting.v1" 1485 } 1486 1487 func (d *UpdateAlertDescriptor) GetApiName() string { 1488 return "AlertService" 1489 } 1490 1491 func (d *UpdateAlertDescriptor) GetServiceDomain() string { 1492 return "alerting.edgelq.com" 1493 } 1494 1495 func (d *UpdateAlertDescriptor) GetServiceVersion() string { 1496 return "v1" 1497 } 1498 1499 func (d *UpdateAlertDescriptor) GetApiDescriptor() gotenclient.ApiDescriptor { 1500 return alertServiceDescriptor 1501 } 1502 1503 func (d *UpdateAlertDescriptor) GetResourceDescriptor() gotenresource.Descriptor { 1504 return alert.GetDescriptor() 1505 } 1506 1507 func (d *UpdateAlertDescriptor) GetClientMsgReflectHandle() gotenclient.MethodMsgHandle { 1508 return &UpdateAlertDescriptorClientMsgHandle{} 1509 } 1510 1511 func (d *UpdateAlertDescriptor) GetServerMsgReflectHandle() gotenclient.MethodMsgHandle { 1512 return &UpdateAlertDescriptorServerMsgHandle{} 1513 } 1514 1515 func (h *UpdateAlertDescriptorClientMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 1516 typedMsg := msg.(*UpdateAlertRequest) 1517 var asInterface interface{} = h 1518 override, ok := asInterface.(interface { 1519 OverrideExtractResourceName(*UpdateAlertRequest) *alert.Name 1520 }) 1521 if ok { 1522 return override.OverrideExtractResourceName(typedMsg) 1523 } 1524 { 1525 res := typedMsg.GetAlert() 1526 if name := res.GetName(); name != nil { 1527 return name 1528 } 1529 } 1530 return (*alert.Name)(nil) 1531 } 1532 1533 func (h *UpdateAlertDescriptorClientMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 1534 typedMsg := msg.(*UpdateAlertRequest) 1535 var asInterface interface{} = h 1536 override, ok := asInterface.(interface { 1537 OverrideExtractResourceNames(*UpdateAlertRequest) []*alert.Name 1538 }) 1539 if ok { 1540 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 1541 } 1542 return nil 1543 } 1544 1545 func (h *UpdateAlertDescriptorClientMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 1546 typedMsg := msg.(*UpdateAlertRequest) 1547 var asInterface interface{} = h 1548 override, ok := asInterface.(interface { 1549 OverrideExtractCollectionName(*UpdateAlertRequest) *alert.ParentName 1550 }) 1551 if ok { 1552 return override.OverrideExtractCollectionName(typedMsg) 1553 } 1554 return nil 1555 } 1556 1557 func (h *UpdateAlertDescriptorClientMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 1558 typedMsg := msg.(*UpdateAlertRequest) 1559 var asInterface interface{} = h 1560 override, ok := asInterface.(interface { 1561 OverrideExtractResourceBody(*UpdateAlertRequest) *alert.Alert 1562 }) 1563 if ok { 1564 return override.OverrideExtractResourceBody(typedMsg) 1565 } 1566 { 1567 return typedMsg.GetAlert() 1568 } 1569 return (*alert.Alert)(nil) 1570 } 1571 1572 func (h *UpdateAlertDescriptorClientMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 1573 typedMsg := msg.(*UpdateAlertRequest) 1574 var asInterface interface{} = h 1575 override, ok := asInterface.(interface { 1576 OverrideExtractResourceBodies(*UpdateAlertRequest) []*alert.Alert 1577 }) 1578 if ok { 1579 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 1580 } 1581 return nil 1582 } 1583 1584 func (h *UpdateAlertDescriptorServerMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 1585 typedMsg := msg.(*alert.Alert) 1586 var asInterface interface{} = h 1587 override, ok := asInterface.(interface { 1588 OverrideExtractResourceName(*alert.Alert) *alert.Name 1589 }) 1590 if ok { 1591 return override.OverrideExtractResourceName(typedMsg) 1592 } 1593 { 1594 if name := typedMsg.GetName(); name != nil { 1595 return name 1596 } 1597 } 1598 return (*alert.Name)(nil) 1599 } 1600 1601 func (h *UpdateAlertDescriptorServerMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 1602 typedMsg := msg.(*alert.Alert) 1603 var asInterface interface{} = h 1604 override, ok := asInterface.(interface { 1605 OverrideExtractResourceNames(*alert.Alert) []*alert.Name 1606 }) 1607 if ok { 1608 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 1609 } 1610 return nil 1611 } 1612 1613 func (h *UpdateAlertDescriptorServerMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 1614 typedMsg := msg.(*alert.Alert) 1615 var asInterface interface{} = h 1616 override, ok := asInterface.(interface { 1617 OverrideExtractCollectionName(*alert.Alert) *alert.ParentName 1618 }) 1619 if ok { 1620 return override.OverrideExtractCollectionName(typedMsg) 1621 } 1622 return nil 1623 } 1624 1625 func (h *UpdateAlertDescriptorServerMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 1626 return msg.(*alert.Alert) 1627 } 1628 1629 func (h *UpdateAlertDescriptorServerMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 1630 typedMsg := msg.(*alert.Alert) 1631 var asInterface interface{} = h 1632 override, ok := asInterface.(interface { 1633 OverrideExtractResourceBodies(*alert.Alert) []*alert.Alert 1634 }) 1635 if ok { 1636 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 1637 } 1638 return nil 1639 } 1640 1641 func GetUpdateAlertDescriptor() *UpdateAlertDescriptor { 1642 return updateAlertDescriptor 1643 } 1644 1645 type DeleteAlertDescriptor struct{} 1646 1647 type DeleteAlertDescriptorClientMsgHandle struct{} 1648 1649 type DeleteAlertDescriptorServerMsgHandle struct{} 1650 1651 func (d *DeleteAlertDescriptor) NewEmptyClientMsg() proto.Message { 1652 return &DeleteAlertRequest{} 1653 } 1654 1655 func (d *DeleteAlertDescriptor) NewEmptyServerMsg() proto.Message { 1656 return &emptypb.Empty{} 1657 } 1658 1659 func (d *DeleteAlertDescriptor) IsUnary() bool { 1660 return true 1661 } 1662 1663 func (d *DeleteAlertDescriptor) IsClientStream() bool { 1664 return false 1665 } 1666 1667 func (d *DeleteAlertDescriptor) IsServerStream() bool { 1668 return false 1669 } 1670 1671 func (d *DeleteAlertDescriptor) IsCollection() bool { 1672 return false 1673 } 1674 1675 func (d *DeleteAlertDescriptor) IsPlural() bool { 1676 return false 1677 } 1678 1679 func (d *DeleteAlertDescriptor) HasResource() bool { 1680 return true 1681 } 1682 1683 func (d *DeleteAlertDescriptor) RequestHasResourceBody() bool { 1684 return false 1685 } 1686 1687 func (d *DeleteAlertDescriptor) GetVerb() string { 1688 return "delete" 1689 } 1690 1691 func (d *DeleteAlertDescriptor) GetMethodName() string { 1692 return "DeleteAlert" 1693 } 1694 1695 func (d *DeleteAlertDescriptor) GetFullMethodName() string { 1696 return "/ntt.alerting.v1.AlertService/DeleteAlert" 1697 } 1698 1699 func (d *DeleteAlertDescriptor) GetProtoPkgName() string { 1700 return "ntt.alerting.v1" 1701 } 1702 1703 func (d *DeleteAlertDescriptor) GetApiName() string { 1704 return "AlertService" 1705 } 1706 1707 func (d *DeleteAlertDescriptor) GetServiceDomain() string { 1708 return "alerting.edgelq.com" 1709 } 1710 1711 func (d *DeleteAlertDescriptor) GetServiceVersion() string { 1712 return "v1" 1713 } 1714 1715 func (d *DeleteAlertDescriptor) GetApiDescriptor() gotenclient.ApiDescriptor { 1716 return alertServiceDescriptor 1717 } 1718 1719 func (d *DeleteAlertDescriptor) GetResourceDescriptor() gotenresource.Descriptor { 1720 return alert.GetDescriptor() 1721 } 1722 1723 func (d *DeleteAlertDescriptor) GetClientMsgReflectHandle() gotenclient.MethodMsgHandle { 1724 return &DeleteAlertDescriptorClientMsgHandle{} 1725 } 1726 1727 func (d *DeleteAlertDescriptor) GetServerMsgReflectHandle() gotenclient.MethodMsgHandle { 1728 return &DeleteAlertDescriptorServerMsgHandle{} 1729 } 1730 1731 func (h *DeleteAlertDescriptorClientMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 1732 typedMsg := msg.(*DeleteAlertRequest) 1733 var asInterface interface{} = h 1734 override, ok := asInterface.(interface { 1735 OverrideExtractResourceName(*DeleteAlertRequest) *alert.Name 1736 }) 1737 if ok { 1738 return override.OverrideExtractResourceName(typedMsg) 1739 } 1740 { 1741 if name := typedMsg.GetName(); name != nil { 1742 return name 1743 } 1744 } 1745 return (*alert.Name)(nil) 1746 } 1747 1748 func (h *DeleteAlertDescriptorClientMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 1749 typedMsg := msg.(*DeleteAlertRequest) 1750 var asInterface interface{} = h 1751 override, ok := asInterface.(interface { 1752 OverrideExtractResourceNames(*DeleteAlertRequest) []*alert.Name 1753 }) 1754 if ok { 1755 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 1756 } 1757 return nil 1758 } 1759 1760 func (h *DeleteAlertDescriptorClientMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 1761 typedMsg := msg.(*DeleteAlertRequest) 1762 var asInterface interface{} = h 1763 override, ok := asInterface.(interface { 1764 OverrideExtractCollectionName(*DeleteAlertRequest) *alert.ParentName 1765 }) 1766 if ok { 1767 return override.OverrideExtractCollectionName(typedMsg) 1768 } 1769 return nil 1770 } 1771 1772 func (h *DeleteAlertDescriptorClientMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 1773 typedMsg := msg.(*DeleteAlertRequest) 1774 var asInterface interface{} = h 1775 override, ok := asInterface.(interface { 1776 OverrideExtractResourceBody(*DeleteAlertRequest) *alert.Alert 1777 }) 1778 if ok { 1779 return override.OverrideExtractResourceBody(typedMsg) 1780 } 1781 return nil 1782 } 1783 1784 func (h *DeleteAlertDescriptorClientMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 1785 typedMsg := msg.(*DeleteAlertRequest) 1786 var asInterface interface{} = h 1787 override, ok := asInterface.(interface { 1788 OverrideExtractResourceBodies(*DeleteAlertRequest) []*alert.Alert 1789 }) 1790 if ok { 1791 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 1792 } 1793 return nil 1794 } 1795 1796 func (h *DeleteAlertDescriptorServerMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 1797 typedMsg := msg.(*emptypb.Empty) 1798 var asInterface interface{} = h 1799 override, ok := asInterface.(interface { 1800 OverrideExtractResourceName(*emptypb.Empty) *alert.Name 1801 }) 1802 if ok { 1803 return override.OverrideExtractResourceName(typedMsg) 1804 } 1805 return nil 1806 } 1807 1808 func (h *DeleteAlertDescriptorServerMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 1809 typedMsg := msg.(*emptypb.Empty) 1810 var asInterface interface{} = h 1811 override, ok := asInterface.(interface { 1812 OverrideExtractResourceNames(*emptypb.Empty) []*alert.Name 1813 }) 1814 if ok { 1815 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 1816 } 1817 return nil 1818 } 1819 1820 func (h *DeleteAlertDescriptorServerMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 1821 typedMsg := msg.(*emptypb.Empty) 1822 var asInterface interface{} = h 1823 override, ok := asInterface.(interface { 1824 OverrideExtractCollectionName(*emptypb.Empty) *alert.ParentName 1825 }) 1826 if ok { 1827 return override.OverrideExtractCollectionName(typedMsg) 1828 } 1829 return nil 1830 } 1831 1832 func (h *DeleteAlertDescriptorServerMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 1833 typedMsg := msg.(*emptypb.Empty) 1834 var asInterface interface{} = h 1835 override, ok := asInterface.(interface { 1836 OverrideExtractResourceBody(*emptypb.Empty) *alert.Alert 1837 }) 1838 if ok { 1839 return override.OverrideExtractResourceBody(typedMsg) 1840 } 1841 return nil 1842 } 1843 1844 func (h *DeleteAlertDescriptorServerMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 1845 typedMsg := msg.(*emptypb.Empty) 1846 var asInterface interface{} = h 1847 override, ok := asInterface.(interface { 1848 OverrideExtractResourceBodies(*emptypb.Empty) []*alert.Alert 1849 }) 1850 if ok { 1851 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 1852 } 1853 return nil 1854 } 1855 1856 func GetDeleteAlertDescriptor() *DeleteAlertDescriptor { 1857 return deleteAlertDescriptor 1858 } 1859 1860 type BulkSaveAlertsDescriptor struct{} 1861 1862 type BulkSaveAlertsDescriptorClientMsgHandle struct{} 1863 1864 type BulkSaveAlertsDescriptorServerMsgHandle struct{} 1865 1866 func (d *BulkSaveAlertsDescriptor) NewEmptyClientMsg() proto.Message { 1867 return &BulkSaveAlertsRequest{} 1868 } 1869 1870 func (d *BulkSaveAlertsDescriptor) NewEmptyServerMsg() proto.Message { 1871 return &BulkSaveAlertsResponse{} 1872 } 1873 1874 func (d *BulkSaveAlertsDescriptor) IsUnary() bool { 1875 return true 1876 } 1877 1878 func (d *BulkSaveAlertsDescriptor) IsClientStream() bool { 1879 return false 1880 } 1881 1882 func (d *BulkSaveAlertsDescriptor) IsServerStream() bool { 1883 return false 1884 } 1885 1886 func (d *BulkSaveAlertsDescriptor) IsCollection() bool { 1887 return true 1888 } 1889 1890 func (d *BulkSaveAlertsDescriptor) IsPlural() bool { 1891 return false 1892 } 1893 1894 func (d *BulkSaveAlertsDescriptor) HasResource() bool { 1895 return true 1896 } 1897 1898 func (d *BulkSaveAlertsDescriptor) RequestHasResourceBody() bool { 1899 return false 1900 } 1901 1902 func (d *BulkSaveAlertsDescriptor) GetVerb() string { 1903 return "bulkSaveAlerts" 1904 } 1905 1906 func (d *BulkSaveAlertsDescriptor) GetMethodName() string { 1907 return "BulkSaveAlerts" 1908 } 1909 1910 func (d *BulkSaveAlertsDescriptor) GetFullMethodName() string { 1911 return "/ntt.alerting.v1.AlertService/BulkSaveAlerts" 1912 } 1913 1914 func (d *BulkSaveAlertsDescriptor) GetProtoPkgName() string { 1915 return "ntt.alerting.v1" 1916 } 1917 1918 func (d *BulkSaveAlertsDescriptor) GetApiName() string { 1919 return "AlertService" 1920 } 1921 1922 func (d *BulkSaveAlertsDescriptor) GetServiceDomain() string { 1923 return "alerting.edgelq.com" 1924 } 1925 1926 func (d *BulkSaveAlertsDescriptor) GetServiceVersion() string { 1927 return "v1" 1928 } 1929 1930 func (d *BulkSaveAlertsDescriptor) GetApiDescriptor() gotenclient.ApiDescriptor { 1931 return alertServiceDescriptor 1932 } 1933 1934 func (d *BulkSaveAlertsDescriptor) GetResourceDescriptor() gotenresource.Descriptor { 1935 return alert.GetDescriptor() 1936 } 1937 1938 func (d *BulkSaveAlertsDescriptor) GetClientMsgReflectHandle() gotenclient.MethodMsgHandle { 1939 return &BulkSaveAlertsDescriptorClientMsgHandle{} 1940 } 1941 1942 func (d *BulkSaveAlertsDescriptor) GetServerMsgReflectHandle() gotenclient.MethodMsgHandle { 1943 return &BulkSaveAlertsDescriptorServerMsgHandle{} 1944 } 1945 1946 func (h *BulkSaveAlertsDescriptorClientMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 1947 typedMsg := msg.(*BulkSaveAlertsRequest) 1948 var asInterface interface{} = h 1949 override, ok := asInterface.(interface { 1950 OverrideExtractResourceName(*BulkSaveAlertsRequest) *alert.Name 1951 }) 1952 if ok { 1953 return override.OverrideExtractResourceName(typedMsg) 1954 } 1955 return nil 1956 } 1957 1958 func (h *BulkSaveAlertsDescriptorClientMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 1959 typedMsg := msg.(*BulkSaveAlertsRequest) 1960 var asInterface interface{} = h 1961 override, ok := asInterface.(interface { 1962 OverrideExtractResourceNames(*BulkSaveAlertsRequest) []*alert.Name 1963 }) 1964 if ok { 1965 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 1966 } 1967 return nil 1968 } 1969 1970 func (h *BulkSaveAlertsDescriptorClientMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 1971 typedMsg := msg.(*BulkSaveAlertsRequest) 1972 var asInterface interface{} = h 1973 override, ok := asInterface.(interface { 1974 OverrideExtractCollectionName(*BulkSaveAlertsRequest) *alert.ParentName 1975 }) 1976 if ok { 1977 return override.OverrideExtractCollectionName(typedMsg) 1978 } 1979 return nil 1980 } 1981 1982 func (h *BulkSaveAlertsDescriptorClientMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 1983 typedMsg := msg.(*BulkSaveAlertsRequest) 1984 var asInterface interface{} = h 1985 override, ok := asInterface.(interface { 1986 OverrideExtractResourceBody(*BulkSaveAlertsRequest) *alert.Alert 1987 }) 1988 if ok { 1989 return override.OverrideExtractResourceBody(typedMsg) 1990 } 1991 return nil 1992 } 1993 1994 func (h *BulkSaveAlertsDescriptorClientMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 1995 typedMsg := msg.(*BulkSaveAlertsRequest) 1996 var asInterface interface{} = h 1997 override, ok := asInterface.(interface { 1998 OverrideExtractResourceBodies(*BulkSaveAlertsRequest) []*alert.Alert 1999 }) 2000 if ok { 2001 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 2002 } 2003 return nil 2004 } 2005 2006 func (h *BulkSaveAlertsDescriptorServerMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 2007 typedMsg := msg.(*BulkSaveAlertsResponse) 2008 var asInterface interface{} = h 2009 override, ok := asInterface.(interface { 2010 OverrideExtractResourceName(*BulkSaveAlertsResponse) *alert.Name 2011 }) 2012 if ok { 2013 return override.OverrideExtractResourceName(typedMsg) 2014 } 2015 return nil 2016 } 2017 2018 func (h *BulkSaveAlertsDescriptorServerMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 2019 typedMsg := msg.(*BulkSaveAlertsResponse) 2020 var asInterface interface{} = h 2021 override, ok := asInterface.(interface { 2022 OverrideExtractResourceNames(*BulkSaveAlertsResponse) []*alert.Name 2023 }) 2024 if ok { 2025 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 2026 } 2027 return nil 2028 } 2029 2030 func (h *BulkSaveAlertsDescriptorServerMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 2031 typedMsg := msg.(*BulkSaveAlertsResponse) 2032 var asInterface interface{} = h 2033 override, ok := asInterface.(interface { 2034 OverrideExtractCollectionName(*BulkSaveAlertsResponse) *alert.ParentName 2035 }) 2036 if ok { 2037 return override.OverrideExtractCollectionName(typedMsg) 2038 } 2039 return nil 2040 } 2041 2042 func (h *BulkSaveAlertsDescriptorServerMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 2043 typedMsg := msg.(*BulkSaveAlertsResponse) 2044 var asInterface interface{} = h 2045 override, ok := asInterface.(interface { 2046 OverrideExtractResourceBody(*BulkSaveAlertsResponse) *alert.Alert 2047 }) 2048 if ok { 2049 return override.OverrideExtractResourceBody(typedMsg) 2050 } 2051 return nil 2052 } 2053 2054 func (h *BulkSaveAlertsDescriptorServerMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 2055 typedMsg := msg.(*BulkSaveAlertsResponse) 2056 var asInterface interface{} = h 2057 override, ok := asInterface.(interface { 2058 OverrideExtractResourceBodies(*BulkSaveAlertsResponse) []*alert.Alert 2059 }) 2060 if ok { 2061 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 2062 } 2063 return nil 2064 } 2065 2066 func GetBulkSaveAlertsDescriptor() *BulkSaveAlertsDescriptor { 2067 return bulkSaveAlertsDescriptor 2068 } 2069 2070 type BulkMarkAsNotifiedDescriptor struct{} 2071 2072 type BulkMarkAsNotifiedDescriptorClientMsgHandle struct{} 2073 2074 type BulkMarkAsNotifiedDescriptorServerMsgHandle struct{} 2075 2076 func (d *BulkMarkAsNotifiedDescriptor) NewEmptyClientMsg() proto.Message { 2077 return &BulkMarkAsNotifiedRequest{} 2078 } 2079 2080 func (d *BulkMarkAsNotifiedDescriptor) NewEmptyServerMsg() proto.Message { 2081 return &BulkMarkAsNotifiedResponse{} 2082 } 2083 2084 func (d *BulkMarkAsNotifiedDescriptor) IsUnary() bool { 2085 return true 2086 } 2087 2088 func (d *BulkMarkAsNotifiedDescriptor) IsClientStream() bool { 2089 return false 2090 } 2091 2092 func (d *BulkMarkAsNotifiedDescriptor) IsServerStream() bool { 2093 return false 2094 } 2095 2096 func (d *BulkMarkAsNotifiedDescriptor) IsCollection() bool { 2097 return true 2098 } 2099 2100 func (d *BulkMarkAsNotifiedDescriptor) IsPlural() bool { 2101 return false 2102 } 2103 2104 func (d *BulkMarkAsNotifiedDescriptor) HasResource() bool { 2105 return true 2106 } 2107 2108 func (d *BulkMarkAsNotifiedDescriptor) RequestHasResourceBody() bool { 2109 return false 2110 } 2111 2112 func (d *BulkMarkAsNotifiedDescriptor) GetVerb() string { 2113 return "bulkMarkAsNotified" 2114 } 2115 2116 func (d *BulkMarkAsNotifiedDescriptor) GetMethodName() string { 2117 return "BulkMarkAsNotified" 2118 } 2119 2120 func (d *BulkMarkAsNotifiedDescriptor) GetFullMethodName() string { 2121 return "/ntt.alerting.v1.AlertService/BulkMarkAsNotified" 2122 } 2123 2124 func (d *BulkMarkAsNotifiedDescriptor) GetProtoPkgName() string { 2125 return "ntt.alerting.v1" 2126 } 2127 2128 func (d *BulkMarkAsNotifiedDescriptor) GetApiName() string { 2129 return "AlertService" 2130 } 2131 2132 func (d *BulkMarkAsNotifiedDescriptor) GetServiceDomain() string { 2133 return "alerting.edgelq.com" 2134 } 2135 2136 func (d *BulkMarkAsNotifiedDescriptor) GetServiceVersion() string { 2137 return "v1" 2138 } 2139 2140 func (d *BulkMarkAsNotifiedDescriptor) GetApiDescriptor() gotenclient.ApiDescriptor { 2141 return alertServiceDescriptor 2142 } 2143 2144 func (d *BulkMarkAsNotifiedDescriptor) GetResourceDescriptor() gotenresource.Descriptor { 2145 return alert.GetDescriptor() 2146 } 2147 2148 func (d *BulkMarkAsNotifiedDescriptor) GetClientMsgReflectHandle() gotenclient.MethodMsgHandle { 2149 return &BulkMarkAsNotifiedDescriptorClientMsgHandle{} 2150 } 2151 2152 func (d *BulkMarkAsNotifiedDescriptor) GetServerMsgReflectHandle() gotenclient.MethodMsgHandle { 2153 return &BulkMarkAsNotifiedDescriptorServerMsgHandle{} 2154 } 2155 2156 func (h *BulkMarkAsNotifiedDescriptorClientMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 2157 typedMsg := msg.(*BulkMarkAsNotifiedRequest) 2158 var asInterface interface{} = h 2159 override, ok := asInterface.(interface { 2160 OverrideExtractResourceName(*BulkMarkAsNotifiedRequest) *alert.Name 2161 }) 2162 if ok { 2163 return override.OverrideExtractResourceName(typedMsg) 2164 } 2165 return nil 2166 } 2167 2168 func (h *BulkMarkAsNotifiedDescriptorClientMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 2169 typedMsg := msg.(*BulkMarkAsNotifiedRequest) 2170 var asInterface interface{} = h 2171 override, ok := asInterface.(interface { 2172 OverrideExtractResourceNames(*BulkMarkAsNotifiedRequest) []*alert.Name 2173 }) 2174 if ok { 2175 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 2176 } 2177 return nil 2178 } 2179 2180 func (h *BulkMarkAsNotifiedDescriptorClientMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 2181 typedMsg := msg.(*BulkMarkAsNotifiedRequest) 2182 var asInterface interface{} = h 2183 override, ok := asInterface.(interface { 2184 OverrideExtractCollectionName(*BulkMarkAsNotifiedRequest) *alert.ParentName 2185 }) 2186 if ok { 2187 return override.OverrideExtractCollectionName(typedMsg) 2188 } 2189 return nil 2190 } 2191 2192 func (h *BulkMarkAsNotifiedDescriptorClientMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 2193 typedMsg := msg.(*BulkMarkAsNotifiedRequest) 2194 var asInterface interface{} = h 2195 override, ok := asInterface.(interface { 2196 OverrideExtractResourceBody(*BulkMarkAsNotifiedRequest) *alert.Alert 2197 }) 2198 if ok { 2199 return override.OverrideExtractResourceBody(typedMsg) 2200 } 2201 return nil 2202 } 2203 2204 func (h *BulkMarkAsNotifiedDescriptorClientMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 2205 typedMsg := msg.(*BulkMarkAsNotifiedRequest) 2206 var asInterface interface{} = h 2207 override, ok := asInterface.(interface { 2208 OverrideExtractResourceBodies(*BulkMarkAsNotifiedRequest) []*alert.Alert 2209 }) 2210 if ok { 2211 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 2212 } 2213 return nil 2214 } 2215 2216 func (h *BulkMarkAsNotifiedDescriptorServerMsgHandle) ExtractResourceName(msg proto.Message) gotenresource.Name { 2217 typedMsg := msg.(*BulkMarkAsNotifiedResponse) 2218 var asInterface interface{} = h 2219 override, ok := asInterface.(interface { 2220 OverrideExtractResourceName(*BulkMarkAsNotifiedResponse) *alert.Name 2221 }) 2222 if ok { 2223 return override.OverrideExtractResourceName(typedMsg) 2224 } 2225 return nil 2226 } 2227 2228 func (h *BulkMarkAsNotifiedDescriptorServerMsgHandle) ExtractResourceNames(msg proto.Message) gotenresource.NameList { 2229 typedMsg := msg.(*BulkMarkAsNotifiedResponse) 2230 var asInterface interface{} = h 2231 override, ok := asInterface.(interface { 2232 OverrideExtractResourceNames(*BulkMarkAsNotifiedResponse) []*alert.Name 2233 }) 2234 if ok { 2235 return alert.AlertNameList(override.OverrideExtractResourceNames(typedMsg)) 2236 } 2237 return nil 2238 } 2239 2240 func (h *BulkMarkAsNotifiedDescriptorServerMsgHandle) ExtractCollectionName(msg proto.Message) gotenresource.Name { 2241 typedMsg := msg.(*BulkMarkAsNotifiedResponse) 2242 var asInterface interface{} = h 2243 override, ok := asInterface.(interface { 2244 OverrideExtractCollectionName(*BulkMarkAsNotifiedResponse) *alert.ParentName 2245 }) 2246 if ok { 2247 return override.OverrideExtractCollectionName(typedMsg) 2248 } 2249 return nil 2250 } 2251 2252 func (h *BulkMarkAsNotifiedDescriptorServerMsgHandle) ExtractResourceBody(msg proto.Message) gotenresource.Resource { 2253 typedMsg := msg.(*BulkMarkAsNotifiedResponse) 2254 var asInterface interface{} = h 2255 override, ok := asInterface.(interface { 2256 OverrideExtractResourceBody(*BulkMarkAsNotifiedResponse) *alert.Alert 2257 }) 2258 if ok { 2259 return override.OverrideExtractResourceBody(typedMsg) 2260 } 2261 return nil 2262 } 2263 2264 func (h *BulkMarkAsNotifiedDescriptorServerMsgHandle) ExtractResourceBodies(msg proto.Message) gotenresource.ResourceList { 2265 typedMsg := msg.(*BulkMarkAsNotifiedResponse) 2266 var asInterface interface{} = h 2267 override, ok := asInterface.(interface { 2268 OverrideExtractResourceBodies(*BulkMarkAsNotifiedResponse) []*alert.Alert 2269 }) 2270 if ok { 2271 return alert.AlertList(override.OverrideExtractResourceBodies(typedMsg)) 2272 } 2273 return nil 2274 } 2275 2276 func GetBulkMarkAsNotifiedDescriptor() *BulkMarkAsNotifiedDescriptor { 2277 return bulkMarkAsNotifiedDescriptor 2278 } 2279 2280 type AlertServiceDescriptor struct{} 2281 2282 func (d *AlertServiceDescriptor) AllMethodDescriptors() []gotenclient.MethodDescriptor { 2283 return []gotenclient.MethodDescriptor{ 2284 getAlertDescriptor, 2285 batchGetAlertsDescriptor, 2286 listAlertsDescriptor, 2287 watchAlertDescriptor, 2288 watchAlertsDescriptor, 2289 createAlertDescriptor, 2290 updateAlertDescriptor, 2291 deleteAlertDescriptor, 2292 bulkSaveAlertsDescriptor, 2293 bulkMarkAsNotifiedDescriptor, 2294 } 2295 } 2296 2297 func (d *AlertServiceDescriptor) GetFullAPIName() string { 2298 return "/ntt.alerting.v1.AlertService" 2299 } 2300 2301 func (d *AlertServiceDescriptor) GetProtoPkgName() string { 2302 return "ntt.alerting.v1" 2303 } 2304 2305 func (d *AlertServiceDescriptor) GetApiName() string { 2306 return "AlertService" 2307 } 2308 2309 func (d *AlertServiceDescriptor) GetServiceDomain() string { 2310 return "alerting.edgelq.com" 2311 } 2312 2313 func (d *AlertServiceDescriptor) GetServiceVersion() string { 2314 return "v1" 2315 } 2316 2317 func GetAlertServiceDescriptor() *AlertServiceDescriptor { 2318 return alertServiceDescriptor 2319 } 2320 2321 func initDescriptors() { 2322 alertServiceDescriptor = &AlertServiceDescriptor{} 2323 getAlertDescriptor = &GetAlertDescriptor{} 2324 batchGetAlertsDescriptor = &BatchGetAlertsDescriptor{} 2325 listAlertsDescriptor = &ListAlertsDescriptor{} 2326 watchAlertDescriptor = &WatchAlertDescriptor{} 2327 watchAlertsDescriptor = &WatchAlertsDescriptor{} 2328 createAlertDescriptor = &CreateAlertDescriptor{} 2329 updateAlertDescriptor = &UpdateAlertDescriptor{} 2330 deleteAlertDescriptor = &DeleteAlertDescriptor{} 2331 bulkSaveAlertsDescriptor = &BulkSaveAlertsDescriptor{} 2332 bulkMarkAsNotifiedDescriptor = &BulkMarkAsNotifiedDescriptor{} 2333 gotenclient.GetRegistry().RegisterApiDescriptor(alertServiceDescriptor) 2334 gotenclient.GetRegistry().RegisterMethodDescriptor(getAlertDescriptor) 2335 gotenclient.GetRegistry().RegisterMethodDescriptor(batchGetAlertsDescriptor) 2336 gotenclient.GetRegistry().RegisterMethodDescriptor(listAlertsDescriptor) 2337 gotenclient.GetRegistry().RegisterMethodDescriptor(watchAlertDescriptor) 2338 gotenclient.GetRegistry().RegisterMethodDescriptor(watchAlertsDescriptor) 2339 gotenclient.GetRegistry().RegisterMethodDescriptor(createAlertDescriptor) 2340 gotenclient.GetRegistry().RegisterMethodDescriptor(updateAlertDescriptor) 2341 gotenclient.GetRegistry().RegisterMethodDescriptor(deleteAlertDescriptor) 2342 gotenclient.GetRegistry().RegisterMethodDescriptor(bulkSaveAlertsDescriptor) 2343 gotenclient.GetRegistry().RegisterMethodDescriptor(bulkMarkAsNotifiedDescriptor) 2344 } 2345 2346 func init() { 2347 if !descriptorsInitialized { 2348 initDescriptors() 2349 descriptorsInitialized = true 2350 } 2351 }