google-cloud-backupdr-v1 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (28) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/cloud/backupdr/v1/backupdr/client.rb +2829 -157
  3. data/lib/google/cloud/backupdr/v1/backupdr/operations.rb +3 -10
  4. data/lib/google/cloud/backupdr/v1/backupdr/paths.rb +101 -0
  5. data/lib/google/cloud/backupdr/v1/backupdr/rest/client.rb +2656 -151
  6. data/lib/google/cloud/backupdr/v1/backupdr/rest/operations.rb +3 -10
  7. data/lib/google/cloud/backupdr/v1/backupdr/rest/service_stub.rb +1382 -17
  8. data/lib/google/cloud/backupdr/v1/backupdr_pb.rb +5 -1
  9. data/lib/google/cloud/backupdr/v1/backupdr_services_pb.rb +48 -0
  10. data/lib/google/cloud/backupdr/v1/backupplan_pb.rb +62 -0
  11. data/lib/google/cloud/backupdr/v1/backupplanassociation_pb.rb +59 -0
  12. data/lib/google/cloud/backupdr/v1/backupvault_ba_pb.rb +46 -0
  13. data/lib/google/cloud/backupdr/v1/backupvault_gce_pb.rb +87 -0
  14. data/lib/google/cloud/backupdr/v1/backupvault_pb.rb +99 -0
  15. data/lib/google/cloud/backupdr/v1/version.rb +1 -1
  16. data/proto_docs/google/api/client.rb +51 -10
  17. data/proto_docs/google/api/field_info.rb +88 -0
  18. data/proto_docs/google/api/resource.rb +7 -2
  19. data/proto_docs/google/cloud/backupdr/v1/backupdr.rb +11 -10
  20. data/proto_docs/google/cloud/backupdr/v1/backupplan.rb +414 -0
  21. data/proto_docs/google/cloud/backupdr/v1/backupplanassociation.rb +272 -0
  22. data/proto_docs/google/cloud/backupdr/v1/backupvault.rb +1103 -0
  23. data/proto_docs/google/cloud/backupdr/v1/backupvault_ba.rb +47 -0
  24. data/proto_docs/google/cloud/backupdr/v1/backupvault_gce.rb +993 -0
  25. data/proto_docs/google/longrunning/operations.rb +19 -14
  26. data/proto_docs/google/type/dayofweek.rb +49 -0
  27. data/proto_docs/google/type/month.rb +64 -0
  28. metadata +16 -3
@@ -213,20 +213,1279 @@ module Google
213
213
  result
214
214
  end
215
215
 
