google-cloud-gaming-v1 0.4.0 → 0.4.1

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 (24) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/cloud/gaming/v1/common_pb.rb +2 -2
  3. data/lib/google/cloud/gaming/v1/game_server_clusters_pb.rb +2 -2
  4. data/lib/google/cloud/gaming/v1/game_server_clusters_service/client.rb +187 -24
  5. data/lib/google/cloud/gaming/v1/game_server_clusters_service/operations.rb +115 -12
  6. data/lib/google/cloud/gaming/v1/game_server_clusters_service_pb.rb +2 -2
  7. data/lib/google/cloud/gaming/v1/game_server_clusters_service_services_pb.rb +1 -1
  8. data/lib/google/cloud/gaming/v1/game_server_configs_pb.rb +2 -2
  9. data/lib/google/cloud/gaming/v1/game_server_configs_service/client.rb +100 -12
  10. data/lib/google/cloud/gaming/v1/game_server_configs_service/operations.rb +115 -12
  11. data/lib/google/cloud/gaming/v1/game_server_configs_service_pb.rb +2 -2
  12. data/lib/google/cloud/gaming/v1/game_server_configs_service_services_pb.rb +1 -1
  13. data/lib/google/cloud/gaming/v1/game_server_deployments_pb.rb +2 -2
  14. data/lib/google/cloud/gaming/v1/game_server_deployments_service/client.rb +214 -27
  15. data/lib/google/cloud/gaming/v1/game_server_deployments_service/operations.rb +115 -12
  16. data/lib/google/cloud/gaming/v1/game_server_deployments_service_pb.rb +2 -2
  17. data/lib/google/cloud/gaming/v1/game_server_deployments_service_services_pb.rb +1 -1
  18. data/lib/google/cloud/gaming/v1/realms_pb.rb +2 -2
  19. data/lib/google/cloud/gaming/v1/realms_service/client.rb +147 -18
  20. data/lib/google/cloud/gaming/v1/realms_service/operations.rb +115 -12
  21. data/lib/google/cloud/gaming/v1/realms_service_pb.rb +2 -2
  22. data/lib/google/cloud/gaming/v1/realms_service_services_pb.rb +1 -1
  23. data/lib/google/cloud/gaming/v1/version.rb +1 -1
  24. metadata +2 -2
@@ -234,6 +234,27 @@ module Google
234
234
  #
235
235
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
236
236
  #
237
+ # @example Basic example
238
+ # require "google/cloud/gaming/v1"
239
+ #
240
+ # # Create a client object. The client can be reused for multiple calls.
241
+ # client = Google::Cloud::Gaming::V1::GameServerDeploymentsService::Client.new
242
+ #
243
+ # # Create a request. To set request fields, pass in keyword arguments.
244
+ # request = Google::Cloud::Gaming::V1::ListGameServerDeploymentsRequest.new
245
+ #
246
+ # # Call the list_game_server_deployments method.
247
+ # result = client.list_game_server_deployments request
248
+ #
249
+ # # The returned object is of type Gapic::PagedEnumerable. You can
250
+ # # iterate over all elements by calling #each, and the enumerable
251
+ # # will lazily make API calls to fetch subsequent pages. Other
252
+ # # methods are also available for managing paging directly.
253
+ # result.each do |response|
254
+ # # Each element is of type ::Google::Cloud::Gaming::V1::GameServerDeployment.
255
+ # p response
256
+ # end
257
+ #
237
258
  def list_game_server_deployments request, options = nil
238
259
  raise ::ArgumentError, "request must be provided" if request.nil?
239
260
 
@@ -251,9 +272,11 @@ module Google
251
272
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
252
273
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
253
274
 
254
- header_params = {
255
- "parent" => request.parent
256
- }
275
+ header_params = {}
276
+ if request.parent
277
+ header_params["parent"] = request.parent
278
+ end
279
+
257
280
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
258
281
  metadata[:"x-goog-request-params"] ||= request_params_header
259
282
 
@@ -304,6 +327,21 @@ module Google
304
327
  #
