google-cloud-compute-v1 3.5.0 → 3.6.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 (54) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/cloud/compute/v1/backend_buckets/rest/client.rb +375 -0
  3. data/lib/google/cloud/compute/v1/backend_buckets/rest/service_stub.rb +122 -0
  4. data/lib/google/cloud/compute/v1/compute_pb.rb +94 -1
  5. data/lib/google/cloud/compute/v1/disks/rest/client.rb +118 -0
  6. data/lib/google/cloud/compute/v1/disks/rest/service_stub.rb +64 -0
  7. data/lib/google/cloud/compute/v1/instant_snapshot_groups/credentials.rb +52 -0
  8. data/lib/google/cloud/compute/v1/instant_snapshot_groups/rest/client.rb +1145 -0
  9. data/lib/google/cloud/compute/v1/instant_snapshot_groups/rest/service_stub.rb +523 -0
  10. data/lib/google/cloud/compute/v1/instant_snapshot_groups/rest.rb +51 -0
  11. data/lib/google/cloud/compute/v1/instant_snapshot_groups.rb +47 -0
  12. data/lib/google/cloud/compute/v1/region_backend_buckets/credentials.rb +52 -0
  13. data/lib/google/cloud/compute/v1/region_backend_buckets/rest/client.rb +1450 -0
  14. data/lib/google/cloud/compute/v1/region_backend_buckets/rest/service_stub.rb +649 -0
  15. data/lib/google/cloud/compute/v1/region_backend_buckets/rest.rb +51 -0
  16. data/lib/google/cloud/compute/v1/region_backend_buckets.rb +47 -0
  17. data/lib/google/cloud/compute/v1/region_composite_health_checks/rest/client.rb +95 -0
  18. data/lib/google/cloud/compute/v1/region_composite_health_checks/rest/service_stub.rb +63 -0
  19. data/lib/google/cloud/compute/v1/region_disks/rest/client.rb +118 -0
  20. data/lib/google/cloud/compute/v1/region_disks/rest/service_stub.rb +64 -0
  21. data/lib/google/cloud/compute/v1/region_health_sources/rest/client.rb +95 -0
  22. data/lib/google/cloud/compute/v1/region_health_sources/rest/service_stub.rb +63 -0
  23. data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests/credentials.rb +52 -0
  24. data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests/rest/client.rb +1002 -0
  25. data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests/rest/service_stub.rb +400 -0
  26. data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests/rest.rb +51 -0
  27. data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests.rb +47 -0
  28. data/lib/google/cloud/compute/v1/region_instant_snapshot_groups/credentials.rb +52 -0
  29. data/lib/google/cloud/compute/v1/region_instant_snapshot_groups/rest/client.rb +1146 -0
  30. data/lib/google/cloud/compute/v1/region_instant_snapshot_groups/rest/service_stub.rb +523 -0
  31. data/lib/google/cloud/compute/v1/region_instant_snapshot_groups/rest.rb +51 -0
  32. data/lib/google/cloud/compute/v1/region_instant_snapshot_groups.rb +47 -0
  33. data/lib/google/cloud/compute/v1/region_snapshot_settings/credentials.rb +52 -0
  34. data/lib/google/cloud/compute/v1/region_snapshot_settings/rest/client.rb +561 -0
  35. data/lib/google/cloud/compute/v1/region_snapshot_settings/rest/service_stub.rb +206 -0
  36. data/lib/google/cloud/compute/v1/region_snapshot_settings/rest.rb +51 -0
  37. data/lib/google/cloud/compute/v1/region_snapshot_settings.rb +47 -0
  38. data/lib/google/cloud/compute/v1/region_snapshots/credentials.rb +52 -0
  39. data/lib/google/cloud/compute/v1/region_snapshots/rest/client.rb +1388 -0
  40. data/lib/google/cloud/compute/v1/region_snapshots/rest/service_stub.rb +651 -0
  41. data/lib/google/cloud/compute/v1/region_snapshots/rest.rb +51 -0
  42. data/lib/google/cloud/compute/v1/region_snapshots.rb +47 -0
  43. data/lib/google/cloud/compute/v1/rest.rb +7 -0
  44. data/lib/google/cloud/compute/v1/snapshots/rest/client.rb +115 -0
  45. data/lib/google/cloud/compute/v1/snapshots/rest/service_stub.rb +63 -0
  46. data/lib/google/cloud/compute/v1/version.rb +1 -1
  47. data/lib/google/cloud/compute/v1/zone_vm_extension_policies/credentials.rb +52 -0
  48. data/lib/google/cloud/compute/v1/zone_vm_extension_policies/rest/client.rb +975 -0
  49. data/lib/google/cloud/compute/v1/zone_vm_extension_policies/rest/service_stub.rb +396 -0
  50. data/lib/google/cloud/compute/v1/zone_vm_extension_policies/rest.rb +51 -0
  51. data/lib/google/cloud/compute/v1/zone_vm_extension_policies.rb +47 -0
  52. data/lib/google/cloud/compute/v1.rb +7 -0
  53. data/proto_docs/google/cloud/compute/v1/compute.rb +4753 -1599
  54. metadata +36 -1