216
+ ##
217
+ # Baseline implementation for the create_backup_vault REST call
218
+ #
219
+ # @param request_pb [::Google::Cloud::BackupDR::V1::CreateBackupVaultRequest]
220
+ # A request object representing the call parameters. Required.
221
+ # @param options [::Gapic::CallOptions]
222
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
223
+ #
224
+ # @yield [result, operation] Access the result along with the TransportOperation object
225
+ # @yieldparam result [::Google::Longrunning::Operation]
226
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
227
+ #
228
+ # @return [::Google::Longrunning::Operation]
229
+ # A result object deserialized from the server's reply
230
+ def create_backup_vault request_pb, options = nil
231
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
232
+
233
+ verb, uri, query_string_params, body = ServiceStub.transcode_create_backup_vault_request request_pb
234
+ query_string_params = if query_string_params.any?
235
+ query_string_params.to_h { |p| p.split "=", 2 }
236
+ else
237
+ {}
238
+ end
239
+
240
+ response = @client_stub.make_http_request(
241
+ verb,
242
+ uri: uri,
243
+ body: body || "",
244
+ params: query_string_params,
245
+ options: options
246
+ )
247
+ operation = ::Gapic::Rest::TransportOperation.new response
248
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
249
+
250
+ yield result, operation if block_given?
251
+ result
252
+ end
253
+
254
+ ##
255
+ # Baseline implementation for the list_backup_vaults REST call
256
+ #
257
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListBackupVaultsRequest]
258
+ # A request object representing the call parameters. Required.
259
+ # @param options [::Gapic::CallOptions]
260
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
261
+ #
262
+ # @yield [result, operation] Access the result along with the TransportOperation object
263
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::ListBackupVaultsResponse]
264
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
265
+ #
266
+ # @return [::Google::Cloud::BackupDR::V1::ListBackupVaultsResponse]
267
+ # A result object deserialized from the server's reply
268
+ def list_backup_vaults request_pb, options = nil
269
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
270
+
271
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_backup_vaults_request request_pb
272
+ query_string_params = if query_string_params.any?
273
+ query_string_params.to_h { |p| p.split "=", 2 }
274
+ else
275
+ {}
276
+ end
277
+
278
+ response = @client_stub.make_http_request(
279
+ verb,
280
+ uri: uri,
281
+ body: body || "",
282
+ params: query_string_params,
283
+ options: options
284
+ )
285
+ operation = ::Gapic::Rest::TransportOperation.new response
286
+ result = ::Google::Cloud::BackupDR::V1::ListBackupVaultsResponse.decode_json response.body, ignore_unknown_fields: true
287
+
288
+ yield result, operation if block_given?
289
+ result
290
+ end
291
+
292
+ ##
293
+ # Baseline implementation for the fetch_usable_backup_vaults REST call
294
+ #
295
+ # @param request_pb [::Google::Cloud::BackupDR::V1::FetchUsableBackupVaultsRequest]
296
+ # A request object representing the call parameters. Required.
297
+ # @param options [::Gapic::CallOptions]
298
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
299
+ #
300
+ # @yield [result, operation] Access the result along with the TransportOperation object
301
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::FetchUsableBackupVaultsResponse]
302
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
303
+ #
304
+ # @return [::Google::Cloud::BackupDR::V1::FetchUsableBackupVaultsResponse]
305
+ # A result object deserialized from the server's reply
306
+ def fetch_usable_backup_vaults request_pb, options = nil
307
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
308
+
309
+ verb, uri, query_string_params, body = ServiceStub.transcode_fetch_usable_backup_vaults_request request_pb
310
+ query_string_params = if query_string_params.any?
311
+ query_string_params.to_h { |p| p.split "=", 2 }
312
+ else
313
+ {}
314
+ end
315
+
316
+ response = @client_stub.make_http_request(
317
+ verb,
318
+ uri: uri,
319
+ body: body || "",
320
+ params: query_string_params,
321
+ options: options
322
+ )
323
+ operation = ::Gapic::Rest::TransportOperation.new response
324
+ result = ::Google::Cloud::BackupDR::V1::FetchUsableBackupVaultsResponse.decode_json response.body, ignore_unknown_fields: true
325
+
326
+ yield result, operation if block_given?
327
+ result
328
+ end
329
+
330
+ ##
331
+ # Baseline implementation for the get_backup_vault REST call
332
+ #
333
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetBackupVaultRequest]
334
+ # A request object representing the call parameters. Required.
335
+ # @param options [::Gapic::CallOptions]
336
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
337
+ #
338
+ # @yield [result, operation] Access the result along with the TransportOperation object
339
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::BackupVault]
340
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
341
+ #
342
+ # @return [::Google::Cloud::BackupDR::V1::BackupVault]
343
+ # A result object deserialized from the server's reply
344
+ def get_backup_vault request_pb, options = nil
345
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
346
+
347
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_backup_vault_request request_pb
348
+ query_string_params = if query_string_params.any?
349
+ query_string_params.to_h { |p| p.split "=", 2 }
350
+ else
351
+ {}
352
+ end
353
+
354
+ response = @client_stub.make_http_request(
355
+ verb,
356
+ uri: uri,
357
+ body: body || "",
358
+ params: query_string_params,
359
+ options: options
360
+ )
361
+ operation = ::Gapic::Rest::TransportOperation.new response
362
+ result = ::Google::Cloud::BackupDR::V1::BackupVault.decode_json response.body, ignore_unknown_fields: true
363
+
364
+ yield result, operation if block_given?
365
+ result
366
+ end
367
+
368
+ ##
369
+ # Baseline implementation for the update_backup_vault REST call
370
+ #
371
+ # @param request_pb [::Google::Cloud::BackupDR::V1::UpdateBackupVaultRequest]
372
+ # A request object representing the call parameters. Required.
373
+ # @param options [::Gapic::CallOptions]
374
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
375
+ #
376
+ # @yield [result, operation] Access the result along with the TransportOperation object
377
+ # @yieldparam result [::Google::Longrunning::Operation]
378
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
379
+ #
380
+ # @return [::Google::Longrunning::Operation]
381
+ # A result object deserialized from the server's reply
382
+ def update_backup_vault request_pb, options = nil
383
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
384
+
385
+ verb, uri, query_string_params, body = ServiceStub.transcode_update_backup_vault_request request_pb
386
+ query_string_params = if query_string_params.any?
387
+ query_string_params.to_h { |p| p.split "=", 2 }
388
+ else
389
+ {}
390
+ end
391
+
392
+ response = @client_stub.make_http_request(
393
+ verb,
394
+ uri: uri,
395
+ body: body || "",
396
+ params: query_string_params,
397
+ options: options
398
+ )
399
+ operation = ::Gapic::Rest::TransportOperation.new response
400
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
401
+
402
+ yield result, operation if block_given?
403
+ result
404
+ end
405
+
406
+ ##
407
+ # Baseline implementation for the delete_backup_vault REST call
408
+ #
409
+ # @param request_pb [::Google::Cloud::BackupDR::V1::DeleteBackupVaultRequest]
410
+ # A request object representing the call parameters. Required.
411
+ # @param options [::Gapic::CallOptions]
412
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
413
+ #
414
+ # @yield [result, operation] Access the result along with the TransportOperation object
415
+ # @yieldparam result [::Google::Longrunning::Operation]
416
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
417
+ #
418
+ # @return [::Google::Longrunning::Operation]
419
+ # A result object deserialized from the server's reply
420
+ def delete_backup_vault request_pb, options = nil
421
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
422
+
423
+ verb, uri, query_string_params, body = ServiceStub.transcode_delete_backup_vault_request request_pb
424
+ query_string_params = if query_string_params.any?
425
+ query_string_params.to_h { |p| p.split "=", 2 }
426
+ else
427
+ {}
428
+ end
429
+
430
+ response = @client_stub.make_http_request(
431
+ verb,
432
+ uri: uri,
433
+ body: body || "",
434
+ params: query_string_params,
435
+ options: options
436
+ )
437
+ operation = ::Gapic::Rest::TransportOperation.new response
438
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
439
+
440
+ yield result, operation if block_given?
441
+ result
442
+ end
443
+
444
+ ##
445
+ # Baseline implementation for the list_data_sources REST call
446
+ #
447
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListDataSourcesRequest]
448
+ # A request object representing the call parameters. Required.
449
+ # @param options [::Gapic::CallOptions]
450
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
451
+ #
452
+ # @yield [result, operation] Access the result along with the TransportOperation object
453
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::ListDataSourcesResponse]
454
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
455
+ #
456
+ # @return [::Google::Cloud::BackupDR::V1::ListDataSourcesResponse]
457
+ # A result object deserialized from the server's reply
458
+ def list_data_sources request_pb, options = nil
459
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
460
+
461
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_data_sources_request request_pb
462
+ query_string_params = if query_string_params.any?
463
+ query_string_params.to_h { |p| p.split "=", 2 }
464
+ else
465
+ {}
466
+ end
467
+
468
+ response = @client_stub.make_http_request(
469
+ verb,
470
+ uri: uri,
471
+ body: body || "",
472
+ params: query_string_params,
473
+ options: options
474
+ )
475
+ operation = ::Gapic::Rest::TransportOperation.new response
476
+ result = ::Google::Cloud::BackupDR::V1::ListDataSourcesResponse.decode_json response.body, ignore_unknown_fields: true
477
+
478
+ yield result, operation if block_given?
479
+ result
480
+ end
481
+
482
+ ##
483
+ # Baseline implementation for the get_data_source REST call
484
+ #
485
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetDataSourceRequest]
486
+ # A request object representing the call parameters. Required.
487
+ # @param options [::Gapic::CallOptions]
488
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
489
+ #
490
+ # @yield [result, operation] Access the result along with the TransportOperation object
491
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::DataSource]
492
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
493
+ #
494
+ # @return [::Google::Cloud::BackupDR::V1::DataSource]
495
+ # A result object deserialized from the server's reply
496
+ def get_data_source request_pb, options = nil
497
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
498
+
499
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_data_source_request request_pb
500
+ query_string_params = if query_string_params.any?
501
+ query_string_params.to_h { |p| p.split "=", 2 }
502
+ else
503
+ {}
504
+ end
505
+
506
+ response = @client_stub.make_http_request(
507
+ verb,
508
+ uri: uri,
509
+ body: body || "",
510
+ params: query_string_params,
511
+ options: options
512
+ )
513
+ operation = ::Gapic::Rest::TransportOperation.new response
514
+ result = ::Google::Cloud::BackupDR::V1::DataSource.decode_json response.body, ignore_unknown_fields: true
515
+
516
+ yield result, operation if block_given?
517
+ result
518
+ end
519
+
520
+ ##
521
+ # Baseline implementation for the update_data_source REST call
522
+ #
523
+ # @param request_pb [::Google::Cloud::BackupDR::V1::UpdateDataSourceRequest]
524
+ # A request object representing the call parameters. Required.
525
+ # @param options [::Gapic::CallOptions]
526
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
527
+ #
528
+ # @yield [result, operation] Access the result along with the TransportOperation object
529
+ # @yieldparam result [::Google::Longrunning::Operation]
530
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
531
+ #
532
+ # @return [::Google::Longrunning::Operation]
533
+ # A result object deserialized from the server's reply
534
+ def update_data_source request_pb, options = nil
535
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
536
+
537
+ verb, uri, query_string_params, body = ServiceStub.transcode_update_data_source_request request_pb
538
+ query_string_params = if query_string_params.any?
539
+ query_string_params.to_h { |p| p.split "=", 2 }
540
+ else
541
+ {}
542
+ end
543
+
544
+ response = @client_stub.make_http_request(
545
+ verb,
546
+ uri: uri,
547
+ body: body || "",
548
+ params: query_string_params,
549
+ options: options
550
+ )
551
+ operation = ::Gapic::Rest::TransportOperation.new response
552
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
553
+
554
+ yield result, operation if block_given?
555
+ result
556
+ end
557
+
558
+ ##
559
+ # Baseline implementation for the list_backups REST call
560
+ #
561
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListBackupsRequest]
562
+ # A request object representing the call parameters. Required.
563
+ # @param options [::Gapic::CallOptions]
564
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
565
+ #
566
+ # @yield [result, operation] Access the result along with the TransportOperation object
567
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::ListBackupsResponse]
568
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
569
+ #
570
+ # @return [::Google::Cloud::BackupDR::V1::ListBackupsResponse]
571
+ # A result object deserialized from the server's reply
572
+ def list_backups request_pb, options = nil
573
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
574
+
575
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_backups_request request_pb
576
+ query_string_params = if query_string_params.any?
577
+ query_string_params.to_h { |p| p.split "=", 2 }
578
+ else
579
+ {}
580
+ end
581
+
582
+ response = @client_stub.make_http_request(
583
+ verb,
584
+ uri: uri,
585
+ body: body || "",
586
+ params: query_string_params,
587
+ options: options
588
+ )
589
+ operation = ::Gapic::Rest::TransportOperation.new response
590
+ result = ::Google::Cloud::BackupDR::V1::ListBackupsResponse.decode_json response.body, ignore_unknown_fields: true
591
+
592
+ yield result, operation if block_given?
593
+ result
594
+ end
595
+
596
+ ##
597
+ # Baseline implementation for the get_backup REST call
598
+ #
599
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetBackupRequest]
600
+ # A request object representing the call parameters. Required.
601
+ # @param options [::Gapic::CallOptions]
602
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
603
+ #
604
+ # @yield [result, operation] Access the result along with the TransportOperation object
605
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::Backup]
606
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
607
+ #
608
+ # @return [::Google::Cloud::BackupDR::V1::Backup]
609
+ # A result object deserialized from the server's reply
610
+ def get_backup request_pb, options = nil
611
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
612
+
613
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_backup_request request_pb
614
+ query_string_params = if query_string_params.any?
615
+ query_string_params.to_h { |p| p.split "=", 2 }
616
+ else
617
+ {}
618
+ end
619
+
620
+ response = @client_stub.make_http_request(
621
+ verb,
622
+ uri: uri,
623
+ body: body || "",
624
+ params: query_string_params,
625
+ options: options
626
+ )
627
+ operation = ::Gapic::Rest::TransportOperation.new response
628
+ result = ::Google::Cloud::BackupDR::V1::Backup.decode_json response.body, ignore_unknown_fields: true
629
+
630
+ yield result, operation if block_given?
631
+ result
632
+ end
633
+
634
+ ##
635
+ # Baseline implementation for the update_backup REST call
636
+ #
637
+ # @param request_pb [::Google::Cloud::BackupDR::V1::UpdateBackupRequest]
638
+ # A request object representing the call parameters. Required.
639
+ # @param options [::Gapic::CallOptions]
640
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
641
+ #
642
+ # @yield [result, operation] Access the result along with the TransportOperation object
643
+ # @yieldparam result [::Google::Longrunning::Operation]
644
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
645
+ #
646
+ # @return [::Google::Longrunning::Operation]
647
+ # A result object deserialized from the server's reply
648
+ def update_backup request_pb, options = nil
649
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
650
+
651
+ verb, uri, query_string_params, body = ServiceStub.transcode_update_backup_request request_pb
652
+ query_string_params = if query_string_params.any?
653
+ query_string_params.to_h { |p| p.split "=", 2 }
654
+ else
655
+ {}
656
+ end
657
+
658
+ response = @client_stub.make_http_request(
659
+ verb,
660
+ uri: uri,
661
+ body: body || "",
662
+ params: query_string_params,
663
+ options: options
664
+ )
665
+ operation = ::Gapic::Rest::TransportOperation.new response
666
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
667
+
668
+ yield result, operation if block_given?
669
+ result
670
+ end
671
+
672
+ ##
673
+ # Baseline implementation for the delete_backup REST call
674
+ #
675
+ # @param request_pb [::Google::Cloud::BackupDR::V1::DeleteBackupRequest]
676
+ # A request object representing the call parameters. Required.
677
+ # @param options [::Gapic::CallOptions]
678
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
679
+ #
680
+ # @yield [result, operation] Access the result along with the TransportOperation object
681
+ # @yieldparam result [::Google::Longrunning::Operation]
682
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
683
+ #
684
+ # @return [::Google::Longrunning::Operation]
685
+ # A result object deserialized from the server's reply
686
+ def delete_backup request_pb, options = nil
687
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
688
+
689
+ verb, uri, query_string_params, body = ServiceStub.transcode_delete_backup_request request_pb
690
+ query_string_params = if query_string_params.any?
691
+ query_string_params.to_h { |p| p.split "=", 2 }
692
+ else
693
+ {}
694
+ end
695
+
696
+ response = @client_stub.make_http_request(
697
+ verb,
698
+ uri: uri,
699
+ body: body || "",
700
+ params: query_string_params,
701
+ options: options
702
+ )
703
+ operation = ::Gapic::Rest::TransportOperation.new response
704
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
705
+
706
+ yield result, operation if block_given?
707
+ result
708
+ end
709
+
710
+ ##
711
+ # Baseline implementation for the restore_backup REST call
712
+ #
713
+ # @param request_pb [::Google::Cloud::BackupDR::V1::RestoreBackupRequest]
714
+ # A request object representing the call parameters. Required.
715
+ # @param options [::Gapic::CallOptions]
716
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
717
+ #
718
+ # @yield [result, operation] Access the result along with the TransportOperation object
719
+ # @yieldparam result [::Google::Longrunning::Operation]
720
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
721
+ #
722
+ # @return [::Google::Longrunning::Operation]
723
+ # A result object deserialized from the server's reply
724
+ def restore_backup request_pb, options = nil
725
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
726
+
727
+ verb, uri, query_string_params, body = ServiceStub.transcode_restore_backup_request request_pb
728
+ query_string_params = if query_string_params.any?
729
+ query_string_params.to_h { |p| p.split "=", 2 }
730
+ else
731
+ {}
732
+ end
733
+
734
+ response = @client_stub.make_http_request(
735
+ verb,
736
+ uri: uri,
737
+ body: body || "",
738
+ params: query_string_params,
739
+ options: options
740
+ )
741
+ operation = ::Gapic::Rest::TransportOperation.new response
742
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
743
+
744
+ yield result, operation if block_given?
745
+ result
746
+ end
747
+
748
+ ##
749
+ # Baseline implementation for the create_backup_plan REST call
750
+ #
751
+ # @param request_pb [::Google::Cloud::BackupDR::V1::CreateBackupPlanRequest]
752
+ # A request object representing the call parameters. Required.
753
+ # @param options [::Gapic::CallOptions]
754
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
755
+ #
756
+ # @yield [result, operation] Access the result along with the TransportOperation object
757
+ # @yieldparam result [::Google::Longrunning::Operation]
758
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
759
+ #
760
+ # @return [::Google::Longrunning::Operation]
761
+ # A result object deserialized from the server's reply
762
+ def create_backup_plan request_pb, options = nil
763
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
764
+
765
+ verb, uri, query_string_params, body = ServiceStub.transcode_create_backup_plan_request request_pb
766
+ query_string_params = if query_string_params.any?
767
+ query_string_params.to_h { |p| p.split "=", 2 }
768
+ else
769
+ {}
770
+ end
771
+
772
+ response = @client_stub.make_http_request(
773
+ verb,
774
+ uri: uri,
775
+ body: body || "",
776
+ params: query_string_params,
777
+ options: options
778
+ )
779
+ operation = ::Gapic::Rest::TransportOperation.new response
780
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
781
+
782
+ yield result, operation if block_given?
783
+ result
784
+ end
785
+
786
+ ##
787
+ # Baseline implementation for the get_backup_plan REST call
788
+ #
789
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetBackupPlanRequest]
790
+ # A request object representing the call parameters. Required.
791
+ # @param options [::Gapic::CallOptions]
792
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
793
+ #
794
+ # @yield [result, operation] Access the result along with the TransportOperation object
795
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::BackupPlan]
796
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
797
+ #
798
+ # @return [::Google::Cloud::BackupDR::V1::BackupPlan]
799
+ # A result object deserialized from the server's reply
800
+ def get_backup_plan request_pb, options = nil
801
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
802
+
803
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_backup_plan_request request_pb
804
+ query_string_params = if query_string_params.any?
805
+ query_string_params.to_h { |p| p.split "=", 2 }
806
+ else
807
+ {}
808
+ end
809
+
810
+ response = @client_stub.make_http_request(
811
+ verb,
812
+ uri: uri,
813
+ body: body || "",
814
+ params: query_string_params,
815
+ options: options
816
+ )
817
+ operation = ::Gapic::Rest::TransportOperation.new response
818
+ result = ::Google::Cloud::BackupDR::V1::BackupPlan.decode_json response.body, ignore_unknown_fields: true
819
+
820
+ yield result, operation if block_given?
821
+ result
822
+ end
823
+
824
+ ##
825
+ # Baseline implementation for the list_backup_plans REST call
826
+ #
827
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListBackupPlansRequest]
828
+ # A request object representing the call parameters. Required.
829
+ # @param options [::Gapic::CallOptions]
830
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
831
+ #
832
+ # @yield [result, operation] Access the result along with the TransportOperation object
833
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::ListBackupPlansResponse]
834
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
835
+ #
836
+ # @return [::Google::Cloud::BackupDR::V1::ListBackupPlansResponse]
837
+ # A result object deserialized from the server's reply
838
+ def list_backup_plans request_pb, options = nil
839
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
840
+
841
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_backup_plans_request request_pb
842
+ query_string_params = if query_string_params.any?
843
+ query_string_params.to_h { |p| p.split "=", 2 }
844
+ else
845
+ {}
846
+ end
847
+
848
+ response = @client_stub.make_http_request(
849
+ verb,
850
+ uri: uri,
851
+ body: body || "",
852
+ params: query_string_params,
853
+ options: options
854
+ )
855
+ operation = ::Gapic::Rest::TransportOperation.new response
856
+ result = ::Google::Cloud::BackupDR::V1::ListBackupPlansResponse.decode_json response.body, ignore_unknown_fields: true
857
+
858
+ yield result, operation if block_given?
859
+ result
860
+ end
861
+
862
+ ##
863
+ # Baseline implementation for the delete_backup_plan REST call
864
+ #
865
+ # @param request_pb [::Google::Cloud::BackupDR::V1::DeleteBackupPlanRequest]
866
+ # A request object representing the call parameters. Required.
867
+ # @param options [::Gapic::CallOptions]
868
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
869
+ #
870
+ # @yield [result, operation] Access the result along with the TransportOperation object
871
+ # @yieldparam result [::Google::Longrunning::Operation]
872
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
873
+ #
874
+ # @return [::Google::Longrunning::Operation]
875
+ # A result object deserialized from the server's reply
876
+ def delete_backup_plan request_pb, options = nil
877
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
878
+
879
+ verb, uri, query_string_params, body = ServiceStub.transcode_delete_backup_plan_request request_pb
880
+ query_string_params = if query_string_params.any?
881
+ query_string_params.to_h { |p| p.split "=", 2 }
882
+ else
883
+ {}
884
+ end
885
+
886
+ response = @client_stub.make_http_request(
887
+ verb,
888
+ uri: uri,
889
+ body: body || "",
890
+ params: query_string_params,
891
+ options: options
892
+ )
893
+ operation = ::Gapic::Rest::TransportOperation.new response
894
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
895
+
896
+ yield result, operation if block_given?
897
+ result
898
+ end
899
+
900
+ ##
901
+ # Baseline implementation for the create_backup_plan_association REST call
902
+ #
903
+ # @param request_pb [::Google::Cloud::BackupDR::V1::CreateBackupPlanAssociationRequest]
904
+ # A request object representing the call parameters. Required.
905
+ # @param options [::Gapic::CallOptions]
906
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
907
+ #
908
+ # @yield [result, operation] Access the result along with the TransportOperation object
909
+ # @yieldparam result [::Google::Longrunning::Operation]
910
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
911
+ #
912
+ # @return [::Google::Longrunning::Operation]
913
+ # A result object deserialized from the server's reply
914
+ def create_backup_plan_association request_pb, options = nil
915
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
916
+
917
+ verb, uri, query_string_params, body = ServiceStub.transcode_create_backup_plan_association_request request_pb
918
+ query_string_params = if query_string_params.any?
919
+ query_string_params.to_h { |p| p.split "=", 2 }
920
+ else
921
+ {}
922
+ end
923
+
924
+ response = @client_stub.make_http_request(
925
+ verb,
926
+ uri: uri,
927
+ body: body || "",
928
+ params: query_string_params,
929
+ options: options
930
+ )
931
+ operation = ::Gapic::Rest::TransportOperation.new response
932
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
933
+
934
+ yield result, operation if block_given?
935
+ result
936
+ end
937
+
938
+ ##
939
+ # Baseline implementation for the get_backup_plan_association REST call
940
+ #
941
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetBackupPlanAssociationRequest]
942
+ # A request object representing the call parameters. Required.
943
+ # @param options [::Gapic::CallOptions]
944
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
945
+ #
946
+ # @yield [result, operation] Access the result along with the TransportOperation object
947
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::BackupPlanAssociation]
948
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
949
+ #
950
+ # @return [::Google::Cloud::BackupDR::V1::BackupPlanAssociation]
951
+ # A result object deserialized from the server's reply
952
+ def get_backup_plan_association request_pb, options = nil
953
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
954
+
955
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_backup_plan_association_request request_pb
956
+ query_string_params = if query_string_params.any?
957
+ query_string_params.to_h { |p| p.split "=", 2 }
958
+ else
959
+ {}
960
+ end
961
+
962
+ response = @client_stub.make_http_request(
963
+ verb,
964
+ uri: uri,
965
+ body: body || "",
966
+ params: query_string_params,
967
+ options: options
968
+ )
969
+ operation = ::Gapic::Rest::TransportOperation.new response
970
+ result = ::Google::Cloud::BackupDR::V1::BackupPlanAssociation.decode_json response.body, ignore_unknown_fields: true
971
+
972
+ yield result, operation if block_given?
973
+ result
974
+ end
975
+
976
+ ##
977
+ # Baseline implementation for the list_backup_plan_associations REST call
978
+ #
979
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListBackupPlanAssociationsRequest]
980
+ # A request object representing the call parameters. Required.
981
+ # @param options [::Gapic::CallOptions]
982
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
983
+ #
984
+ # @yield [result, operation] Access the result along with the TransportOperation object
985
+ # @yieldparam result [::Google::Cloud::BackupDR::V1::ListBackupPlanAssociationsResponse]
986
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
987
+ #
988
+ # @return [::Google::Cloud::BackupDR::V1::ListBackupPlanAssociationsResponse]
989
+ # A result object deserialized from the server's reply
990
+ def list_backup_plan_associations request_pb, options = nil
991
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
992
+
993
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_backup_plan_associations_request request_pb
994
+ query_string_params = if query_string_params.any?
995
+ query_string_params.to_h { |p| p.split "=", 2 }
996
+ else
997
+ {}
998
+ end
999
+
1000
+ response = @client_stub.make_http_request(
1001
+ verb,
1002
+ uri: uri,
1003
+ body: body || "",
1004
+ params: query_string_params,
1005
+ options: options
1006
+ )
1007
+ operation = ::Gapic::Rest::TransportOperation.new response
1008
+ result = ::Google::Cloud::BackupDR::V1::ListBackupPlanAssociationsResponse.decode_json response.body, ignore_unknown_fields: true
1009
+
1010
+ yield result, operation if block_given?
1011
+ result
1012
+ end
1013
+
1014
+ ##
1015
+ # Baseline implementation for the delete_backup_plan_association REST call
1016
+ #
1017
+ # @param request_pb [::Google::Cloud::BackupDR::V1::DeleteBackupPlanAssociationRequest]
1018
+ # A request object representing the call parameters. Required.
1019
+ # @param options [::Gapic::CallOptions]
1020
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1021
+ #
1022
+ # @yield [result, operation] Access the result along with the TransportOperation object
1023
+ # @yieldparam result [::Google::Longrunning::Operation]
1024
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1025
+ #
1026
+ # @return [::Google::Longrunning::Operation]
1027
+ # A result object deserialized from the server's reply
1028
+ def delete_backup_plan_association request_pb, options = nil
1029
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
1030
+
1031
+ verb, uri, query_string_params, body = ServiceStub.transcode_delete_backup_plan_association_request request_pb
1032
+ query_string_params = if query_string_params.any?
1033
+ query_string_params.to_h { |p| p.split "=", 2 }
1034
+ else
1035
+ {}
1036
+ end
1037
+
1038
+ response = @client_stub.make_http_request(
1039
+ verb,
1040
+ uri: uri,
1041
+ body: body || "",
1042
+ params: query_string_params,
1043
+ options: options
1044
+ )
1045
+ operation = ::Gapic::Rest::TransportOperation.new response
1046
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
1047
+
1048
+ yield result, operation if block_given?
1049
+ result
1050
+ end
1051
+
1052
+ ##
1053
+ # Baseline implementation for the trigger_backup REST call
1054
+ #
1055
+ # @param request_pb [::Google::Cloud::BackupDR::V1::TriggerBackupRequest]
1056
+ # A request object representing the call parameters. Required.
1057
+ # @param options [::Gapic::CallOptions]
1058
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1059
+ #
1060
+ # @yield [result, operation] Access the result along with the TransportOperation object
1061
+ # @yieldparam result [::Google::Longrunning::Operation]
1062
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1063
+ #
1064
+ # @return [::Google::Longrunning::Operation]
1065
+ # A result object deserialized from the server's reply
1066
+ def trigger_backup request_pb, options = nil
1067
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
1068
+
1069
+ verb, uri, query_string_params, body = ServiceStub.transcode_trigger_backup_request request_pb
1070
+ query_string_params = if query_string_params.any?
1071
+ query_string_params.to_h { |p| p.split "=", 2 }
1072
+ else
1073
+ {}
1074
+ end
1075
+
1076
+ response = @client_stub.make_http_request(
1077
+ verb,
1078
+ uri: uri,
1079
+ body: body || "",
1080
+ params: query_string_params,
1081
+ options: options
1082
+ )
1083
+ operation = ::Gapic::Rest::TransportOperation.new response
1084
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
1085
+
1086
+ yield result, operation if block_given?
1087
+ result
1088
+ end
1089
+
1090
+ ##
1091
+ # @private
1092
+ #
1093
+ # GRPC transcoding helper method for the list_management_servers REST call
1094
+ #
1095
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListManagementServersRequest]
1096
+ # A request object representing the call parameters. Required.
1097
+ # @return [Array(String, [String, nil], Hash{String => String})]
1098
+ # Uri, Body, Query string parameters
1099
+ def self.transcode_list_management_servers_request request_pb
1100
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1101
+ .with_bindings(
1102
+ uri_method: :get,
1103
+ uri_template: "/v1/{parent}/managementServers",
1104
+ matches: [
1105
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
1106
+ ]
1107
+ )
1108
+ transcoder.transcode request_pb
1109
+ end
1110
+
1111
+ ##
1112
+ # @private
1113
+ #
1114
+ # GRPC transcoding helper method for the get_management_server REST call
1115
+ #
1116
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetManagementServerRequest]
1117
+ # A request object representing the call parameters. Required.
1118
+ # @return [Array(String, [String, nil], Hash{String => String})]
1119
+ # Uri, Body, Query string parameters
1120
+ def self.transcode_get_management_server_request request_pb
1121
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1122
+ .with_bindings(
1123
+ uri_method: :get,
1124
+ uri_template: "/v1/{name}",
1125
+ matches: [
1126
+ ["name", %r{^projects/[^/]+/locations/[^/]+/managementServers/[^/]+/?$}, false]
1127
+ ]
1128
+ )
1129
+ transcoder.transcode request_pb
1130
+ end
1131
+
1132
+ ##
1133
+ # @private
1134
+ #
1135
+ # GRPC transcoding helper method for the create_management_server REST call
1136
+ #
1137
+ # @param request_pb [::Google::Cloud::BackupDR::V1::CreateManagementServerRequest]
1138
+ # A request object representing the call parameters. Required.
1139
+ # @return [Array(String, [String, nil], Hash{String => String})]
1140
+ # Uri, Body, Query string parameters
1141
+ def self.transcode_create_management_server_request request_pb
1142
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1143
+ .with_bindings(
1144
+ uri_method: :post,
1145
+ uri_template: "/v1/{parent}/managementServers",
1146
+ body: "management_server",
1147
+ matches: [
1148
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
1149
+ ]
1150
+ )
1151
+ transcoder.transcode request_pb
1152
+ end
1153
+
1154
+ ##
1155
+ # @private
1156
+ #
1157
+ # GRPC transcoding helper method for the delete_management_server REST call
1158
+ #
1159
+ # @param request_pb [::Google::Cloud::BackupDR::V1::DeleteManagementServerRequest]
1160
+ # A request object representing the call parameters. Required.
1161
+ # @return [Array(String, [String, nil], Hash{String => String})]
1162
+ # Uri, Body, Query string parameters
1163
+ def self.transcode_delete_management_server_request request_pb
1164
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1165
+ .with_bindings(
1166
+ uri_method: :delete,
1167
+ uri_template: "/v1/{name}",
1168
+ matches: [
1169
+ ["name", %r{^projects/[^/]+/locations/[^/]+/managementServers/[^/]+/?$}, false]
1170
+ ]
1171
+ )
1172
+ transcoder.transcode request_pb
1173
+ end
1174
+
1175
+ ##
1176
+ # @private
1177
+ #
1178
+ # GRPC transcoding helper method for the create_backup_vault REST call
1179
+ #
1180
+ # @param request_pb [::Google::Cloud::BackupDR::V1::CreateBackupVaultRequest]
1181
+ # A request object representing the call parameters. Required.
1182
+ # @return [Array(String, [String, nil], Hash{String => String})]
1183
+ # Uri, Body, Query string parameters
1184
+ def self.transcode_create_backup_vault_request request_pb
1185
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1186
+ .with_bindings(
1187
+ uri_method: :post,
1188
+ uri_template: "/v1/{parent}/backupVaults",
1189
+ body: "backup_vault",
1190
+ matches: [
1191
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
1192
+ ]
1193
+ )
1194
+ transcoder.transcode request_pb
1195
+ end
1196
+
1197
+ ##
1198
+ # @private
1199
+ #
1200
+ # GRPC transcoding helper method for the list_backup_vaults REST call
1201
+ #
1202
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListBackupVaultsRequest]
1203
+ # A request object representing the call parameters. Required.
1204
+ # @return [Array(String, [String, nil], Hash{String => String})]
1205
+ # Uri, Body, Query string parameters
1206
+ def self.transcode_list_backup_vaults_request request_pb
1207
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1208
+ .with_bindings(
1209
+ uri_method: :get,
1210
+ uri_template: "/v1/{parent}/backupVaults",
1211
+ matches: [
1212
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
1213
+ ]
1214
+ )
1215
+ transcoder.transcode request_pb
1216
+ end
1217
+
1218
+ ##
1219
+ # @private
1220
+ #
1221
+ # GRPC transcoding helper method for the fetch_usable_backup_vaults REST call
1222
+ #
1223
+ # @param request_pb [::Google::Cloud::BackupDR::V1::FetchUsableBackupVaultsRequest]
1224
+ # A request object representing the call parameters. Required.
1225
+ # @return [Array(String, [String, nil], Hash{String => String})]
1226
+ # Uri, Body, Query string parameters
1227
+ def self.transcode_fetch_usable_backup_vaults_request request_pb
1228
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1229
+ .with_bindings(
1230
+ uri_method: :get,
1231
+ uri_template: "/v1/{parent}/backupVaults:fetchUsable",
1232
+ matches: [
1233
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
1234
+ ]
1235
+ )
1236
+ transcoder.transcode request_pb
1237
+ end
1238
+
1239
+ ##
1240
+ # @private
1241
+ #
1242
+ # GRPC transcoding helper method for the get_backup_vault REST call
1243
+ #
1244
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetBackupVaultRequest]
1245
+ # A request object representing the call parameters. Required.
1246
+ # @return [Array(String, [String, nil], Hash{String => String})]
1247
+ # Uri, Body, Query string parameters
1248
+ def self.transcode_get_backup_vault_request request_pb
1249
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1250
+ .with_bindings(
1251
+ uri_method: :get,
1252
+ uri_template: "/v1/{name}",
1253
+ matches: [
1254
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/?$}, false]
1255
+ ]
1256
+ )
1257
+ transcoder.transcode request_pb
1258
+ end
1259
+
1260
+ ##
1261
+ # @private
1262
+ #
1263
+ # GRPC transcoding helper method for the update_backup_vault REST call
1264
+ #
1265
+ # @param request_pb [::Google::Cloud::BackupDR::V1::UpdateBackupVaultRequest]
1266
+ # A request object representing the call parameters. Required.
1267
+ # @return [Array(String, [String, nil], Hash{String => String})]
1268
+ # Uri, Body, Query string parameters
1269
+ def self.transcode_update_backup_vault_request request_pb
1270
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1271
+ .with_bindings(
1272
+ uri_method: :patch,
1273
+ uri_template: "/v1/{backup_vault.name}",
1274
+ body: "backup_vault",
1275
+ matches: [
1276
+ ["backup_vault.name", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/?$}, false]
1277
+ ]
1278
+ )
1279
+ transcoder.transcode request_pb
1280
+ end
1281
+
216
1282
  ##