305
328
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
306
329
  #
330
+ # @example Basic example
331
+ # require "google/cloud/gaming/v1"
332
+ #
333
+ # # Create a client object. The client can be reused for multiple calls.
334
+ # client = Google::Cloud::Gaming::V1::GameServerDeploymentsService::Client.new
335
+ #
336
+ # # Create a request. To set request fields, pass in keyword arguments.
337
+ # request = Google::Cloud::Gaming::V1::GetGameServerDeploymentRequest.new
338
+ #
339
+ # # Call the get_game_server_deployment method.
340
+ # result = client.get_game_server_deployment request
341
+ #
342
+ # # The returned object is of type Google::Cloud::Gaming::V1::GameServerDeployment.
343
+ # p result
344
+ #
307
345
  def get_game_server_deployment request, options = nil
308
346
  raise ::ArgumentError, "request must be provided" if request.nil?
309
347
 
@@ -321,9 +359,11 @@ module Google
321
359
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
322
360
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
323
361
 
324
- header_params = {
325
- "name" => request.name
326
- }
362
+ header_params = {}
363
+ if request.name
364
+ header_params["name"] = request.name
365
+ end
366
+
327
367
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
328
368
  metadata[:"x-goog-request-params"] ||= request_params_header
329
369
 
@@ -377,6 +417,28 @@ module Google
377
417
  #
378
418
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
379
419
  #
420
+ # @example Basic example
421
+ # require "google/cloud/gaming/v1"
422
+ #
423
+ # # Create a client object. The client can be reused for multiple calls.
424
+ # client = Google::Cloud::Gaming::V1::GameServerDeploymentsService::Client.new
425
+ #
426
+ # # Create a request. To set request fields, pass in keyword arguments.
427
+ # request = Google::Cloud::Gaming::V1::CreateGameServerDeploymentRequest.new
428
+ #
429
+ # # Call the create_game_server_deployment method.
430
+ # result = client.create_game_server_deployment request
431
+ #
432
+ # # The returned object is of type Gapic::Operation. You can use this
433
+ # # object to check the status of an operation, cancel it, or wait
434
+ # # for results. Here is how to block until completion:
435
+ # result.wait_until_done! timeout: 60
436
+ # if result.response?
437
+ # p result.response
438
+ # else
439
+ # puts "Error!"
440
+ # end
441
+ #
380
442
  def create_game_server_deployment request, options = nil
381
443
  raise ::ArgumentError, "request must be provided" if request.nil?
382
444
 
@@ -394,9 +456,11 @@ module Google
394
456
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
395
457
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
396
458
 
397
- header_params = {
398
- "parent" => request.parent
399
- }
459
+ header_params = {}
460
+ if request.parent
461
+ header_params["parent"] = request.parent
462
+ end
463
+
400
464
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
401
465
  metadata[:"x-goog-request-params"] ||= request_params_header
402
466
 
@@ -447,6 +511,28 @@ module Google
447
511
  #
448
512
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
449
513
  #
514
+ # @example Basic example
515
+ # require "google/cloud/gaming/v1"
516
+ #
517
+ # # Create a client object. The client can be reused for multiple calls.
518
+ # client = Google::Cloud::Gaming::V1::GameServerDeploymentsService::Client.new
519
+ #
520
+ # # Create a request. To set request fields, pass in keyword arguments.
521
+ # request = Google::Cloud::Gaming::V1::DeleteGameServerDeploymentRequest.new
522
+ #
523
+ # # Call the delete_game_server_deployment method.
524
+ # result = client.delete_game_server_deployment request
525
+ #
526
+ # # The returned object is of type Gapic::Operation. You can use this
527
+ # # object to check the status of an operation, cancel it, or wait
528
+ # # for results. Here is how to block until completion:
529
+ # result.wait_until_done! timeout: 60
530
+ # if result.response?
531
+ # p result.response
532
+ # else
533
+ # puts "Error!"
534
+ # end
535
+ #
450
536
  def delete_game_server_deployment request, options = nil
451
537
  raise ::ArgumentError, "request must be provided" if request.nil?