@@ -0,0 +1,1450 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2026 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+ require "google/cloud/errors"
20
+ require "google/cloud/compute/v1/compute_pb"
21
+ require "google/cloud/compute/v1/region_backend_buckets/rest/service_stub"
22
+ require "google/cloud/compute/v1/region_operations/rest"
23
+
24
+ module Google
25
+ module Cloud
26
+ module Compute
27
+ module V1
28
+ module RegionBackendBuckets
29
+ module Rest
30
+ ##
31
+ # REST client for the RegionBackendBuckets service.
32
+ #
33
+ # The RegionBackendBuckets API.
34
+ #
35
+ class Client
36
+ # @private
37
+ API_VERSION = ""
38
+
39
+ # @private
40
+ DEFAULT_ENDPOINT_TEMPLATE = "compute.$UNIVERSE_DOMAIN$"
41
+
42
+ # @private
43
+ attr_reader :region_backend_buckets_stub
44
+
45
+ ##
46
+ # Configure the RegionBackendBuckets Client class.
47
+ #
48
+ # See {::Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client::Configuration}
49
+ # for a description of the configuration fields.
50
+ #
51
+ # @example
52
+ #
53
+ # # Modify the configuration for all RegionBackendBuckets clients
54
+ # ::Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.configure do |config|
55
+ # config.timeout = 10.0
56
+ # end
57
+ #
58
+ # @yield [config] Configure the Client client.
59
+ # @yieldparam config [Client::Configuration]
60
+ #
61
+ # @return [Client::Configuration]
62
+ #
63
+ def self.configure
64
+ @configure ||= begin
65
+ namespace = ["Google", "Cloud", "Compute", "V1"]
66
+ parent_config = while namespace.any?
67
+ parent_name = namespace.join "::"
68
+ parent_const = const_get parent_name
69
+ break parent_const.configure if parent_const.respond_to? :configure
70
+ namespace.pop
71
+ end
72
+ default_config = Client::Configuration.new parent_config
73
+
74
+ default_config.rpcs.delete.timeout = 600.0
75
+
76
+ default_config.rpcs.get.timeout = 600.0
77
+ default_config.rpcs.get.retry_policy = {
78
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
79
+ }
80
+
81
+ default_config.rpcs.get_iam_policy.timeout = 600.0
82
+ default_config.rpcs.get_iam_policy.retry_policy = {
83
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
84
+ }
85
+
86
+ default_config.rpcs.insert.timeout = 600.0
87
+
88
+ default_config.rpcs.list.timeout = 600.0
89
+ default_config.rpcs.list.retry_policy = {
90
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
91
+ }
92
+
93
+ default_config.rpcs.list_usable.timeout = 600.0
94
+ default_config.rpcs.list_usable.retry_policy = {
95
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
96
+ }
97
+
98
+ default_config.rpcs.patch.timeout = 600.0
99
+
100
+ default_config.rpcs.set_iam_policy.timeout = 600.0
101
+
102
+ default_config.rpcs.test_iam_permissions.timeout = 600.0
103
+
104
+ default_config
105
+ end
106
+ yield @configure if block_given?
107
+ @configure
108
+ end
109
+
110
+ ##
111
+ # Configure the RegionBackendBuckets Client instance.
112
+ #
113
+ # The configuration is set to the derived mode, meaning that values can be changed,
114
+ # but structural changes (adding new fields, etc.) are not allowed. Structural changes
115
+ # should be made on {Client.configure}.
116
+ #
117
+ # See {::Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client::Configuration}
118
+ # for a description of the configuration fields.
119
+ #
120
+ # @yield [config] Configure the Client client.
121
+ # @yieldparam config [Client::Configuration]
122
+ #
123
+ # @return [Client::Configuration]
124
+ #
125
+ def configure
126
+ yield @config if block_given?
127
+ @config
128
+ end
129
+
130
+ ##
131
+ # The effective universe domain
132
+ #
133
+ # @return [String]
134
+ #
135
+ def universe_domain
136
+ @region_backend_buckets_stub.universe_domain
137
+ end
138
+
139
+ ##
140
+ # Create a new RegionBackendBuckets REST client object.
141
+ #
142
+ # @example
143
+ #
144
+ # # Create a client using the default configuration
145
+ # client = ::Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new
146
+ #
147
+ # # Create a client using a custom configuration
148
+ # client = ::Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new do |config|
149
+ # config.timeout = 10.0
150
+ # end
151
+ #
152
+ # @yield [config] Configure the RegionBackendBuckets client.
153
+ # @yieldparam config [Client::Configuration]
154
+ #
155
+ def initialize
156
+ # Create the configuration object
157
+ @config = Configuration.new Client.configure
158
+
159
+ # Yield the configuration if needed
160
+ yield @config if block_given?
161
+
162
+ # Create credentials
163
+ credentials = @config.credentials
164
+ # Use self-signed JWT if the endpoint is unchanged from default,
165
+ # but only if the default endpoint does not have a region prefix.
166
+ enable_self_signed_jwt = @config.endpoint.nil? ||
167
+ (@config.endpoint == Configuration::DEFAULT_ENDPOINT &&
168
+ !@config.endpoint.split(".").first.include?("-"))
169
+ credentials ||= Credentials.default scope: @config.scope,
170
+ enable_self_signed_jwt: enable_self_signed_jwt
171
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
172
+ credentials = Credentials.new credentials, scope: @config.scope
173
+ end
174
+
175
+ @quota_project_id = @config.quota_project
176
+ @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
177
+
178
+ @region_operations = ::Google::Cloud::Compute::V1::RegionOperations::Rest::Client.new do |config|
179
+ config.credentials = credentials
180
+ config.quota_project = @quota_project_id
181
+ config.endpoint = @config.endpoint
182
+ config.universe_domain = @config.universe_domain
183
+ end
184
+
185
+ @region_backend_buckets_stub = ::Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::ServiceStub.new(
186
+ endpoint: @config.endpoint,
187
+ endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
188
+ universe_domain: @config.universe_domain,
189
+ credentials: credentials,
190
+ logger: @config.logger
191
+ )
192
+
193
+ @region_backend_buckets_stub.logger(stub: true)&.info do |entry|
194
+ entry.set_system_name
195
+ entry.set_service
196
+ entry.message = "Created client for #{entry.service}"
197
+ entry.set_credentials_fields credentials
198
+ entry.set "customEndpoint", @config.endpoint if @config.endpoint
199
+ entry.set "defaultTimeout", @config.timeout if @config.timeout
200
+ entry.set "quotaProject", @quota_project_id if @quota_project_id
201
+ end
202
+ end
203
+
204
+ ##
205
+ # Get the associated client for long-running operations via RegionOperations.
206
+ #
207
+ # @return [::Google::Cloud::Compute::V1::RegionOperations::Rest::Client]
208
+ #
209
+ attr_reader :region_operations
210
+
211
+ ##
212
+ # The logger used for request/response debug logging.
213
+ #
214
+ # @return [Logger]
215
+ #
216
+ def logger
217
+ @region_backend_buckets_stub.logger
218
+ end
219
+
220
+ # Service calls
221
+
222
+ ##
223
+ # Deletes the specified regional BackendBucket resource.
224
+ #
225
+ # @overload delete(request, options = nil)
226
+ # Pass arguments to `delete` via a request object, either of type
227
+ # {::Google::Cloud::Compute::V1::DeleteRegionBackendBucketRequest} or an equivalent Hash.
228
+ #
229
+ # @param request [::Google::Cloud::Compute::V1::DeleteRegionBackendBucketRequest, ::Hash]
230
+ # A request object representing the call parameters. Required. To specify no
231
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
232
+ # @param options [::Gapic::CallOptions, ::Hash]
233
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
234
+ #
235
+ # @overload delete(backend_bucket: nil, project: nil, region: nil, request_id: nil)
236
+ # Pass arguments to `delete` via keyword arguments. Note that at
237
+ # least one keyword argument is required. To specify no parameters, or to keep all
238
+ # the default parameter values, pass an empty Hash as a request object (see above).
239
+ #
240
+ # @param backend_bucket [::String]
241
+ # Name of the BackendBucket resource to delete.
242
+ # @param project [::String]
243
+ # Project ID for this request.
244
+ # @param region [::String]
245
+ # Name of the region scoping this request.
246
+ # @param request_id [::String]
247
+ # An optional request ID to identify requests. Specify a unique request ID so
248
+ # that if you must retry your request, the server will know to ignore the
249
+ # request if it has already been completed.
250
+ #
251
+ # For example, consider a situation where you make an initial request and
252
+ # the request times out. If you make the request again with the same
253
+ # request ID, the server can check if original operation with the same
254
+ # request ID was received, and if so, will ignore the second request. This
255
+ # prevents clients from accidentally creating duplicate commitments.
256
+ #
257
+ # The request ID must be
258
+ # a valid UUID with the exception that zero UUID is not supported
259
+ # (00000000-0000-0000-0000-000000000000).
260
+ # end_interface: MixerMutationRequestBuilder
261
+ # @yield [result, operation] Access the result along with the TransportOperation object
262
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
263
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
264
+ #
265
+ # @return [::Gapic::GenericLRO::Operation]
266
+ #
267
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
268
+ #
269
+ # @example Basic example
270
+ # require "google/cloud/compute/v1"
271
+ #
272
+ # # Create a client object. The client can be reused for multiple calls.
273
+ # client = Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new
274
+ #
275
+ # # Create a request. To set request fields, pass in keyword arguments.
276
+ # request = Google::Cloud::Compute::V1::DeleteRegionBackendBucketRequest.new
277
+ #
278
+ # # Call the delete method.
279
+ # result = client.delete request
280
+ #
281
+ # # The returned object is of type Google::Cloud::Compute::V1::Operation.
282
+ # p result
283
+ #
284
+ def delete request, options = nil
285
+ raise ::ArgumentError, "request must be provided" if request.nil?
286
+
287
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::DeleteRegionBackendBucketRequest
288
+
289
+ # Converts hash and nil to an options object
290
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
291
+
292
+ # Customize the options with defaults
293
+ call_metadata = @config.rpcs.delete.metadata.to_h
294
+
295
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
296
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
297
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
298
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
299
+ transports_version_send: [:rest]
300
+
301
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
302
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
303
+
304
+ options.apply_defaults timeout: @config.rpcs.delete.timeout,
305
+ metadata: call_metadata,
306
+ retry_policy: @config.rpcs.delete.retry_policy
307
+
308
+ options.apply_defaults timeout: @config.timeout,
309
+ metadata: @config.metadata,
310
+ retry_policy: @config.retry_policy
311
+
312
+ @region_backend_buckets_stub.delete request, options do |result, response|
313
+ result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
314
+ operation: result,
315
+ client: region_operations,
316
+ request_values: {
317
+ "project" => request.project,
318
+ "region" => request.region
319
+ },
320
+ options: options
321
+ )
322
+ yield result, response if block_given?
323
+ throw :response, result
324
+ end
325
+ rescue ::Gapic::Rest::Error => e
326
+ raise ::Google::Cloud::Error.from_error(e)
327
+ end
328
+
329
+ ##
330
+ # Returns the specified regional BackendBucket resource.
331
+ #
332
+ # @overload get(request, options = nil)
333
+ # Pass arguments to `get` via a request object, either of type
334
+ # {::Google::Cloud::Compute::V1::GetRegionBackendBucketRequest} or an equivalent Hash.
335
+ #
336
+ # @param request [::Google::Cloud::Compute::V1::GetRegionBackendBucketRequest, ::Hash]
337
+ # A request object representing the call parameters. Required. To specify no
338
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
339
+ # @param options [::Gapic::CallOptions, ::Hash]
340
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
341
+ #
342
+ # @overload get(backend_bucket: nil, project: nil, region: nil)
343
+ # Pass arguments to `get` via keyword arguments. Note that at
344
+ # least one keyword argument is required. To specify no parameters, or to keep all
345
+ # the default parameter values, pass an empty Hash as a request object (see above).
346
+ #
347
+ # @param backend_bucket [::String]
348
+ # Name of the BackendBucket resource to return.
349
+ # @param project [::String]
350
+ # Project ID for this request.
351
+ # @param region [::String]
352
+ # Name of the region scoping this request.
353
+ # @yield [result, operation] Access the result along with the TransportOperation object
354
+ # @yieldparam result [::Google::Cloud::Compute::V1::BackendBucket]
355
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
356
+ #
357
+ # @return [::Google::Cloud::Compute::V1::BackendBucket]
358
+ #
359
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
360
+ #
361
+ # @example Basic example
362
+ # require "google/cloud/compute/v1"
363
+ #
364
+ # # Create a client object. The client can be reused for multiple calls.
365
+ # client = Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new
366
+ #
367
+ # # Create a request. To set request fields, pass in keyword arguments.
368
+ # request = Google::Cloud::Compute::V1::GetRegionBackendBucketRequest.new
369
+ #
370
+ # # Call the get method.
371
+ # result = client.get request
372
+ #
373
+ # # The returned object is of type Google::Cloud::Compute::V1::BackendBucket.
374
+ # p result
375
+ #
376
+ def get request, options = nil
377
+ raise ::ArgumentError, "request must be provided" if request.nil?
378
+
379
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::GetRegionBackendBucketRequest
380
+
381
+ # Converts hash and nil to an options object
382
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
383
+
384
+ # Customize the options with defaults
385
+ call_metadata = @config.rpcs.get.metadata.to_h
386
+
387
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
388
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
389
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
390
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
391
+ transports_version_send: [:rest]
392
+
393
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
394
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
395
+
396
+ options.apply_defaults timeout: @config.rpcs.get.timeout,
397
+ metadata: call_metadata,
398
+ retry_policy: @config.rpcs.get.retry_policy
399
+
400
+ options.apply_defaults timeout: @config.timeout,
401
+ metadata: @config.metadata,
402
+ retry_policy: @config.retry_policy
403
+
404
+ @region_backend_buckets_stub.get request, options do |result, operation|
405
+ yield result, operation if block_given?
406
+ end
407
+ rescue ::Gapic::Rest::Error => e
408
+ raise ::Google::Cloud::Error.from_error(e)
409
+ end
410
+
411
+ ##
412
+ # Gets the access control policy for a resource. May be empty if no such
413
+ # policy or resource exists.
414
+ #
415
+ # @overload get_iam_policy(request, options = nil)
416
+ # Pass arguments to `get_iam_policy` via a request object, either of type
417
+ # {::Google::Cloud::Compute::V1::GetIamPolicyRegionBackendBucketRequest} or an equivalent Hash.
418
+ #
419
+ # @param request [::Google::Cloud::Compute::V1::GetIamPolicyRegionBackendBucketRequest, ::Hash]
420
+ # A request object representing the call parameters. Required. To specify no
421
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
422
+ # @param options [::Gapic::CallOptions, ::Hash]
423
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
424
+ #
425
+ # @overload get_iam_policy(options_requested_policy_version: nil, project: nil, region: nil, resource: nil)
426
+ # Pass arguments to `get_iam_policy` via keyword arguments. Note that at
427
+ # least one keyword argument is required. To specify no parameters, or to keep all
428
+ # the default parameter values, pass an empty Hash as a request object (see above).
429
+ #
430
+ # @param options_requested_policy_version [::Integer]
431
+ # Requested IAM Policy version.
432
+ # @param project [::String]
433
+ # Project ID for this request.
434
+ # @param region [::String]
435
+ # The name of the region for this request.
436
+ # @param resource [::String]
437
+ # Name or id of the resource for this request.
438
+ # @yield [result, operation] Access the result along with the TransportOperation object
439
+ # @yieldparam result [::Google::Cloud::Compute::V1::Policy]
440
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
441
+ #
442
+ # @return [::Google::Cloud::Compute::V1::Policy]
443
+ #
444
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
445
+ #
446
+ # @example Basic example
447
+ # require "google/cloud/compute/v1"
448
+ #
449
+ # # Create a client object. The client can be reused for multiple calls.
450
+ # client = Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new
451
+ #
452
+ # # Create a request. To set request fields, pass in keyword arguments.
453
+ # request = Google::Cloud::Compute::V1::GetIamPolicyRegionBackendBucketRequest.new
454
+ #
455
+ # # Call the get_iam_policy method.
456
+ # result = client.get_iam_policy request
457
+ #
458
+ # # The returned object is of type Google::Cloud::Compute::V1::Policy.
459
+ # p result
460
+ #
461
+ def get_iam_policy request, options = nil
462
+ raise ::ArgumentError, "request must be provided" if request.nil?
463
+
464
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::GetIamPolicyRegionBackendBucketRequest
465
+
466
+ # Converts hash and nil to an options object
467
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
468
+
469
+ # Customize the options with defaults
470
+ call_metadata = @config.rpcs.get_iam_policy.metadata.to_h
471
+
472
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
473
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
474
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
475
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
476
+ transports_version_send: [:rest]
477
+
478
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
479
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
480
+
481
+ options.apply_defaults timeout: @config.rpcs.get_iam_policy.timeout,
482
+ metadata: call_metadata,
483
+ retry_policy: @config.rpcs.get_iam_policy.retry_policy
484
+
485
+ options.apply_defaults timeout: @config.timeout,
486
+ metadata: @config.metadata,
487
+ retry_policy: @config.retry_policy
488
+
489
+ @region_backend_buckets_stub.get_iam_policy request, options do |result, operation|
490
+ yield result, operation if block_given?
491
+ end
492
+ rescue ::Gapic::Rest::Error => e
493
+ raise ::Google::Cloud::Error.from_error(e)
494
+ end
495
+
496
+ ##
497
+ # Creates a RegionBackendBucket in the specified project in the given scope
498
+ # using the parameters that are included in the request.
499
+ #
500
+ # @overload insert(request, options = nil)
501
+ # Pass arguments to `insert` via a request object, either of type
502
+ # {::Google::Cloud::Compute::V1::InsertRegionBackendBucketRequest} or an equivalent Hash.
503
+ #
504
+ # @param request [::Google::Cloud::Compute::V1::InsertRegionBackendBucketRequest, ::Hash]
505
+ # A request object representing the call parameters. Required. To specify no
506
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
507
+ # @param options [::Gapic::CallOptions, ::Hash]
508
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
509
+ #
510
+ # @overload insert(backend_bucket_resource: nil, project: nil, region: nil, request_id: nil)
511
+ # Pass arguments to `insert` via keyword arguments. Note that at
512
+ # least one keyword argument is required. To specify no parameters, or to keep all
513
+ # the default parameter values, pass an empty Hash as a request object (see above).
514
+ #
515
+ # @param backend_bucket_resource [::Google::Cloud::Compute::V1::BackendBucket, ::Hash]
516
+ # The body resource for this request
517
+ # @param project [::String]
518
+ # Project ID for this request.
519
+ # @param region [::String]
520
+ # Name of the region of this request.
521
+ # @param request_id [::String]
522
+ # An optional request ID to identify requests. Specify a unique request ID so
523
+ # that if you must retry your request, the server will know to ignore the
524
+ # request if it has already been completed.
525
+ #
526
+ # For example, consider a situation where you make an initial request and
527
+ # the request times out. If you make the request again with the same
528
+ # request ID, the server can check if original operation with the same
529
+ # request ID was received, and if so, will ignore the second request. This
530
+ # prevents clients from accidentally creating duplicate commitments.
531
+ #
532
+ # The request ID must be
533
+ # a valid UUID with the exception that zero UUID is not supported
534
+ # (00000000-0000-0000-0000-000000000000).
535
+ # @yield [result, operation] Access the result along with the TransportOperation object
536
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
537
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
538
+ #
539
+ # @return [::Gapic::GenericLRO::Operation]
540
+ #
541
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
542
+ #
543
+ # @example Basic example
544
+ # require "google/cloud/compute/v1"
545
+ #
546
+ # # Create a client object. The client can be reused for multiple calls.
547
+ # client = Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new
548
+ #
549
+ # # Create a request. To set request fields, pass in keyword arguments.
550
+ # request = Google::Cloud::Compute::V1::InsertRegionBackendBucketRequest.new
551
+ #
552
+ # # Call the insert method.
553
+ # result = client.insert request
554
+ #
555
+ # # The returned object is of type Google::Cloud::Compute::V1::Operation.
556
+ # p result
557
+ #
558
+ def insert request, options = nil
559
+ raise ::ArgumentError, "request must be provided" if request.nil?
560
+
561
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::InsertRegionBackendBucketRequest
562
+
563
+ # Converts hash and nil to an options object
564
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
565
+
566
+ # Customize the options with defaults
567
+ call_metadata = @config.rpcs.insert.metadata.to_h
568
+
569
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
570
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
571
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
572
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
573
+ transports_version_send: [:rest]
574
+
575
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
576
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
577
+
578
+ options.apply_defaults timeout: @config.rpcs.insert.timeout,
579
+ metadata: call_metadata,
580
+ retry_policy: @config.rpcs.insert.retry_policy
581
+
582
+ options.apply_defaults timeout: @config.timeout,
583
+ metadata: @config.metadata,
584
+ retry_policy: @config.retry_policy
585
+
586
+ @region_backend_buckets_stub.insert request, options do |result, response|
587
+ result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
588
+ operation: result,
589
+ client: region_operations,
590
+ request_values: {
591
+ "project" => request.project,
592
+ "region" => request.region
593
+ },
594
+ options: options
595
+ )
596
+ yield result, response if block_given?
597
+ throw :response, result
598
+ end
599
+ rescue ::Gapic::Rest::Error => e
600
+ raise ::Google::Cloud::Error.from_error(e)
601
+ end
602
+
603
+ ##
604
+ # Retrieves the list of BackendBucket resources available to the specified
605
+ # project in the given region.
606
+ #
607
+ # @overload list(request, options = nil)
608
+ # Pass arguments to `list` via a request object, either of type
609
+ # {::Google::Cloud::Compute::V1::ListRegionBackendBucketsRequest} or an equivalent Hash.
610
+ #
611
+ # @param request [::Google::Cloud::Compute::V1::ListRegionBackendBucketsRequest, ::Hash]
612
+ # A request object representing the call parameters. Required. To specify no
613
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
614
+ # @param options [::Gapic::CallOptions, ::Hash]
615
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
616
+ #
617
+ # @overload list(filter: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, region: nil, return_partial_success: nil)
618
+ # Pass arguments to `list` via keyword arguments. Note that at
619
+ # least one keyword argument is required. To specify no parameters, or to keep all
620
+ # the default parameter values, pass an empty Hash as a request object (see above).
621
+ #
622
+ # @param filter [::String]
623
+ # A filter expression that filters resources listed in the response. Most
624
+ # Compute resources support two types of filter expressions:
625
+ # expressions that support regular expressions and expressions that follow
626
+ # API improvement proposal AIP-160.
627
+ # These two types of filter expressions cannot be mixed in one request.
628
+ #
629
+ # If you want to use AIP-160, your expression must specify the field name, an
630
+ # operator, and the value that you want to use for filtering. The value
631
+ # must be a string, a number, or a boolean. The operator
632
+ # must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`.
633
+ #
634
+ # For example, if you are filtering Compute Engine instances, you can
635
+ # exclude instances named `example-instance` by specifying
636
+ # `name != example-instance`.
637
+ #
638
+ # The `:*` comparison can be used to test whether a key has been defined.
639
+ # For example, to find all objects with `owner` label use:
640
+ # ```
641
+ # labels.owner:*
642
+ # ```
643
+ #
644
+ # You can also filter nested fields. For example, you could specify
645
+ # `scheduling.automaticRestart = false` to include instances only
646
+ # if they are not scheduled for automatic restarts. You can use filtering
647
+ # on nested fields to filter based onresource labels.
648
+ #
649
+ # To filter on multiple expressions, provide each separate expression within
650
+ # parentheses. For example:
651
+ # ```
652
+ # (scheduling.automaticRestart = true)
653
+ # (cpuPlatform = "Intel Skylake")
654
+ # ```
655
+ # By default, each expression is an `AND` expression. However, you
656
+ # can include `AND` and `OR` expressions explicitly.
657
+ # For example:
658
+ # ```
659
+ # (cpuPlatform = "Intel Skylake") OR
660
+ # (cpuPlatform = "Intel Broadwell") AND
661
+ # (scheduling.automaticRestart = true)
662
+ # ```
663
+ #
664
+ # If you want to use a regular expression, use the `eq` (equal) or `ne`
665
+ # (not equal) operator against a single un-parenthesized expression with or
666
+ # without quotes or against multiple parenthesized expressions. Examples:
667
+ #
668
+ # `fieldname eq unquoted literal`
669
+ # `fieldname eq 'single quoted literal'`
670
+ # `fieldname eq "double quoted literal"`
671
+ # `(fieldname1 eq literal) (fieldname2 ne "literal")`
672
+ #
673
+ # The literal value is interpreted as a regular expression using GoogleRE2 library syntax.
674
+ # The literal value must match the entire field.
675
+ #
676
+ # For example, to filter for instances that do not end with name "instance",
677
+ # you would use `name ne .*instance`.
678
+ #
679
+ # You cannot combine constraints on multiple fields using regular
680
+ # expressions.
681
+ # @param max_results [::Integer]
682
+ # The maximum number of results per page that should be returned.
683
+ # If the number of available results is larger than `maxResults`,
684
+ # Compute Engine returns a `nextPageToken` that can be used to get
685
+ # the next page of results in subsequent list requests. Acceptable values are
686
+ # `0` to `500`, inclusive. (Default: `500`)
687
+ # @param order_by [::String]
688
+ # Sorts list results by a certain order. By default, results
689
+ # are returned in alphanumerical order based on the resource name.
690
+ #
691
+ # You can also sort results in descending order based on the creation
692
+ # timestamp using `orderBy="creationTimestamp desc"`. This sorts
693
+ # results based on the `creationTimestamp` field in
694
+ # reverse chronological order (newest result first). Use this to sort
695
+ # resources like operations so that the newest operation is returned first.
696
+ #
697
+ # Currently, only sorting by `name` or
698
+ # `creationTimestamp desc` is supported.
699
+ # @param page_token [::String]
700
+ # Specifies a page token to use. Set `pageToken` to the
701
+ # `nextPageToken` returned by a previous list request to get
702
+ # the next page of results.
703
+ # @param project [::String]
704
+ # Project ID for this request.
705
+ # @param region [::String]
706
+ # Name of the region of this request.
707
+ # @param return_partial_success [::Boolean]
708
+ # Opt-in for partial success behavior which provides partial results in case
709
+ # of failure. The default value is false.
710
+ #
711
+ # For example, when partial success behavior is enabled, aggregatedList for a
712
+ # single zone scope either returns all resources in the zone or no resources,
713
+ # with an error code.
714
+ # @yield [result, operation] Access the result along with the TransportOperation object
715
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Compute::V1::BackendBucket>]
716
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
717
+ #
718
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Compute::V1::BackendBucket>]
719
+ #
720
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
721
+ #
722
+ # @example Basic example
723
+ # require "google/cloud/compute/v1"
724
+ #
725
+ # # Create a client object. The client can be reused for multiple calls.
726
+ # client = Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new
727
+ #
728
+ # # Create a request. To set request fields, pass in keyword arguments.
729
+ # request = Google::Cloud::Compute::V1::ListRegionBackendBucketsRequest.new
730
+ #
731
+ # # Call the list method.
732
+ # result = client.list request
733
+ #
734
+ # # The returned object is of type Google::Cloud::Compute::V1::BackendBucketList.
735
+ # p result
736
+ #
737
+ def list request, options = nil
738
+ raise ::ArgumentError, "request must be provided" if request.nil?
739
+
740
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::ListRegionBackendBucketsRequest
741
+
742
+ # Converts hash and nil to an options object
743
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
744
+
745
+ # Customize the options with defaults
746
+ call_metadata = @config.rpcs.list.metadata.to_h
747
+
748
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
749
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
750
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
751
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
752
+ transports_version_send: [:rest]
753
+
754
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
755
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
756
+
757
+ options.apply_defaults timeout: @config.rpcs.list.timeout,
758
+ metadata: call_metadata,
759
+ retry_policy: @config.rpcs.list.retry_policy
760
+
761
+ options.apply_defaults timeout: @config.timeout,
762
+ metadata: @config.metadata,
763
+ retry_policy: @config.retry_policy
764
+
765
+ @region_backend_buckets_stub.list request, options do |result, operation|
766
+ result = ::Gapic::Rest::PagedEnumerable.new @region_backend_buckets_stub, :list, "items", request, result, options
767
+ yield result, operation if block_given?
768
+ throw :response, result
769
+ end
770
+ rescue ::Gapic::Rest::Error => e
771
+ raise ::Google::Cloud::Error.from_error(e)
772
+ end
773
+
774
+ ##
775
+ # Retrieves a list of all usable backend buckets in the specified project in
776
+ # the given region.
777
+ #
778
+ # @overload list_usable(request, options = nil)
779
+ # Pass arguments to `list_usable` via a request object, either of type
780
+ # {::Google::Cloud::Compute::V1::ListUsableRegionBackendBucketsRequest} or an equivalent Hash.
781
+ #
782
+ # @param request [::Google::Cloud::Compute::V1::ListUsableRegionBackendBucketsRequest, ::Hash]
783
+ # A request object representing the call parameters. Required. To specify no
784
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
785
+ # @param options [::Gapic::CallOptions, ::Hash]
786
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
787
+ #
788
+ # @overload list_usable(filter: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, region: nil, return_partial_success: nil)
789
+ # Pass arguments to `list_usable` via keyword arguments. Note that at
790
+ # least one keyword argument is required. To specify no parameters, or to keep all
791
+ # the default parameter values, pass an empty Hash as a request object (see above).
792
+ #
793
+ # @param filter [::String]
794
+ # A filter expression that filters resources listed in the response. Most
795
+ # Compute resources support two types of filter expressions:
796
+ # expressions that support regular expressions and expressions that follow
797
+ # API improvement proposal AIP-160.
798
+ # These two types of filter expressions cannot be mixed in one request.
799
+ #
800
+ # If you want to use AIP-160, your expression must specify the field name, an
801
+ # operator, and the value that you want to use for filtering. The value
802
+ # must be a string, a number, or a boolean. The operator
803
+ # must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`.
804
+ #
805
+ # For example, if you are filtering Compute Engine instances, you can
806
+ # exclude instances named `example-instance` by specifying
807
+ # `name != example-instance`.
808
+ #
809
+ # The `:*` comparison can be used to test whether a key has been defined.
810
+ # For example, to find all objects with `owner` label use:
811
+ # ```
812
+ # labels.owner:*
813
+ # ```
814
+ #
815
+ # You can also filter nested fields. For example, you could specify
816
+ # `scheduling.automaticRestart = false` to include instances only
817
+ # if they are not scheduled for automatic restarts. You can use filtering
818
+ # on nested fields to filter based onresource labels.
819
+ #
820
+ # To filter on multiple expressions, provide each separate expression within
821
+ # parentheses. For example:
822
+ # ```
823
+ # (scheduling.automaticRestart = true)
824
+ # (cpuPlatform = "Intel Skylake")
825
+ # ```
826
+ # By default, each expression is an `AND` expression. However, you
827
+ # can include `AND` and `OR` expressions explicitly.
828
+ # For example:
829
+ # ```
830
+ # (cpuPlatform = "Intel Skylake") OR
831
+ # (cpuPlatform = "Intel Broadwell") AND
832
+ # (scheduling.automaticRestart = true)
833
+ # ```
834
+ #
835
+ # If you want to use a regular expression, use the `eq` (equal) or `ne`
836
+ # (not equal) operator against a single un-parenthesized expression with or
837
+ # without quotes or against multiple parenthesized expressions. Examples:
838
+ #
839
+ # `fieldname eq unquoted literal`
840
+ # `fieldname eq 'single quoted literal'`
841
+ # `fieldname eq "double quoted literal"`
842
+ # `(fieldname1 eq literal) (fieldname2 ne "literal")`
843
+ #
844
+ # The literal value is interpreted as a regular expression using GoogleRE2 library syntax.
845
+ # The literal value must match the entire field.
846
+ #
847
+ # For example, to filter for instances that do not end with name "instance",
848
+ # you would use `name ne .*instance`.
849
+ #
850
+ # You cannot combine constraints on multiple fields using regular
851
+ # expressions.
852
+ # @param max_results [::Integer]
853
+ # The maximum number of results per page that should be returned.
854
+ # If the number of available results is larger than `maxResults`,
855
+ # Compute Engine returns a `nextPageToken` that can be used to get
856
+ # the next page of results in subsequent list requests. Acceptable values are
857
+ # `0` to `500`, inclusive. (Default: `500`)
858
+ # @param order_by [::String]
859
+ # Sorts list results by a certain order. By default, results
860
+ # are returned in alphanumerical order based on the resource name.
861
+ #
862
+ # You can also sort results in descending order based on the creation
863
+ # timestamp using `orderBy="creationTimestamp desc"`. This sorts
864
+ # results based on the `creationTimestamp` field in
865
+ # reverse chronological order (newest result first). Use this to sort
866
+ # resources like operations so that the newest operation is returned first.
867
+ #
868
+ # Currently, only sorting by `name` or
869
+ # `creationTimestamp desc` is supported.
870
+ # @param page_token [::String]
871
+ # Specifies a page token to use. Set `pageToken` to the
872
+ # `nextPageToken` returned by a previous list request to get
873
+ # the next page of results.
874
+ # @param project [::String]
875
+ # Project ID for this request.
876
+ # @param region [::String]
877
+ # Name of the region scoping this request.
878
+ # It must be a string that meets the requirements in RFC1035.
879
+ # @param return_partial_success [::Boolean]
880
+ # Opt-in for partial success behavior which provides partial results in case
881
+ # of failure. The default value is false.
882
+ #
883
+ # For example, when partial success behavior is enabled, aggregatedList for a
884
+ # single zone scope either returns all resources in the zone or no resources,
885
+ # with an error code.
886
+ # @yield [result, operation] Access the result along with the TransportOperation object
887
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Compute::V1::BackendBucket>]
888
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
889
+ #
890
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Compute::V1::BackendBucket>]
891
+ #
892
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
893
+ #
894
+ # @example Basic example
895
+ # require "google/cloud/compute/v1"
896
+ #
897
+ # # Create a client object. The client can be reused for multiple calls.
898
+ # client = Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new
899
+ #
900
+ # # Create a request. To set request fields, pass in keyword arguments.
901
+ # request = Google::Cloud::Compute::V1::ListUsableRegionBackendBucketsRequest.new
902
+ #
903
+ # # Call the list_usable method.
904
+ # result = client.list_usable request
905
+ #
906
+ # # The returned object is of type Google::Cloud::Compute::V1::BackendBucketListUsable.
907
+ # p result
908
+ #
909
+ def list_usable request, options = nil
910
+ raise ::ArgumentError, "request must be provided" if request.nil?
911
+
912
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::ListUsableRegionBackendBucketsRequest
913
+
914
+ # Converts hash and nil to an options object
915
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
916
+
917
+ # Customize the options with defaults
918
+ call_metadata = @config.rpcs.list_usable.metadata.to_h
919
+
920
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
921
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
922
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
923
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
924
+ transports_version_send: [:rest]
925
+
926
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
927
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
928
+
929
+ options.apply_defaults timeout: @config.rpcs.list_usable.timeout,
930
+ metadata: call_metadata,
931
+ retry_policy: @config.rpcs.list_usable.retry_policy
932
+
933
+ options.apply_defaults timeout: @config.timeout,
934
+ metadata: @config.metadata,
935
+ retry_policy: @config.retry_policy
936
+
937
+ @region_backend_buckets_stub.list_usable request, options do |result, operation|
938
+ result = ::Gapic::Rest::PagedEnumerable.new @region_backend_buckets_stub, :list_usable, "items", request, result, options
939
+ yield result, operation if block_given?
940
+ throw :response, result
941
+ end
942
+ rescue ::Gapic::Rest::Error => e
943
+ raise ::Google::Cloud::Error.from_error(e)
944
+ end
945
+
946
+ ##
947
+ # Updates the specified BackendBucket resource with the data included in the
948
+ # request. This method supportsPATCH
949
+ # semantics and uses theJSON merge
950
+ # patch format and processing rules.
951
+ #
952
+ # @overload patch(request, options = nil)
953
+ # Pass arguments to `patch` via a request object, either of type
954
+ # {::Google::Cloud::Compute::V1::PatchRegionBackendBucketRequest} or an equivalent Hash.
955
+ #
956
+ # @param request [::Google::Cloud::Compute::V1::PatchRegionBackendBucketRequest, ::Hash]
957
+ # A request object representing the call parameters. Required. To specify no
958
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
959
+ # @param options [::Gapic::CallOptions, ::Hash]
960
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
961
+ #
962
+ # @overload patch(backend_bucket: nil, backend_bucket_resource: nil, project: nil, region: nil, request_id: nil)
963
+ # Pass arguments to `patch` via keyword arguments. Note that at
964
+ # least one keyword argument is required. To specify no parameters, or to keep all
965
+ # the default parameter values, pass an empty Hash as a request object (see above).
966
+ #
967
+ # @param backend_bucket [::String]
968
+ # Name of the BackendBucket resource to patch.
969
+ # @param backend_bucket_resource [::Google::Cloud::Compute::V1::BackendBucket, ::Hash]
970
+ # The body resource for this request
971
+ # @param project [::String]
972
+ # Project ID for this request.
973
+ # @param region [::String]
974
+ # Name of the region scoping this request.
975
+ # @param request_id [::String]
976
+ # An optional request ID to identify requests. Specify a unique request ID so
977
+ # that if you must retry your request, the server will know to ignore the
978
+ # request if it has already been completed.
979
+ #
980
+ # For example, consider a situation where you make an initial request and
981
+ # the request times out. If you make the request again with the same
982
+ # request ID, the server can check if original operation with the same
983
+ # request ID was received, and if so, will ignore the second request. This
984
+ # prevents clients from accidentally creating duplicate commitments.
985
+ #
986
+ # The request ID must be
987
+ # a valid UUID with the exception that zero UUID is not supported
988
+ # (00000000-0000-0000-0000-000000000000).
989
+ # end_interface: MixerMutationRequestBuilder
990
+ # @yield [result, operation] Access the result along with the TransportOperation object
991
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
992
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
993
+ #
994
+ # @return [::Gapic::GenericLRO::Operation]
995
+ #
996
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
997
+ #
998
+ # @example Basic example
999
+ # require "google/cloud/compute/v1"
1000
+ #
1001
+ # # Create a client object. The client can be reused for multiple calls.
1002
+ # client = Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new
1003
+ #
1004
+ # # Create a request. To set request fields, pass in keyword arguments.
1005
+ # request = Google::Cloud::Compute::V1::PatchRegionBackendBucketRequest.new
1006
+ #
1007
+ # # Call the patch method.
1008
+ # result = client.patch request
1009
+ #
1010
+ # # The returned object is of type Google::Cloud::Compute::V1::Operation.
1011
+ # p result
1012
+ #
1013
+ def patch request, options = nil
1014
+ raise ::ArgumentError, "request must be provided" if request.nil?
1015
+
1016
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::PatchRegionBackendBucketRequest
1017
+
1018
+ # Converts hash and nil to an options object
1019
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1020
+
1021
+ # Customize the options with defaults
1022
+ call_metadata = @config.rpcs.patch.metadata.to_h
1023
+
1024
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1025
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1026
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1027
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
1028
+ transports_version_send: [:rest]
1029
+
1030
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1031
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1032
+
1033
+ options.apply_defaults timeout: @config.rpcs.patch.timeout,
1034
+ metadata: call_metadata,
1035
+ retry_policy: @config.rpcs.patch.retry_policy
1036
+
1037
+ options.apply_defaults timeout: @config.timeout,
1038
+ metadata: @config.metadata,
1039
+ retry_policy: @config.retry_policy
1040
+
1041
+ @region_backend_buckets_stub.patch request, options do |result, response|
1042
+ result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
1043
+ operation: result,
1044
+ client: region_operations,
1045
+ request_values: {
1046
+ "project" => request.project,
1047
+ "region" => request.region
1048
+ },
1049
+ options: options
1050
+ )
1051
+ yield result, response if block_given?
1052
+ throw :response, result
1053
+ end
1054
+ rescue ::Gapic::Rest::Error => e
1055
+ raise ::Google::Cloud::Error.from_error(e)
1056
+ end
1057
+
1058
+ ##
1059
+ # Sets the access control policy on the specified resource.
1060
+ # Replaces any existing policy.
1061
+ #
1062
+ # @overload set_iam_policy(request, options = nil)
1063
+ # Pass arguments to `set_iam_policy` via a request object, either of type
1064
+ # {::Google::Cloud::Compute::V1::SetIamPolicyRegionBackendBucketRequest} or an equivalent Hash.
1065
+ #
1066
+ # @param request [::Google::Cloud::Compute::V1::SetIamPolicyRegionBackendBucketRequest, ::Hash]
1067
+ # A request object representing the call parameters. Required. To specify no
1068
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1069
+ # @param options [::Gapic::CallOptions, ::Hash]
1070
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1071
+ #
1072
+ # @overload set_iam_policy(project: nil, region: nil, region_set_policy_request_resource: nil, resource: nil)
1073
+ # Pass arguments to `set_iam_policy` via keyword arguments. Note that at
1074
+ # least one keyword argument is required. To specify no parameters, or to keep all
1075
+ # the default parameter values, pass an empty Hash as a request object (see above).
1076
+ #
1077
+ # @param project [::String]
1078
+ # Project ID for this request.
1079
+ # @param region [::String]
1080
+ # The name of the region for this request.
1081
+ # @param region_set_policy_request_resource [::Google::Cloud::Compute::V1::RegionSetPolicyRequest, ::Hash]
1082
+ # The body resource for this request
1083
+ # @param resource [::String]
1084
+ # Name or id of the resource for this request.
1085
+ # @yield [result, operation] Access the result along with the TransportOperation object
1086
+ # @yieldparam result [::Google::Cloud::Compute::V1::Policy]
1087
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1088
+ #
1089
+ # @return [::Google::Cloud::Compute::V1::Policy]
1090
+ #
1091
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1092
+ #
1093
+ # @example Basic example
1094
+ # require "google/cloud/compute/v1"
1095
+ #
1096
+ # # Create a client object. The client can be reused for multiple calls.
1097
+ # client = Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new
1098
+ #
1099
+ # # Create a request. To set request fields, pass in keyword arguments.
1100
+ # request = Google::Cloud::Compute::V1::SetIamPolicyRegionBackendBucketRequest.new
1101
+ #
1102
+ # # Call the set_iam_policy method.
1103
+ # result = client.set_iam_policy request
1104
+ #
1105
+ # # The returned object is of type Google::Cloud::Compute::V1::Policy.
1106
+ # p result
1107
+ #
1108
+ def set_iam_policy request, options = nil
1109
+ raise ::ArgumentError, "request must be provided" if request.nil?
1110
+
1111
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::SetIamPolicyRegionBackendBucketRequest
1112
+
1113
+ # Converts hash and nil to an options object
1114
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1115
+
1116
+ # Customize the options with defaults
1117
+ call_metadata = @config.rpcs.set_iam_policy.metadata.to_h
1118
+
1119
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1120
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1121
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1122
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
1123
+ transports_version_send: [:rest]
1124
+
1125
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1126
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1127
+
1128
+ options.apply_defaults timeout: @config.rpcs.set_iam_policy.timeout,
1129
+ metadata: call_metadata,
1130
+ retry_policy: @config.rpcs.set_iam_policy.retry_policy
1131
+
1132
+ options.apply_defaults timeout: @config.timeout,
1133
+ metadata: @config.metadata,
1134
+ retry_policy: @config.retry_policy
1135
+
1136
+ @region_backend_buckets_stub.set_iam_policy request, options do |result, operation|
1137
+ yield result, operation if block_given?
1138
+ end
1139
+ rescue ::Gapic::Rest::Error => e
1140
+ raise ::Google::Cloud::Error.from_error(e)
1141
+ end
1142
+
1143
+ ##
1144
+ # Returns permissions that a caller has on the specified resource.
1145
+ #
1146
+ # @overload test_iam_permissions(request, options = nil)
1147
+ # Pass arguments to `test_iam_permissions` via a request object, either of type
1148
+ # {::Google::Cloud::Compute::V1::TestIamPermissionsRegionBackendBucketRequest} or an equivalent Hash.
1149
+ #
1150
+ # @param request [::Google::Cloud::Compute::V1::TestIamPermissionsRegionBackendBucketRequest, ::Hash]
1151
+ # A request object representing the call parameters. Required. To specify no
1152
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1153
+ # @param options [::Gapic::CallOptions, ::Hash]
1154
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1155
+ #
1156
+ # @overload test_iam_permissions(project: nil, region: nil, resource: nil, test_permissions_request_resource: nil)
1157
+ # Pass arguments to `test_iam_permissions` via keyword arguments. Note that at
1158
+ # least one keyword argument is required. To specify no parameters, or to keep all
1159
+ # the default parameter values, pass an empty Hash as a request object (see above).
1160
+ #
1161
+ # @param project [::String]
1162
+ # Project ID for this request.
1163
+ # @param region [::String]
1164
+ # The name of the region for this request.
1165
+ # @param resource [::String]
1166
+ # Name or id of the resource for this request.
1167
+ # @param test_permissions_request_resource [::Google::Cloud::Compute::V1::TestPermissionsRequest, ::Hash]
1168
+ # The body resource for this request
1169
+ # @yield [result, operation] Access the result along with the TransportOperation object
1170
+ # @yieldparam result [::Google::Cloud::Compute::V1::TestPermissionsResponse]
1171
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1172
+ #
1173
+ # @return [::Google::Cloud::Compute::V1::TestPermissionsResponse]
1174
+ #
1175
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1176
+ #
1177
+ # @example Basic example
1178
+ # require "google/cloud/compute/v1"
1179
+ #
1180
+ # # Create a client object. The client can be reused for multiple calls.
1181
+ # client = Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new
1182
+ #
1183
+ # # Create a request. To set request fields, pass in keyword arguments.
1184
+ # request = Google::Cloud::Compute::V1::TestIamPermissionsRegionBackendBucketRequest.new
1185
+ #
1186
+ # # Call the test_iam_permissions method.
1187
+ # result = client.test_iam_permissions request
1188
+ #
1189
+ # # The returned object is of type Google::Cloud::Compute::V1::TestPermissionsResponse.
1190
+ # p result
1191
+ #
1192
+ def test_iam_permissions request, options = nil
1193
+ raise ::ArgumentError, "request must be provided" if request.nil?
1194
+
1195
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::TestIamPermissionsRegionBackendBucketRequest
1196
+
1197
+ # Converts hash and nil to an options object
1198
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1199
+
1200
+ # Customize the options with defaults
1201
+ call_metadata = @config.rpcs.test_iam_permissions.metadata.to_h
1202
+
1203
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1204
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1205
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1206
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
1207
+ transports_version_send: [:rest]
1208
+
1209
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1210
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1211
+
1212
+ options.apply_defaults timeout: @config.rpcs.test_iam_permissions.timeout,
1213
+ metadata: call_metadata,
1214
+ retry_policy: @config.rpcs.test_iam_permissions.retry_policy
1215
+
1216
+ options.apply_defaults timeout: @config.timeout,
1217
+ metadata: @config.metadata,
1218
+ retry_policy: @config.retry_policy
1219
+
1220
+ @region_backend_buckets_stub.test_iam_permissions request, options do |result, operation|
1221
+ yield result, operation if block_given?
1222
+ end
1223
+ rescue ::Gapic::Rest::Error => e
1224
+ raise ::Google::Cloud::Error.from_error(e)
1225
+ end
1226
+
1227
+ ##
1228
+ # Configuration class for the RegionBackendBuckets REST API.
1229
+ #
1230
+ # This class represents the configuration for RegionBackendBuckets REST,
1231
+ # providing control over timeouts, retry behavior, logging, transport
1232
+ # parameters, and other low-level controls. Certain parameters can also be
1233
+ # applied individually to specific RPCs. See
1234
+ # {::Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client::Configuration::Rpcs}
1235
+ # for a list of RPCs that can be configured independently.
1236
+ #
1237
+ # Configuration can be applied globally to all clients, or to a single client
1238
+ # on construction.
1239
+ #
1240
+ # @example
1241
+ #
1242
+ # # Modify the global config, setting the timeout for
1243
+ # # delete to 20 seconds,
1244
+ # # and all remaining timeouts to 10 seconds.
1245
+ # ::Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.configure do |config|
1246
+ # config.timeout = 10.0
1247
+ # config.rpcs.delete.timeout = 20.0
1248
+ # end
1249
+ #
1250
+ # # Apply the above configuration only to a new client.
1251
+ # client = ::Google::Cloud::Compute::V1::RegionBackendBuckets::Rest::Client.new do |config|
1252
+ # config.timeout = 10.0
1253
+ # config.rpcs.delete.timeout = 20.0
1254
+ # end
1255
+ #
1256
+ # @!attribute [rw] endpoint
1257
+ # A custom service endpoint, as a hostname or hostname:port. The default is
1258
+ # nil, indicating to use the default endpoint in the current universe domain.
1259
+ # @return [::String,nil]
1260
+ # @!attribute [rw] credentials
1261
+ # Credentials to send with calls. You may provide any of the following types:
1262
+ # * (`String`) The path to a service account key file in JSON format
1263
+ # * (`Hash`) A service account key as a Hash
1264
+ # * (`Google::Auth::Credentials`) A googleauth credentials object
1265
+ # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
1266
+ # * (`Signet::OAuth2::Client`) A signet oauth2 client object
1267
+ # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
1268
+ # * (`nil`) indicating no credentials
1269
+ #
1270
+ # Warning: If you accept a credential configuration (JSON file or Hash) from an
1271
+ # external source for authentication to Google Cloud, you must validate it before
1272
+ # providing it to a Google API client library. Providing an unvalidated credential
1273
+ # configuration to Google APIs can compromise the security of your systems and data.
1274
+ # For more information, refer to [Validate credential configurations from external
1275
+ # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials).
1276
+ # @return [::Object]
1277
+ # @!attribute [rw] scope
1278
+ # The OAuth scopes
1279
+ # @return [::Array<::String>]
1280
+ # @!attribute [rw] lib_name
1281
+ # The library name as recorded in instrumentation and logging
1282
+ # @return [::String]
1283
+ # @!attribute [rw] lib_version
1284
+ # The library version as recorded in instrumentation and logging
1285
+ # @return [::String]
1286
+ # @!attribute [rw] timeout
1287
+ # The call timeout in seconds.
1288
+ # @return [::Numeric]
1289
+ # @!attribute [rw] metadata
1290
+ # Additional headers to be sent with the call.
1291
+ # @return [::Hash{::Symbol=>::String}]
1292
+ # @!attribute [rw] retry_policy
1293
+ # The retry policy. The value is a hash with the following keys:
1294
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
1295
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
1296
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
1297
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
1298
+ # trigger a retry.
1299
+ # @return [::Hash]
1300
+ # @!attribute [rw] quota_project
1301
+ # A separate project against which to charge quota.
1302
+ # @return [::String]
1303
+ # @!attribute [rw] universe_domain
1304
+ # The universe domain within which to make requests. This determines the
1305
+ # default endpoint URL. The default value of nil uses the environment
1306
+ # universe (usually the default "googleapis.com" universe).
1307
+ # @return [::String,nil]
1308
+ # @!attribute [rw] logger
1309
+ # A custom logger to use for request/response debug logging, or the value
1310
+ # `:default` (the default) to construct a default logger, or `nil` to
1311
+ # explicitly disable logging.
1312
+ # @return [::Logger,:default,nil]
1313
+ #
1314
+ class Configuration
1315
+ extend ::Gapic::Config
1316
+
1317
+ # @private
1318
+ # The endpoint specific to the default "googleapis.com" universe. Deprecated.
1319
+ DEFAULT_ENDPOINT = "compute.googleapis.com"
1320
+
1321
+ config_attr :endpoint, nil, ::String, nil
1322
+ config_attr :credentials, nil do |value|
1323
+ allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Google::Auth::BaseClient, ::Signet::OAuth2::Client, nil]
1324
+ allowed.any? { |klass| klass === value }
1325
+ end
1326
+ config_attr :scope, nil, ::String, ::Array, nil
1327
+ config_attr :lib_name, nil, ::String, nil
1328
+ config_attr :lib_version, nil, ::String, nil
1329
+ config_attr :timeout, nil, ::Numeric, nil
1330
+ config_attr :metadata, nil, ::Hash, nil
1331
+ config_attr :retry_policy, nil, ::Hash, ::Proc, nil
1332
+ config_attr :quota_project, nil, ::String, nil
1333
+ config_attr :universe_domain, nil, ::String, nil
1334
+ config_attr :logger, :default, ::Logger, nil, :default
1335
+
1336
+ # @private
1337
+ def initialize parent_config = nil
1338
+ @parent_config = parent_config unless parent_config.nil?
1339
+
1340
+ yield self if block_given?
1341
+ end
1342
+
1343
+ ##
1344
+ # Configurations for individual RPCs
1345
+ # @return [Rpcs]
1346
+ #
1347
+ def rpcs
1348
+ @rpcs ||= begin
1349
+ parent_rpcs = nil
1350
+ parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
1351
+ Rpcs.new parent_rpcs
1352
+ end
1353
+ end
1354
+
1355
+ ##
1356
+ # Configuration RPC class for the RegionBackendBuckets API.
1357
+ #
1358
+ # Includes fields providing the configuration for each RPC in this service.
1359
+ # Each configuration object is of type `Gapic::Config::Method` and includes
1360
+ # the following configuration fields:
1361
+ #
1362
+ # * `timeout` (*type:* `Numeric`) - The call timeout in seconds
1363
+ # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers
1364
+ # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
1365
+ # include the following keys:
1366
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
1367
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
1368
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
1369
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
1370
+ # trigger a retry.
1371
+ #
1372
+ class Rpcs
1373
+ ##
1374
+ # RPC-specific configuration for `delete`
1375
+ # @return [::Gapic::Config::Method]
1376
+ #
1377
+ attr_reader :delete
1378
+ ##
1379
+ # RPC-specific configuration for `get`
1380
+ # @return [::Gapic::Config::Method]
1381
+ #
1382
+ attr_reader :get
1383
+ ##
1384
+ # RPC-specific configuration for `get_iam_policy`
1385
+ # @return [::Gapic::Config::Method]
1386
+ #
1387
+ attr_reader :get_iam_policy
1388
+ ##
1389
+ # RPC-specific configuration for `insert`
1390
+ # @return [::Gapic::Config::Method]
1391
+ #
1392
+ attr_reader :insert
1393
+ ##
1394
+ # RPC-specific configuration for `list`
1395
+ # @return [::Gapic::Config::Method]
1396
+ #
1397
+ attr_reader :list
1398
+ ##
1399
+ # RPC-specific configuration for `list_usable`
1400
+ # @return [::Gapic::Config::Method]
1401
+ #
1402
+ attr_reader :list_usable
1403
+ ##
1404
+ # RPC-specific configuration for `patch`
1405
+ # @return [::Gapic::Config::Method]
1406
+ #
1407
+ attr_reader :patch
1408
+ ##
1409
+ # RPC-specific configuration for `set_iam_policy`
1410
+ # @return [::Gapic::Config::Method]
1411
+ #
1412
+ attr_reader :set_iam_policy
1413
+ ##
1414
+ # RPC-specific configuration for `test_iam_permissions`
1415
+ # @return [::Gapic::Config::Method]
1416
+ #
1417
+ attr_reader :test_iam_permissions
1418
+
1419
+ # @private
1420
+ def initialize parent_rpcs = nil
1421
+ delete_config = parent_rpcs.delete if parent_rpcs.respond_to? :delete
1422
+ @delete = ::Gapic::Config::Method.new delete_config
1423
+ get_config = parent_rpcs.get if parent_rpcs.respond_to? :get
1424
+ @get = ::Gapic::Config::Method.new get_config
1425
+ get_iam_policy_config = parent_rpcs.get_iam_policy if parent_rpcs.respond_to? :get_iam_policy
1426
+ @get_iam_policy = ::Gapic::Config::Method.new get_iam_policy_config
1427
+ insert_config = parent_rpcs.insert if parent_rpcs.respond_to? :insert
1428
+ @insert = ::Gapic::Config::Method.new insert_config
1429
+ list_config = parent_rpcs.list if parent_rpcs.respond_to? :list
1430
+ @list = ::Gapic::Config::Method.new list_config
1431
+ list_usable_config = parent_rpcs.list_usable if parent_rpcs.respond_to? :list_usable
1432
+ @list_usable = ::Gapic::Config::Method.new list_usable_config
1433
+ patch_config = parent_rpcs.patch if parent_rpcs.respond_to? :patch
1434
+ @patch = ::Gapic::Config::Method.new patch_config
1435
+ set_iam_policy_config = parent_rpcs.set_iam_policy if parent_rpcs.respond_to? :set_iam_policy
1436
+ @set_iam_policy = ::Gapic::Config::Method.new set_iam_policy_config
1437
+ test_iam_permissions_config = parent_rpcs.test_iam_permissions if parent_rpcs.respond_to? :test_iam_permissions
1438
+ @test_iam_permissions = ::Gapic::Config::Method.new test_iam_permissions_config
1439
+
1440
+ yield self if block_given?
1441
+ end
1442
+ end
1443
+ end
1444
+ end
1445
+ end
1446
+ end
1447
+ end
1448
+ end
1449
+ end
1450
+ end