217
1283
  # @private
218
1284
  #
219
- # GRPC transcoding helper method for the list_management_servers REST call
1285
+ # GRPC transcoding helper method for the delete_backup_vault REST call
220
1286
  #
221
- # @param request_pb [::Google::Cloud::BackupDR::V1::ListManagementServersRequest]
1287
+ # @param request_pb [::Google::Cloud::BackupDR::V1::DeleteBackupVaultRequest]
222
1288
  # A request object representing the call parameters. Required.
223
1289
  # @return [Array(String, [String, nil], Hash{String => String})]
224
1290
  # Uri, Body, Query string parameters
225
- def self.transcode_list_management_servers_request request_pb
1291
+ def self.transcode_delete_backup_vault_request request_pb
1292
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1293
+ .with_bindings(
1294
+ uri_method: :delete,
1295
+ uri_template: "/v1/{name}",
1296
+ matches: [
1297
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/?$}, false]
1298
+ ]
1299
+ )
1300
+ transcoder.transcode request_pb
1301
+ end
1302
+
1303
+ ##
1304
+ # @private
1305
+ #
1306
+ # GRPC transcoding helper method for the list_data_sources REST call
1307
+ #
1308
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListDataSourcesRequest]
1309
+ # A request object representing the call parameters. Required.
1310
+ # @return [Array(String, [String, nil], Hash{String => String})]
1311
+ # Uri, Body, Query string parameters
1312
+ def self.transcode_list_data_sources_request request_pb
226
1313
  transcoder = Gapic::Rest::GrpcTranscoder.new