452
538
 
@@ -464,9 +550,11 @@ module Google
464
550
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
465
551
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
466
552
 
467
- header_params = {
468
- "name" => request.name
469
- }
553
+ header_params = {}
554
+ if request.name
555
+ header_params["name"] = request.name
556
+ end
557
+
470
558
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
471
559
  metadata[:"x-goog-request-params"] ||= request_params_header
472
560
 
@@ -521,6 +609,28 @@ module Google
521
609
  #
522
610
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
523
611
  #
612
+ # @example Basic example
613
+ # require "google/cloud/gaming/v1"
614
+ #
615
+ # # Create a client object. The client can be reused for multiple calls.
616
+ # client = Google::Cloud::Gaming::V1::GameServerDeploymentsService::Client.new
617
+ #
618
+ # # Create a request. To set request fields, pass in keyword arguments.
619
+ # request = Google::Cloud::Gaming::V1::UpdateGameServerDeploymentRequest.new
620
+ #
621
+ # # Call the update_game_server_deployment method.
622
+ # result = client.update_game_server_deployment request
623
+ #
624
+ # # The returned object is of type Gapic::Operation. You can use this
625
+ # # object to check the status of an operation, cancel it, or wait
626
+ # # for results. Here is how to block until completion:
627
+ # result.wait_until_done! timeout: 60
628
+ # if result.response?
629
+ # p result.response
630
+ # else
631
+ # puts "Error!"
632
+ # end
633
+ #
524
634
  def update_game_server_deployment request, options = nil
525
635
  raise ::ArgumentError, "request must be provided" if request.nil?
526
636
 
@@ -538,9 +648,11 @@ module Google
538
648
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
539
649
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
540
650
 
541
- header_params = {
542
- "game_server_deployment.name" => request.game_server_deployment.name
543
- }
651
+ header_params = {}
652
+ if request.game_server_deployment&.name
653
+ header_params["game_server_deployment.name"] = request.game_server_deployment.name
654
+ end
655
+
544
656
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
545
657
  metadata[:"x-goog-request-params"] ||= request_params_header
546
658
 
@@ -591,6 +703,21 @@ module Google
591
703
  #
592
704
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
593
705
  #
706
+ # @example Basic example
707
+ # require "google/cloud/gaming/v1"
708
+ #
709
+ # # Create a client object. The client can be reused for multiple calls.
710
+ # client = Google::Cloud::Gaming::V1::GameServerDeploymentsService::Client.new
711
+ #
712
+ # # Create a request. To set request fields, pass in keyword arguments.
713
+ # request = Google::Cloud::Gaming::V1::GetGameServerDeploymentRolloutRequest.new
714
+ #
715
+ # # Call the get_game_server_deployment_rollout method.
716
+ # result = client.get_game_server_deployment_rollout request
717
+ #
718
+ # # The returned object is of type Google::Cloud::Gaming::V1::GameServerDeploymentRollout.
719
+ # p result
720
+ #
594
721
  def get_game_server_deployment_rollout request, options = nil
595
722
  raise ::ArgumentError, "request must be provided" if request.nil?
596
723
 
@@ -608,9 +735,11 @@ module Google
608
735
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
609
736
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
610
737
 
611
- header_params = {
612
- "name" => request.name
613
- }
738
+ header_params = {}
739
+ if request.name
740
+ header_params["name"] = request.name
741
+ end
742
+
614
743
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
615
744
  metadata[:"x-goog-request-params"] ||= request_params_header
616
745
 
@@ -669,6 +798,28 @@ module Google
669
798
  #
670
799
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
671
800
  #
