google-cloud-resource_manager-v3 0.1.0 → 0.1.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.
- checksums.yaml +4 -4
- data/lib/google/cloud/resource_manager/v3/folders/client.rb +254 -24
- data/lib/google/cloud/resource_manager/v3/folders/operations.rb +115 -12
- data/lib/google/cloud/resource_manager/v3/organizations/client.rb +103 -13
- data/lib/google/cloud/resource_manager/v3/projects/client.rb +254 -24
- data/lib/google/cloud/resource_manager/v3/projects/operations.rb +115 -12
- data/lib/google/cloud/resource_manager/v3/tag_bindings/client.rb +70 -3
- data/lib/google/cloud/resource_manager/v3/tag_bindings/operations.rb +115 -12
- data/lib/google/cloud/resource_manager/v3/tag_keys/client.rb +177 -18
- data/lib/google/cloud/resource_manager/v3/tag_keys/operations.rb +115 -12
- data/lib/google/cloud/resource_manager/v3/tag_values/client.rb +177 -18
- data/lib/google/cloud/resource_manager/v3/tag_values/operations.rb +115 -12
- data/lib/google/cloud/resource_manager/v3/version.rb +1 -1
- data/lib/google/cloud/resourcemanager/v3/folders_pb.rb +2 -2
- data/lib/google/cloud/resourcemanager/v3/folders_services_pb.rb +1 -1
- data/lib/google/cloud/resourcemanager/v3/organizations_pb.rb +2 -2
- data/lib/google/cloud/resourcemanager/v3/organizations_services_pb.rb +1 -1
- data/lib/google/cloud/resourcemanager/v3/projects_pb.rb +2 -2
- data/lib/google/cloud/resourcemanager/v3/projects_services_pb.rb +1 -1
- data/lib/google/cloud/resourcemanager/v3/tag_bindings_pb.rb +2 -2
- data/lib/google/cloud/resourcemanager/v3/tag_bindings_services_pb.rb +1 -1
- data/lib/google/cloud/resourcemanager/v3/tag_keys_pb.rb +2 -2
- data/lib/google/cloud/resourcemanager/v3/tag_keys_services_pb.rb +1 -1
- data/lib/google/cloud/resourcemanager/v3/tag_values_pb.rb +2 -2
- data/lib/google/cloud/resourcemanager/v3/tag_values_services_pb.rb +1 -1
- data/proto_docs/google/cloud/resourcemanager/v3/folders.rb +2 -0
- data/proto_docs/google/cloud/resourcemanager/v3/organizations.rb +2 -1
- data/proto_docs/google/cloud/resourcemanager/v3/projects.rb +2 -0
- metadata +2 -2
@@ -189,6 +189,21 @@ module Google
|
|
189
189
|
#
|
190
190
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
191
191
|
#
|
192
|
+
# @example Basic example
|
193
|
+
# require "google/cloud/resource_manager/v3"
|
194
|
+
#
|
195
|
+
# # Create a client object. The client can be reused for multiple calls.
|
196
|
+
# client = Google::Cloud::ResourceManager::V3::Organizations::Client.new
|
197
|
+
#
|
198
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
199
|
+
# request = Google::Cloud::ResourceManager::V3::GetOrganizationRequest.new
|
200
|
+
#
|
201
|
+
# # Call the get_organization method.
|
202
|
+
# result = client.get_organization request
|
203
|
+
#
|
204
|
+
# # The returned object is of type Google::Cloud::ResourceManager::V3::Organization.
|
205
|
+
# p result
|
206
|
+
#
|
192
207
|
def get_organization request, options = nil
|
193
208
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
194
209
|
|
@@ -206,9 +221,11 @@ module Google
|
|
206
221
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
207
222
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
208
223
|
|
209
|
-
header_params = {
|
210
|
-
|
211
|
-
|
224
|
+
header_params = {}
|
225
|
+
if request.name
|
226
|
+
header_params["name"] = request.name
|
227
|
+
end
|
228
|
+
|
212
229
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
213
230
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
214
231
|
|
@@ -262,12 +279,13 @@ module Google
|
|
262
279
|
# Optional. An optional query string used to filter the Organizations to return in
|
263
280
|
# the response. Query rules are case-insensitive.
|
264
281
|
#
|
265
|
-
#
|
282
|
+
# ```
|
266
283
|
# | Field | Description |
|
267
284
|
# |------------------|--------------------------------------------|
|
268
285
|
# | directoryCustomerId, owner.directoryCustomerId | Filters by directory
|
269
286
|
# customer id. |
|
270
287
|
# | domain | Filters by domain. |
|
288
|
+
# ```
|
271
289
|
#
|
272
290
|
# Organizations may be queried by `directoryCustomerId` or by
|
273
291
|
# `domain`, where the domain is a G Suite domain, for example:
|
@@ -285,6 +303,27 @@ module Google
|
|
285
303
|
#
|
286
304
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
287
305
|
#
|
306
|
+
# @example Basic example
|
307
|
+
# require "google/cloud/resource_manager/v3"
|
308
|
+
#
|
309
|
+
# # Create a client object. The client can be reused for multiple calls.
|
310
|
+
# client = Google::Cloud::ResourceManager::V3::Organizations::Client.new
|
311
|
+
#
|
312
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
313
|
+
# request = Google::Cloud::ResourceManager::V3::SearchOrganizationsRequest.new
|
314
|
+
#
|
315
|
+
# # Call the search_organizations method.
|
316
|
+
# result = client.search_organizations request
|
317
|
+
#
|
318
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
319
|
+
# # iterate over all elements by calling #each, and the enumerable
|
320
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
321
|
+
# # methods are also available for managing paging directly.
|
322
|
+
# result.each do |response|
|
323
|
+
# # Each element is of type ::Google::Cloud::ResourceManager::V3::Organization.
|
324
|
+
# p response
|
325
|
+
# end
|
326
|
+
#
|
288
327
|
def search_organizations request, options = nil
|
289
328
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
290
329
|
|
@@ -357,6 +396,21 @@ module Google
|
|
357
396
|
#
|
358
397
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
359
398
|
#
|
399
|
+
# @example Basic example
|
400
|
+
# require "google/cloud/resource_manager/v3"
|
401
|
+
#
|
402
|
+
# # Create a client object. The client can be reused for multiple calls.
|
403
|
+
# client = Google::Cloud::ResourceManager::V3::Organizations::Client.new
|
404
|
+
#
|
405
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
406
|
+
# request = Google::Iam::V1::GetIamPolicyRequest.new
|
407
|
+
#
|
408
|
+
# # Call the get_iam_policy method.
|
409
|
+
# result = client.get_iam_policy request
|
410
|
+
#
|
411
|
+
# # The returned object is of type Google::Iam::V1::Policy.
|
412
|
+
# p result
|
413
|
+
#
|
360
414
|
def get_iam_policy request, options = nil
|
361
415
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
362
416
|
|
@@ -374,9 +428,11 @@ module Google
|
|
374
428
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
375
429
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
376
430
|
|
377
|
-
header_params = {
|
378
|
-
|
379
|
-
|
431
|
+
header_params = {}
|
432
|
+
if request.resource
|
433
|
+
header_params["resource"] = request.resource
|
434
|
+
end
|
435
|
+
|
380
436
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
381
437
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
382
438
|
|
@@ -436,6 +492,21 @@ module Google
|
|
436
492
|
#
|
437
493
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
438
494
|
#
|
495
|
+
# @example Basic example
|
496
|
+
# require "google/cloud/resource_manager/v3"
|
497
|
+
#
|
498
|
+
# # Create a client object. The client can be reused for multiple calls.
|
499
|
+
# client = Google::Cloud::ResourceManager::V3::Organizations::Client.new
|
500
|
+
#
|
501
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
502
|
+
# request = Google::Iam::V1::SetIamPolicyRequest.new
|
503
|
+
#
|
504
|
+
# # Call the set_iam_policy method.
|
505
|
+
# result = client.set_iam_policy request
|
506
|
+
#
|
507
|
+
# # The returned object is of type Google::Iam::V1::Policy.
|
508
|
+
# p result
|
509
|
+
#
|
439
510
|
def set_iam_policy request, options = nil
|
440
511
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
441
512
|
|
@@ -453,9 +524,11 @@ module Google
|
|
453
524
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
454
525
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
455
526
|
|
456
|
-
header_params = {
|
457
|
-
|
458
|
-
|
527
|
+
header_params = {}
|
528
|
+
if request.resource
|
529
|
+
header_params["resource"] = request.resource
|
530
|
+
end
|
531
|
+
|
459
532
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
460
533
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
461
534
|
|
@@ -514,6 +587,21 @@ module Google
|
|
514
587
|
#
|
515
588
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
516
589
|
#
|
590
|
+
# @example Basic example
|
591
|
+
# require "google/cloud/resource_manager/v3"
|
592
|
+
#
|
593
|
+
# # Create a client object. The client can be reused for multiple calls.
|
594
|
+
# client = Google::Cloud::ResourceManager::V3::Organizations::Client.new
|
595
|
+
#
|
596
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
597
|
+
# request = Google::Iam::V1::TestIamPermissionsRequest.new
|
598
|
+
#
|
599
|
+
# # Call the test_iam_permissions method.
|
600
|
+
# result = client.test_iam_permissions request
|
601
|
+
#
|
602
|
+
# # The returned object is of type Google::Iam::V1::TestIamPermissionsResponse.
|
603
|
+
# p result
|
604
|
+
#
|
517
605
|
def test_iam_permissions request, options = nil
|
518
606
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
519
607
|
|
@@ -531,9 +619,11 @@ module Google
|
|
531
619
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
532
620
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
533
621
|
|
534
|
-
header_params = {
|
535
|
-
|
536
|
-
|
622
|
+
header_params = {}
|
623
|
+
if request.resource
|
624
|
+
header_params["resource"] = request.resource
|
625
|
+
end
|
626
|
+
|
537
627
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
538
628
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
539
629
|
|
@@ -218,6 +218,21 @@ module Google
|
|
218
218
|
#
|
219
219
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
220
220
|
#
|
221
|
+
# @example Basic example
|
222
|
+
# require "google/cloud/resource_manager/v3"
|
223
|
+
#
|
224
|
+
# # Create a client object. The client can be reused for multiple calls.
|
225
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
226
|
+
#
|
227
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
228
|
+
# request = Google::Cloud::ResourceManager::V3::GetProjectRequest.new
|
229
|
+
#
|
230
|
+
# # Call the get_project method.
|
231
|
+
# result = client.get_project request
|
232
|
+
#
|
233
|
+
# # The returned object is of type Google::Cloud::ResourceManager::V3::Project.
|
234
|
+
# p result
|
235
|
+
#
|
221
236
|
def get_project request, options = nil
|
222
237
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
223
238
|
|
@@ -235,9 +250,11 @@ module Google
|
|
235
250
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
236
251
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
237
252
|
|
238
|
-
header_params = {
|
239
|
-
|
240
|
-
|
253
|
+
header_params = {}
|
254
|
+
if request.name
|
255
|
+
header_params["name"] = request.name
|
256
|
+
end
|
257
|
+
|
241
258
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
242
259
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
243
260
|
|
@@ -305,6 +322,27 @@ module Google
|
|
305
322
|
#
|
306
323
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
307
324
|
#
|
325
|
+
# @example Basic example
|
326
|
+
# require "google/cloud/resource_manager/v3"
|
327
|
+
#
|
328
|
+
# # Create a client object. The client can be reused for multiple calls.
|
329
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
330
|
+
#
|
331
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
332
|
+
# request = Google::Cloud::ResourceManager::V3::ListProjectsRequest.new
|
333
|
+
#
|
334
|
+
# # Call the list_projects method.
|
335
|
+
# result = client.list_projects request
|
336
|
+
#
|
337
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
338
|
+
# # iterate over all elements by calling #each, and the enumerable
|
339
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
340
|
+
# # methods are also available for managing paging directly.
|
341
|
+
# result.each do |response|
|
342
|
+
# # Each element is of type ::Google::Cloud::ResourceManager::V3::Project.
|
343
|
+
# p response
|
344
|
+
# end
|
345
|
+
#
|
308
346
|
def list_projects request, options = nil
|
309
347
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
310
348
|
|
@@ -372,6 +410,7 @@ module Google
|
|
372
410
|
# included in the query, the it will return results that match any of the
|
373
411
|
# fields. Some eligible fields are:
|
374
412
|
#
|
413
|
+
# ```
|
375
414
|
# | Field | Description |
|
376
415
|
# |-------------------------|----------------------------------------------|
|
377
416
|
# | displayName, name | Filters by displayName. |
|
@@ -384,6 +423,7 @@ module Google
|
|
384
423
|
# | labels | Filters by label name or value. |
|
385
424
|
# | labels.<key> (where *key* is the name of a label) | Filters by label
|
386
425
|
# name. |
|
426
|
+
# ```
|
387
427
|
#
|
388
428
|
# Search expressions are case insensitive.
|
389
429
|
#
|
@@ -419,6 +459,27 @@ module Google
|
|
419
459
|
#
|
420
460
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
421
461
|
#
|
462
|
+
# @example Basic example
|
463
|
+
# require "google/cloud/resource_manager/v3"
|
464
|
+
#
|
465
|
+
# # Create a client object. The client can be reused for multiple calls.
|
466
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
467
|
+
#
|
468
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
469
|
+
# request = Google::Cloud::ResourceManager::V3::SearchProjectsRequest.new
|
470
|
+
#
|
471
|
+
# # Call the search_projects method.
|
472
|
+
# result = client.search_projects request
|
473
|
+
#
|
474
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
475
|
+
# # iterate over all elements by calling #each, and the enumerable
|
476
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
477
|
+
# # methods are also available for managing paging directly.
|
478
|
+
# result.each do |response|
|
479
|
+
# # Each element is of type ::Google::Cloud::ResourceManager::V3::Project.
|
480
|
+
# p response
|
481
|
+
# end
|
482
|
+
#
|
422
483
|
def search_projects request, options = nil
|
423
484
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
424
485
|
|
@@ -494,6 +555,28 @@ module Google
|
|
494
555
|
#
|
495
556
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
496
557
|
#
|
558
|
+
# @example Basic example
|
559
|
+
# require "google/cloud/resource_manager/v3"
|
560
|
+
#
|
561
|
+
# # Create a client object. The client can be reused for multiple calls.
|
562
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
563
|
+
#
|
564
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
565
|
+
# request = Google::Cloud::ResourceManager::V3::CreateProjectRequest.new
|
566
|
+
#
|
567
|
+
# # Call the create_project method.
|
568
|
+
# result = client.create_project request
|
569
|
+
#
|
570
|
+
# # The returned object is of type Gapic::Operation. You can use this
|
571
|
+
# # object to check the status of an operation, cancel it, or wait
|
572
|
+
# # for results. Here is how to block until completion:
|
573
|
+
# result.wait_until_done! timeout: 60
|
574
|
+
# if result.response?
|
575
|
+
# p result.response
|
576
|
+
# else
|
577
|
+
# puts "Error!"
|
578
|
+
# end
|
579
|
+
#
|
497
580
|
def create_project request, options = nil
|
498
581
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
499
582
|
|
@@ -564,6 +647,28 @@ module Google
|
|
564
647
|
#
|
565
648
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
566
649
|
#
|
650
|
+
# @example Basic example
|
651
|
+
# require "google/cloud/resource_manager/v3"
|
652
|
+
#
|
653
|
+
# # Create a client object. The client can be reused for multiple calls.
|
654
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
655
|
+
#
|
656
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
657
|
+
# request = Google::Cloud::ResourceManager::V3::UpdateProjectRequest.new
|
658
|
+
#
|
659
|
+
# # Call the update_project method.
|
660
|
+
# result = client.update_project request
|
661
|
+
#
|
662
|
+
# # The returned object is of type Gapic::Operation. You can use this
|
663
|
+
# # object to check the status of an operation, cancel it, or wait
|
664
|
+
# # for results. Here is how to block until completion:
|
665
|
+
# result.wait_until_done! timeout: 60
|
666
|
+
# if result.response?
|
667
|
+
# p result.response
|
668
|
+
# else
|
669
|
+
# puts "Error!"
|
670
|
+
# end
|
671
|
+
#
|
567
672
|
def update_project request, options = nil
|
568
673
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
569
674
|
|
@@ -581,9 +686,11 @@ module Google
|
|
581
686
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
582
687
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
583
688
|
|
584
|
-
header_params = {
|
585
|
-
|
586
|
-
|
689
|
+
header_params = {}
|
690
|
+
if request.project&.name
|
691
|
+
header_params["project.name"] = request.project.name
|
692
|
+
end
|
693
|
+
|
587
694
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
588
695
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
589
696
|
|
@@ -645,6 +752,28 @@ module Google
|
|
645
752
|
#
|
646
753
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
647
754
|
#
|
755
|
+
# @example Basic example
|
756
|
+
# require "google/cloud/resource_manager/v3"
|
757
|
+
#
|
758
|
+
# # Create a client object. The client can be reused for multiple calls.
|
759
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
760
|
+
#
|
761
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
762
|
+
# request = Google::Cloud::ResourceManager::V3::MoveProjectRequest.new
|
763
|
+
#
|
764
|
+
# # Call the move_project method.
|
765
|
+
# result = client.move_project request
|
766
|
+
#
|
767
|
+
# # The returned object is of type Gapic::Operation. You can use this
|
768
|
+
# # object to check the status of an operation, cancel it, or wait
|
769
|
+
# # for results. Here is how to block until completion:
|
770
|
+
# result.wait_until_done! timeout: 60
|
771
|
+
# if result.response?
|
772
|
+
# p result.response
|
773
|
+
# else
|
774
|
+
# puts "Error!"
|
775
|
+
# end
|
776
|
+
#
|
648
777
|
def move_project request, options = nil
|
649
778
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
650
779
|
|
@@ -662,9 +791,11 @@ module Google
|
|
662
791
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
663
792
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
664
793
|
|
665
|
-
header_params = {
|
666
|
-
|
667
|
-
|
794
|
+
header_params = {}
|
795
|
+
if request.name
|
796
|
+
header_params["name"] = request.name
|
797
|
+
end
|
798
|
+
|
668
799
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
669
800
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
670
801
|
|
@@ -745,6 +876,28 @@ module Google
|
|
745
876
|
#
|
746
877
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
747
878
|
#
|
879
|
+
# @example Basic example
|
880
|
+
# require "google/cloud/resource_manager/v3"
|
881
|
+
#
|
882
|
+
# # Create a client object. The client can be reused for multiple calls.
|
883
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
884
|
+
#
|
885
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
886
|
+
# request = Google::Cloud::ResourceManager::V3::DeleteProjectRequest.new
|
887
|
+
#
|
888
|
+
# # Call the delete_project method.
|
889
|
+
# result = client.delete_project request
|
890
|
+
#
|
891
|
+
# # The returned object is of type Gapic::Operation. You can use this
|
892
|
+
# # object to check the status of an operation, cancel it, or wait
|
893
|
+
# # for results. Here is how to block until completion:
|
894
|
+
# result.wait_until_done! timeout: 60
|
895
|
+
# if result.response?
|
896
|
+
# p result.response
|
897
|
+
# else
|
898
|
+
# puts "Error!"
|
899
|
+
# end
|
900
|
+
#
|
748
901
|
def delete_project request, options = nil
|
749
902
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
750
903
|
|
@@ -762,9 +915,11 @@ module Google
|
|
762
915
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
763
916
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
764
917
|
|
765
|
-
header_params = {
|
766
|
-
|
767
|
-
|
918
|
+
header_params = {}
|
919
|
+
if request.name
|
920
|
+
header_params["name"] = request.name
|
921
|
+
end
|
922
|
+
|
768
923
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
769
924
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
770
925
|
|
@@ -824,6 +979,28 @@ module Google
|
|
824
979
|
#
|
825
980
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
826
981
|
#
|
982
|
+
# @example Basic example
|
983
|
+
# require "google/cloud/resource_manager/v3"
|
984
|
+
#
|
985
|
+
# # Create a client object. The client can be reused for multiple calls.
|
986
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
987
|
+
#
|
988
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
989
|
+
# request = Google::Cloud::ResourceManager::V3::UndeleteProjectRequest.new
|
990
|
+
#
|
991
|
+
# # Call the undelete_project method.
|
992
|
+
# result = client.undelete_project request
|
993
|
+
#
|
994
|
+
# # The returned object is of type Gapic::Operation. You can use this
|
995
|
+
# # object to check the status of an operation, cancel it, or wait
|
996
|
+
# # for results. Here is how to block until completion:
|
997
|
+
# result.wait_until_done! timeout: 60
|
998
|
+
# if result.response?
|
999
|
+
# p result.response
|
1000
|
+
# else
|
1001
|
+
# puts "Error!"
|
1002
|
+
# end
|
1003
|
+
#
|
827
1004
|
def undelete_project request, options = nil
|
828
1005
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
829
1006
|
|
@@ -841,9 +1018,11 @@ module Google
|
|
841
1018
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
842
1019
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
843
1020
|
|
844
|
-
header_params = {
|
845
|
-
|
846
|
-
|
1021
|
+
header_params = {}
|
1022
|
+
if request.name
|
1023
|
+
header_params["name"] = request.name
|
1024
|
+
end
|
1025
|
+
|
847
1026
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
848
1027
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
849
1028
|
|
@@ -898,6 +1077,21 @@ module Google
|
|
898
1077
|
#
|
899
1078
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
900
1079
|
#
|
1080
|
+
# @example Basic example
|
1081
|
+
# require "google/cloud/resource_manager/v3"
|
1082
|
+
#
|
1083
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1084
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
1085
|
+
#
|
1086
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1087
|
+
# request = Google::Iam::V1::GetIamPolicyRequest.new
|
1088
|
+
#
|
1089
|
+
# # Call the get_iam_policy method.
|
1090
|
+
# result = client.get_iam_policy request
|
1091
|
+
#
|
1092
|
+
# # The returned object is of type Google::Iam::V1::Policy.
|
1093
|
+
# p result
|
1094
|
+
#
|
901
1095
|
def get_iam_policy request, options = nil
|
902
1096
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
903
1097
|
|
@@ -915,9 +1109,11 @@ module Google
|
|
915
1109
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
916
1110
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
917
1111
|
|
918
|
-
header_params = {
|
919
|
-
|
920
|
-
|
1112
|
+
header_params = {}
|
1113
|
+
if request.resource
|
1114
|
+
header_params["resource"] = request.resource
|
1115
|
+
end
|
1116
|
+
|
921
1117
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
922
1118
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
923
1119
|
|
@@ -1015,6 +1211,21 @@ module Google
|
|
1015
1211
|
#
|
1016
1212
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1017
1213
|
#
|
1214
|
+
# @example Basic example
|
1215
|
+
# require "google/cloud/resource_manager/v3"
|
1216
|
+
#
|
1217
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1218
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
1219
|
+
#
|
1220
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1221
|
+
# request = Google::Iam::V1::SetIamPolicyRequest.new
|
1222
|
+
#
|
1223
|
+
# # Call the set_iam_policy method.
|
1224
|
+
# result = client.set_iam_policy request
|
1225
|
+
#
|
1226
|
+
# # The returned object is of type Google::Iam::V1::Policy.
|
1227
|
+
# p result
|
1228
|
+
#
|
1018
1229
|
def set_iam_policy request, options = nil
|
1019
1230
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1020
1231
|
|
@@ -1032,9 +1243,11 @@ module Google
|
|
1032
1243
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
1033
1244
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1034
1245
|
|
1035
|
-
header_params = {
|
1036
|
-
|
1037
|
-
|
1246
|
+
header_params = {}
|
1247
|
+
if request.resource
|
1248
|
+
header_params["resource"] = request.resource
|
1249
|
+
end
|
1250
|
+
|
1038
1251
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1039
1252
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1040
1253
|
|
@@ -1089,6 +1302,21 @@ module Google
|
|
1089
1302
|
#
|
1090
1303
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1091
1304
|
#
|
1305
|
+
# @example Basic example
|
1306
|
+
# require "google/cloud/resource_manager/v3"
|
1307
|
+
#
|
1308
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1309
|
+
# client = Google::Cloud::ResourceManager::V3::Projects::Client.new
|
1310
|
+
#
|
1311
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1312
|
+
# request = Google::Iam::V1::TestIamPermissionsRequest.new
|
1313
|
+
#
|
1314
|
+
# # Call the test_iam_permissions method.
|
1315
|
+
# result = client.test_iam_permissions request
|
1316
|
+
#
|
1317
|
+
# # The returned object is of type Google::Iam::V1::TestIamPermissionsResponse.
|
1318
|
+
# p result
|
1319
|
+
#
|
1092
1320
|
def test_iam_permissions request, options = nil
|
1093
1321
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1094
1322
|
|
@@ -1106,9 +1334,11 @@ module Google
|
|
1106
1334
|
gapic_version: ::Google::Cloud::ResourceManager::V3::VERSION
|
1107
1335
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1108
1336
|
|
1109
|
-
header_params = {
|
1110
|
-
|
1111
|
-
|
1337
|
+
header_params = {}
|
1338
|
+
if request.resource
|
1339
|
+
header_params["resource"] = request.resource
|
1340
|
+
end
|
1341
|
+
|
1112
1342
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1113
1343
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1114
1344
|
|