227
1314
  .with_bindings(
228
1315
  uri_method: :get,
229
- uri_template: "/v1/{parent}/managementServers",
1316
+ uri_template: "/v1/{parent}/dataSources",
1317
+ matches: [
1318
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/?$}, false]
1319
+ ]
1320
+ )
1321
+ transcoder.transcode request_pb
1322
+ end
1323
+
1324
+ ##
1325
+ # @private
1326
+ #
1327
+ # GRPC transcoding helper method for the get_data_source REST call
1328
+ #
1329
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetDataSourceRequest]
1330
+ # A request object representing the call parameters. Required.
1331
+ # @return [Array(String, [String, nil], Hash{String => String})]
1332
+ # Uri, Body, Query string parameters
1333
+ def self.transcode_get_data_source_request request_pb
1334
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1335
+ .with_bindings(
1336
+ uri_method: :get,
1337
+ uri_template: "/v1/{name}",
1338
+ matches: [
1339
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/dataSources/[^/]+/?$}, false]
1340
+ ]
1341
+ )
1342
+ transcoder.transcode request_pb
1343
+ end
1344
+
1345
+ ##
1346
+ # @private
1347
+ #
1348
+ # GRPC transcoding helper method for the update_data_source REST call
1349
+ #
1350
+ # @param request_pb [::Google::Cloud::BackupDR::V1::UpdateDataSourceRequest]
1351
+ # A request object representing the call parameters. Required.
1352
+ # @return [Array(String, [String, nil], Hash{String => String})]
1353
+ # Uri, Body, Query string parameters
1354
+ def self.transcode_update_data_source_request request_pb
1355
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1356
+ .with_bindings(
1357
+ uri_method: :patch,
1358
+ uri_template: "/v1/{data_source.name}",
1359
+ body: "data_source",
1360
+ matches: [
1361
+ ["data_source.name", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/dataSources/[^/]+/?$}, false]
1362
+ ]
1363
+ )
1364
+ transcoder.transcode request_pb
1365
+ end
1366
+
1367
+ ##
1368
+ # @private
1369
+ #
1370
+ # GRPC transcoding helper method for the list_backups REST call
1371
+ #
1372
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListBackupsRequest]
1373
+ # A request object representing the call parameters. Required.
1374
+ # @return [Array(String, [String, nil], Hash{String => String})]
1375
+ # Uri, Body, Query string parameters
1376
+ def self.transcode_list_backups_request request_pb
1377
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1378
+ .with_bindings(
1379
+ uri_method: :get,
1380
+ uri_template: "/v1/{parent}/backups",
1381
+ matches: [
1382
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/dataSources/[^/]+/?$}, false]
1383
+ ]
1384
+ )
1385
+ transcoder.transcode request_pb
1386
+ end
1387
+
1388
+ ##
1389
+ # @private
1390
+ #
1391
+ # GRPC transcoding helper method for the get_backup REST call
1392
+ #
1393
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetBackupRequest]
1394
+ # A request object representing the call parameters. Required.
1395
+ # @return [Array(String, [String, nil], Hash{String => String})]
1396
+ # Uri, Body, Query string parameters
1397
+ def self.transcode_get_backup_request request_pb
1398
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1399
+ .with_bindings(
1400
+ uri_method: :get,
1401
+ uri_template: "/v1/{name}",
1402
+ matches: [
1403
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/dataSources/[^/]+/backups/[^/]+/?$}, false]
1404
+ ]
1405
+ )
1406
+ transcoder.transcode request_pb
1407
+ end
1408
+
1409
+ ##
1410
+ # @private
1411
+ #
1412
+ # GRPC transcoding helper method for the update_backup REST call
1413
+ #
1414
+ # @param request_pb [::Google::Cloud::BackupDR::V1::UpdateBackupRequest]
1415
+ # A request object representing the call parameters. Required.
1416
+ # @return [Array(String, [String, nil], Hash{String => String})]
1417
+ # Uri, Body, Query string parameters
1418
+ def self.transcode_update_backup_request request_pb
1419
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1420
+ .with_bindings(
1421
+ uri_method: :patch,
1422
+ uri_template: "/v1/{backup.name}",
1423
+ body: "backup",
1424
+ matches: [
1425
+ ["backup.name", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/dataSources/[^/]+/backups/[^/]+/?$}, false]
1426
+ ]
1427
+ )
1428
+ transcoder.transcode request_pb
1429
+ end
1430
+
1431
+ ##
1432
+ # @private
1433
+ #
1434
+ # GRPC transcoding helper method for the delete_backup REST call
1435
+ #
1436
+ # @param request_pb [::Google::Cloud::BackupDR::V1::DeleteBackupRequest]
1437
+ # A request object representing the call parameters. Required.
1438
+ # @return [Array(String, [String, nil], Hash{String => String})]
1439
+ # Uri, Body, Query string parameters
1440
+ def self.transcode_delete_backup_request request_pb
1441
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1442
+ .with_bindings(
1443
+ uri_method: :delete,
1444
+ uri_template: "/v1/{name}",
1445
+ matches: [
1446
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/dataSources/[^/]+/backups/[^/]+/?$}, false]
1447
+ ]
1448
+ )
1449
+ transcoder.transcode request_pb
1450
+ end
1451
+
1452
+ ##
1453
+ # @private
1454
+ #
1455
+ # GRPC transcoding helper method for the restore_backup REST call
1456
+ #
1457
+ # @param request_pb [::Google::Cloud::BackupDR::V1::RestoreBackupRequest]
1458
+ # A request object representing the call parameters. Required.
1459
+ # @return [Array(String, [String, nil], Hash{String => String})]
1460
+ # Uri, Body, Query string parameters
1461
+ def self.transcode_restore_backup_request request_pb
1462
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1463
+ .with_bindings(
1464
+ uri_method: :post,
1465
+ uri_template: "/v1/{name}:restore",
1466
+ body: "*",
1467
+ matches: [
1468
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupVaults/[^/]+/dataSources/[^/]+/backups/[^/]+/?$}, false]
1469
+ ]
1470
+ )
1471
+ transcoder.transcode request_pb
1472
+ end
1473
+
1474
+ ##
1475
+ # @private
1476
+ #
1477
+ # GRPC transcoding helper method for the create_backup_plan REST call
1478
+ #
1479
+ # @param request_pb [::Google::Cloud::BackupDR::V1::CreateBackupPlanRequest]
1480
+ # A request object representing the call parameters. Required.
1481
+ # @return [Array(String, [String, nil], Hash{String => String})]
1482
+ # Uri, Body, Query string parameters
1483
+ def self.transcode_create_backup_plan_request request_pb
1484
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1485
+ .with_bindings(
1486
+ uri_method: :post,
1487
+ uri_template: "/v1/{parent}/backupPlans",
1488
+ body: "backup_plan",
230
1489
  matches: [
231
1490
  ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
232
1491
  ]
@@ -237,19 +1496,19 @@ module Google
237
1496
  ##
238
1497
  # @private
239
1498
  #
240
- # GRPC transcoding helper method for the get_management_server REST call
1499
+ # GRPC transcoding helper method for the get_backup_plan REST call
241
1500
  #
242
- # @param request_pb [::Google::Cloud::BackupDR::V1::GetManagementServerRequest]
1501
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetBackupPlanRequest]
243
1502
  # A request object representing the call parameters. Required.