801
+ # @example Basic example
802
+ # require "google/cloud/gaming/v1"
803
+ #
804
+ # # Create a client object. The client can be reused for multiple calls.
805
+ # client = Google::Cloud::Gaming::V1::GameServerDeploymentsService::Client.new
806
+ #
807
+ # # Create a request. To set request fields, pass in keyword arguments.
808
+ # request = Google::Cloud::Gaming::V1::UpdateGameServerDeploymentRolloutRequest.new
809
+ #
810
+ # # Call the update_game_server_deployment_rollout method.
811
+ # result = client.update_game_server_deployment_rollout request
812
+ #
813
+ # # The returned object is of type Gapic::Operation. You can use this
814
+ # # object to check the status of an operation, cancel it, or wait
815
+ # # for results. Here is how to block until completion:
816
+ # result.wait_until_done! timeout: 60
817
+ # if result.response?
818
+ # p result.response
819
+ # else
820
+ # puts "Error!"
821
+ # end
822
+ #
672
823
  def update_game_server_deployment_rollout request, options = nil
673
824
  raise ::ArgumentError, "request must be provided" if request.nil?
674
825
 
@@ -686,9 +837,11 @@ module Google
686
837
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
687
838
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
688
839
 
689
- header_params = {
690
- "rollout.name" => request.rollout.name
691
- }
840
+ header_params = {}
841
+ if request.rollout&.name
842
+ header_params["rollout.name"] = request.rollout.name
843
+ end
844
+
692
845
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
693
846
  metadata[:"x-goog-request-params"] ||= request_params_header
694
847
 
@@ -747,6 +900,21 @@ module Google
747
900
  #
748
901
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
749
902
  #
903
+ # @example Basic example
904
+ # require "google/cloud/gaming/v1"
905
+ #
906
+ # # Create a client object. The client can be reused for multiple calls.
907
+ # client = Google::Cloud::Gaming::V1::GameServerDeploymentsService::Client.new
908
+ #
909
+ # # Create a request. To set request fields, pass in keyword arguments.
910
+ # request = Google::Cloud::Gaming::V1::PreviewGameServerDeploymentRolloutRequest.new
911
+ #
912
+ # # Call the preview_game_server_deployment_rollout method.
913
+ # result = client.preview_game_server_deployment_rollout request
914
+ #
915
+ # # The returned object is of type Google::Cloud::Gaming::V1::PreviewGameServerDeploymentRolloutResponse.
916
+ # p result
917
+ #
750
918
  def preview_game_server_deployment_rollout request, options = nil
751
919
  raise ::ArgumentError, "request must be provided" if request.nil?
752
920
 
@@ -764,9 +932,11 @@ module Google
764
932
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
765
933
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
766
934
 
767
- header_params = {
768
- "rollout.name" => request.rollout.name
769
- }
935
+ header_params = {}
936
+ if request.rollout&.name
937
+ header_params["rollout.name"] = request.rollout.name
938
+ end
939
+
770
940
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
771
941
  metadata[:"x-goog-request-params"] ||= request_params_header
772
942
 
@@ -818,6 +988,21 @@ module Google
818
988
  #
819
989
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
820
990
  #
991
+ # @example Basic example
992
+ # require "google/cloud/gaming/v1"
993
+ #
994
+ # # Create a client object. The client can be reused for multiple calls.
995
+ # client = Google::Cloud::Gaming::V1::GameServerDeploymentsService::Client.new
996
+ #
997
+ # # Create a request. To set request fields, pass in keyword arguments.
998
+ # request = Google::Cloud::Gaming::V1::FetchDeploymentStateRequest.new
999
+ #
1000
+ # # Call the fetch_deployment_state method.
1001
+ # result = client.fetch_deployment_state request
1002
+ #
1003
+ # # The returned object is of type Google::Cloud::Gaming::V1::FetchDeploymentStateResponse.
1004
+ # p result
1005
+ #
821
1006
  def fetch_deployment_state request, options = nil
822
1007
  raise ::ArgumentError, "request must be provided" if request.nil?
823
1008
 
@@ -835,9 +1020,11 @@ module Google
835
1020
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
836
1021
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
837
1022
 
838
- header_params = {
839
- "name" => request.name
840
- }
1023
+ header_params = {}
1024
+ if request.name
1025
+ header_params["name"] = request.name
1026
+ end
1027
+
841
1028
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
842
1029
  metadata[:"x-goog-request-params"] ||= request_params_header
843
1030
 