244
1503
  # @return [Array(String, [String, nil], Hash{String => String})]
245
1504
  # Uri, Body, Query string parameters
246
- def self.transcode_get_management_server_request request_pb
1505
+ def self.transcode_get_backup_plan_request request_pb
247
1506
  transcoder = Gapic::Rest::GrpcTranscoder.new
248
1507
  .with_bindings(
249
1508
  uri_method: :get,
250
1509
  uri_template: "/v1/{name}",
251
1510
  matches: [
252
- ["name", %r{^projects/[^/]+/locations/[^/]+/managementServers/[^/]+/?$}, false]
1511
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/?$}, false]
253
1512
  ]
254
1513
  )
255
1514
  transcoder.transcode request_pb
@@ -258,18 +1517,60 @@ module Google
258
1517
  ##
259
1518
  # @private
260
1519
  #
261
- # GRPC transcoding helper method for the create_management_server REST call
1520
+ # GRPC transcoding helper method for the list_backup_plans REST call
262
1521
  #
263
- # @param request_pb [::Google::Cloud::BackupDR::V1::CreateManagementServerRequest]
1522
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListBackupPlansRequest]
264
1523
  # A request object representing the call parameters. Required.
265
1524
  # @return [Array(String, [String, nil], Hash{String => String})]
266
1525
  # Uri, Body, Query string parameters
267
- def self.transcode_create_management_server_request request_pb
1526
+ def self.transcode_list_backup_plans_request request_pb
1527
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1528
+ .with_bindings(
1529
+ uri_method: :get,
1530
+ uri_template: "/v1/{parent}/backupPlans",
1531
+ matches: [
1532
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
1533
+ ]
1534
+ )
1535
+ transcoder.transcode request_pb
1536
+ end
1537
+
1538
+ ##
1539
+ # @private
1540
+ #
1541
+ # GRPC transcoding helper method for the delete_backup_plan REST call
1542
+ #
1543
+ # @param request_pb [::Google::Cloud::BackupDR::V1::DeleteBackupPlanRequest]
1544
+ # A request object representing the call parameters. Required.
1545
+ # @return [Array(String, [String, nil], Hash{String => String})]
1546
+ # Uri, Body, Query string parameters
1547
+ def self.transcode_delete_backup_plan_request request_pb
1548
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1549
+ .with_bindings(
1550
+ uri_method: :delete,
1551
+ uri_template: "/v1/{name}",
1552
+ matches: [
1553
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/?$}, false]
1554
+ ]
1555
+ )
1556
+ transcoder.transcode request_pb
1557
+ end
1558
+
1559
+ ##
1560
+ # @private
1561
+ #
1562
+ # GRPC transcoding helper method for the create_backup_plan_association REST call
1563
+ #
1564
+ # @param request_pb [::Google::Cloud::BackupDR::V1::CreateBackupPlanAssociationRequest]
1565
+ # A request object representing the call parameters. Required.
1566
+ # @return [Array(String, [String, nil], Hash{String => String})]
1567
+ # Uri, Body, Query string parameters
1568
+ def self.transcode_create_backup_plan_association_request request_pb
268
1569
  transcoder = Gapic::Rest::GrpcTranscoder.new