@@ -143,6 +143,27 @@ module Google
143
143
  #
144
144
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
145
145
  #
146
+ # @example Basic example
147
+ # require "google/longrunning"
148
+ #
149
+ # # Create a client object. The client can be reused for multiple calls.
150
+ # client = Google::Longrunning::Operations::Client.new
151
+ #
152
+ # # Create a request. To set request fields, pass in keyword arguments.
153
+ # request = Google::Longrunning::ListOperationsRequest.new
154
+ #
155
+ # # Call the list_operations method.
156
+ # result = client.list_operations request
157
+ #
158
+ # # The returned object is of type Gapic::PagedEnumerable. You can
159
+ # # iterate over all elements by calling #each, and the enumerable
160
+ # # will lazily make API calls to fetch subsequent pages. Other
161
+ # # methods are also available for managing paging directly.
162
+ # result.each do |response|
163
+ # # Each element is of type ::Google::Longrunning::Operation.
164
+ # p response
165
+ # end
166
+ #
146
167
  def list_operations request, options = nil
147
168
  raise ::ArgumentError, "request must be provided" if request.nil?
148
169
 
@@ -160,9 +181,11 @@ module Google
160
181
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
161
182
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
162
183
 
163
- header_params = {
164
- "name" => request.name
165
- }
184
+ header_params = {}
185
+ if request.name
186
+ header_params["name"] = request.name
187
+ end
188
+
166
189
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
167
190
  metadata[:"x-goog-request-params"] ||= request_params_header
168
191
 
@@ -215,6 +238,28 @@ module Google
215
238
  #
216
239
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
217
240
  #
241
+ # @example Basic example
242
+ # require "google/longrunning"
243
+ #
244
+ # # Create a client object. The client can be reused for multiple calls.
245
+ # client = Google::Longrunning::Operations::Client.new
246
+ #
247
+ # # Create a request. To set request fields, pass in keyword arguments.
248
+ # request = Google::Longrunning::GetOperationRequest.new
249
+ #
250
+ # # Call the get_operation method.
251
+ # result = client.get_operation request
252
+ #
253
+ # # The returned object is of type Gapic::Operation. You can use this
254
+ # # object to check the status of an operation, cancel it, or wait
255
+ # # for results. Here is how to block until completion:
256
+ # result.wait_until_done! timeout: 60
257
+ # if result.response?
258
+ # p result.response
259
+ # else
260
+ # puts "Error!"
261
+ # end
262
+ #
218
263
  def get_operation request, options = nil
219
264
  raise ::ArgumentError, "request must be provided" if request.nil?
220
265
 
@@ -232,9 +277,11 @@ module Google
232
277
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
233
278
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
234
279
 
235
- header_params = {
236
- "name" => request.name
237
- }
280
+ header_params = {}
281
+ if request.name
282
+ header_params["name"] = request.name
283
+ end
284
+
238
285
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
239
286
  metadata[:"x-goog-request-params"] ||= request_params_header
240
287
 
@@ -287,6 +334,21 @@ module Google
287
334
  #
288
335
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
289
336
  #
337
+ # @example Basic example
338
+ # require "google/longrunning"
339
+ #
340
+ # # Create a client object. The client can be reused for multiple calls.
341
+ # client = Google::Longrunning::Operations::Client.new
342
+ #
343
+ # # Create a request. To set request fields, pass in keyword arguments.
344
+ # request = Google::Longrunning::DeleteOperationRequest.new
345
+ #
346
+ # # Call the delete_operation method.
347
+ # result = client.delete_operation request
348
+ #
349
+ # # The returned object is of type Google::Protobuf::Empty.
350
+ # p result
351
+ #
290
352
  def delete_operation request, options = nil
291
353
  raise ::ArgumentError, "request must be provided" if request.nil?
292
354
 
@@ -304,9 +366,11 @@ module Google
304
366
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
305
367
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
306
368
 
307
- header_params = {
308
- "name" => request.name
309
- }
369
+ header_params = {}
370
+ if request.name
371
+ header_params["name"] = request.name
372
+ end
373
+
310
374
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
311
375
  metadata[:"x-goog-request-params"] ||= request_params_header