269
1570
  .with_bindings(
270
1571
  uri_method: :post,
271
- uri_template: "/v1/{parent}/managementServers",
272
- body: "management_server",
1572
+ uri_template: "/v1/{parent}/backupPlanAssociations",
1573
+ body: "backup_plan_association",
273
1574
  matches: [
274
1575
  ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
275
1576
  ]
@@ -280,19 +1581,83 @@ module Google
280
1581
  ##
281
1582
  # @private
282
1583
  #
283
- # GRPC transcoding helper method for the delete_management_server REST call
1584
+ # GRPC transcoding helper method for the get_backup_plan_association REST call
284
1585
  #
285
- # @param request_pb [::Google::Cloud::BackupDR::V1::DeleteManagementServerRequest]
1586
+ # @param request_pb [::Google::Cloud::BackupDR::V1::GetBackupPlanAssociationRequest]
286
1587
  # A request object representing the call parameters. Required.
287
1588
  # @return [Array(String, [String, nil], Hash{String => String})]
288
1589
  # Uri, Body, Query string parameters
289
- def self.transcode_delete_management_server_request request_pb
1590
+ def self.transcode_get_backup_plan_association_request request_pb
1591
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1592
+ .with_bindings(
1593
+ uri_method: :get,
1594
+ uri_template: "/v1/{name}",
1595
+ matches: [
1596
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupPlanAssociations/[^/]+/?$}, false]
1597
+ ]
1598
+ )
1599
+ transcoder.transcode request_pb
1600
+ end
1601
+
1602
+ ##
1603
+ # @private
1604
+ #
1605
+ # GRPC transcoding helper method for the list_backup_plan_associations REST call
1606
+ #
1607
+ # @param request_pb [::Google::Cloud::BackupDR::V1::ListBackupPlanAssociationsRequest]
1608
+ # A request object representing the call parameters. Required.
1609
+ # @return [Array(String, [String, nil], Hash{String => String})]
1610
+ # Uri, Body, Query string parameters
1611
+ def self.transcode_list_backup_plan_associations_request request_pb
1612
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1613
+ .with_bindings(
1614
+ uri_method: :get,
1615
+ uri_template: "/v1/{parent}/backupPlanAssociations",
1616
+ matches: [
1617
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
1618
+ ]
1619
+ )
1620
+ transcoder.transcode request_pb
1621
+ end
1622
+
1623
+ ##
1624
+ # @private
1625
+ #
1626
+ # GRPC transcoding helper method for the delete_backup_plan_association REST call
1627
+ #
1628
+ # @param request_pb [::Google::Cloud::BackupDR::V1::DeleteBackupPlanAssociationRequest]
1629
+ # A request object representing the call parameters. Required.
1630
+ # @return [Array(String, [String, nil], Hash{String => String})]
1631
+ # Uri, Body, Query string parameters
1632
+ def self.transcode_delete_backup_plan_association_request request_pb
290
1633
  transcoder = Gapic::Rest::GrpcTranscoder.new
291
1634
  .with_bindings(
292
1635
  uri_method: :delete,
293
1636
  uri_template: "/v1/{name}",
294
1637
  matches: [
295
- ["name", %r{^projects/[^/]+/locations/[^/]+/managementServers/[^/]+/?$}, false]
1638
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupPlanAssociations/[^/]+/?$}, false]
1639
+ ]
1640
+ )
1641
+ transcoder.transcode request_pb
1642
+ end
1643
+
1644
+ ##
1645
+ # @private
1646
+ #
1647
+ # GRPC transcoding helper method for the trigger_backup REST call
1648
+ #
1649
+ # @param request_pb [::Google::Cloud::BackupDR::V1::TriggerBackupRequest]
1650
+ # A request object representing the call parameters. Required.
1651
+ # @return [Array(String, [String, nil], Hash{String => String})]
1652
+ # Uri, Body, Query string parameters
1653
+ def self.transcode_trigger_backup_request request_pb
1654
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1655
+ .with_bindings(
1656
+ uri_method: :post,
1657
+ uri_template: "/v1/{name}:triggerBackup",
1658
+ body: "*",
1659
+ matches: [
1660
+ ["name", %r{^projects/[^/]+/locations/[^/]+/backupPlanAssociations/[^/]+/?$}, false]
296
1661
  ]
297
1662
  )
298
1663
  transcoder.transcode request_pb