312
376
 
@@ -364,6 +428,21 @@ module Google
364
428
  #
365
429
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
366
430
  #
431
+ # @example Basic example
432
+ # require "google/longrunning"
433
+ #
434
+ # # Create a client object. The client can be reused for multiple calls.
435
+ # client = Google::Longrunning::Operations::Client.new
436
+ #
437
+ # # Create a request. To set request fields, pass in keyword arguments.
438
+ # request = Google::Longrunning::CancelOperationRequest.new
439
+ #
440
+ # # Call the cancel_operation method.
441
+ # result = client.cancel_operation request
442
+ #
443
+ # # The returned object is of type Google::Protobuf::Empty.
444
+ # p result
445
+ #
367
446
  def cancel_operation request, options = nil
368
447
  raise ::ArgumentError, "request must be provided" if request.nil?
369
448
 
@@ -381,9 +460,11 @@ module Google
381
460
  gapic_version: ::Google::Cloud::Gaming::V1::VERSION
382
461
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
383
462
 
384
- header_params = {
385
- "name" => request.name
386
- }
463
+ header_params = {}
464
+ if request.name
465
+ header_params["name"] = request.name
466
+ end
467
+
387
468
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
388
469
  metadata[:"x-goog-request-params"] ||= request_params_header
389
470
 
@@ -444,6 +525,28 @@ module Google
444
525
  #
445
526
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
446
527
  #
528
+ # @example Basic example
529
+ # require "google/longrunning"
530
+ #
531
+ # # Create a client object. The client can be reused for multiple calls.
532
+ # client = Google::Longrunning::Operations::Client.new
533
+ #
534
+ # # Create a request. To set request fields, pass in keyword arguments.
535
+ # request = Google::Longrunning::WaitOperationRequest.new
536
+ #
537
+ # # Call the wait_operation method.
538
+ # result = client.wait_operation request
539
+ #
540
+ # # The returned object is of type Gapic::Operation. You can use this
541
+ # # object to check the status of an operation, cancel it, or wait
542
+ # # for results. Here is how to block until completion:
543
+ # result.wait_until_done! timeout: 60
544
+ # if result.response?
545
+ # p result.response
546
+ # else
547
+ # puts "Error!"
548
+ # end
549
+ #
447
550
  def wait_operation request, options = nil
448
551
  raise ::ArgumentError, "request must be provided" if request.nil?
449
552
 
@@ -1,12 +1,12 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/cloud/gaming/v1/game_server_deployments_service.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/api/client_pb'
8
6
  require 'google/cloud/gaming/v1/game_server_deployments_pb'
9
7
  require 'google/longrunning/operations_pb'
8
+ require 'google/protobuf'
9
+
10
10
  Google::Protobuf::DescriptorPool.generated_pool.build do
11
11
  add_file("google/cloud/gaming/v1/game_server_deployments_service.proto", :syntax => :proto3) do
12
12
  end
@@ -28,7 +28,7 @@ module Google
28
28
  # fleets.
29
29
  class Service
30
30
 
31
- include GRPC::GenericService
31
+ include ::GRPC::GenericService
32
32
 
33
33
  self.marshal_class_method = :encode
34
34
  self.unmarshal_class_method = :decode
@@ -1,14 +1,14 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/cloud/gaming/v1/realms.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/field_behavior_pb'
7
5
  require 'google/api/resource_pb'
8
6
  require 'google/cloud/gaming/v1/common_pb'
9
7
  require 'google/protobuf/field_mask_pb'
10
8
  require 'google/protobuf/timestamp_pb'
11
9
  require 'google/api/annotations_pb'
10
+ require 'google/protobuf'
11
+
12
12
  Google::Protobuf::DescriptorPool.generated_pool.build do
13
13
  add_file("google/cloud/gaming/v1/realms.proto", :syntax => :proto3) do
14
14
  add_message "google.cloud.gaming.v1.ListRealmsRequest" do