google-cloud-compute 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,2475 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2022 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 this file early so that the version constant gets defined before
20
+ # requiring "google/cloud". This is because google-cloud-core will load the
21
+ # entrypoint (gem name) file, which in turn re-requires this file (hence
22
+ # causing a require cycle) unless the version constant is already defined.
23
+ require "google/cloud/compute/version"
24
+
25
+ require "googleauth"
26
+ gem "google-cloud-core"
27
+ require "google/cloud" unless defined? ::Google::Cloud.new
28
+ require "google/cloud/config"
29
+
30
+ # Set the default configuration
31
+ ::Google::Cloud.configure.add_config! :compute do |config|
32
+ config.add_field! :endpoint, "compute.googleapis.com", match: ::String
33
+ config.add_field! :credentials, nil, match: [::String, ::Hash, ::Google::Auth::Credentials]
34
+ config.add_field! :scope, nil, match: [::Array, ::String]
35
+ config.add_field! :lib_name, nil, match: ::String
36
+ config.add_field! :lib_version, nil, match: ::String
37
+ config.add_field! :timeout, nil, match: ::Numeric
38
+ config.add_field! :metadata, nil, match: ::Hash
39
+ end
40
+
41
+ module Google
42
+ module Cloud
43
+ module Compute
44
+ ##
45
+ # Create a new client object for AcceleratorTypes.
46
+ #
47
+ # By default, this returns an instance of
48
+ # [Google::Cloud::Compute::V1::AcceleratorTypes::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/AcceleratorTypes/Rest/Client.html)
49
+ # for version V1 of the API.
50
+ # However, you can specify specify a different API version by passing it in the
51
+ # `version` parameter. If the AcceleratorTypes service is
52
+ # supported by that API version, and the corresponding gem is available, the
53
+ # appropriate versioned client will be returned.
54
+ #
55
+ # ## About AcceleratorTypes
56
+ #
57
+ # Services
58
+ #
59
+ # The AcceleratorTypes API.
60
+ #
61
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
62
+ # Defaults to `:v1`.
63
+ # @return [AcceleratorTypes::Rest::Client] A client object for the specified version.
64
+ #
65
+ def self.accelerator_types version: :v1, &block
66
+ require "google/cloud/compute/#{version.to_s.downcase}"
67
+
68
+ package_name = Google::Cloud::Compute
69
+ .constants
70
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
71
+ .first
72
+ package_module = Google::Cloud::Compute.const_get package_name
73
+ package_module.const_get(:AcceleratorTypes).const_get(:Rest).const_get(:Client).new(&block)
74
+ end
75
+
76
+ ##
77
+ # Create a new client object for Addresses.
78
+ #
79
+ # By default, this returns an instance of
80
+ # [Google::Cloud::Compute::V1::Addresses::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Addresses/Rest/Client.html)
81
+ # for version V1 of the API.
82
+ # However, you can specify specify a different API version by passing it in the
83
+ # `version` parameter. If the Addresses service is
84
+ # supported by that API version, and the corresponding gem is available, the
85
+ # appropriate versioned client will be returned.
86
+ #
87
+ # ## About Addresses
88
+ #
89
+ # The Addresses API.
90
+ #
91
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
92
+ # Defaults to `:v1`.
93
+ # @return [Addresses::Rest::Client] A client object for the specified version.
94
+ #
95
+ def self.addresses version: :v1, &block
96
+ require "google/cloud/compute/#{version.to_s.downcase}"
97
+
98
+ package_name = Google::Cloud::Compute
99
+ .constants
100
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
101
+ .first
102
+ package_module = Google::Cloud::Compute.const_get package_name
103
+ package_module.const_get(:Addresses).const_get(:Rest).const_get(:Client).new(&block)
104
+ end
105
+
106
+ ##
107
+ # Create a new client object for Autoscalers.
108
+ #
109
+ # By default, this returns an instance of
110
+ # [Google::Cloud::Compute::V1::Autoscalers::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Autoscalers/Rest/Client.html)
111
+ # for version V1 of the API.
112
+ # However, you can specify specify a different API version by passing it in the
113
+ # `version` parameter. If the Autoscalers service is
114
+ # supported by that API version, and the corresponding gem is available, the
115
+ # appropriate versioned client will be returned.
116
+ #
117
+ # ## About Autoscalers
118
+ #
119
+ # The Autoscalers API.
120
+ #
121
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
122
+ # Defaults to `:v1`.
123
+ # @return [Autoscalers::Rest::Client] A client object for the specified version.
124
+ #
125
+ def self.autoscalers version: :v1, &block
126
+ require "google/cloud/compute/#{version.to_s.downcase}"
127
+
128
+ package_name = Google::Cloud::Compute
129
+ .constants
130
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
131
+ .first
132
+ package_module = Google::Cloud::Compute.const_get package_name
133
+ package_module.const_get(:Autoscalers).const_get(:Rest).const_get(:Client).new(&block)
134
+ end
135
+
136
+ ##
137
+ # Create a new client object for BackendBuckets.
138
+ #
139
+ # By default, this returns an instance of
140
+ # [Google::Cloud::Compute::V1::BackendBuckets::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/BackendBuckets/Rest/Client.html)
141
+ # for version V1 of the API.
142
+ # However, you can specify specify a different API version by passing it in the
143
+ # `version` parameter. If the BackendBuckets service is
144
+ # supported by that API version, and the corresponding gem is available, the
145
+ # appropriate versioned client will be returned.
146
+ #
147
+ # ## About BackendBuckets
148
+ #
149
+ # The BackendBuckets API.
150
+ #
151
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
152
+ # Defaults to `:v1`.
153
+ # @return [BackendBuckets::Rest::Client] A client object for the specified version.
154
+ #
155
+ def self.backend_buckets version: :v1, &block
156
+ require "google/cloud/compute/#{version.to_s.downcase}"
157
+
158
+ package_name = Google::Cloud::Compute
159
+ .constants
160
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
161
+ .first
162
+ package_module = Google::Cloud::Compute.const_get package_name
163
+ package_module.const_get(:BackendBuckets).const_get(:Rest).const_get(:Client).new(&block)
164
+ end
165
+
166
+ ##
167
+ # Create a new client object for BackendServices.
168
+ #
169
+ # By default, this returns an instance of
170
+ # [Google::Cloud::Compute::V1::BackendServices::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/BackendServices/Rest/Client.html)
171
+ # for version V1 of the API.
172
+ # However, you can specify specify a different API version by passing it in the
173
+ # `version` parameter. If the BackendServices service is
174
+ # supported by that API version, and the corresponding gem is available, the
175
+ # appropriate versioned client will be returned.
176
+ #
177
+ # ## About BackendServices
178
+ #
179
+ # The BackendServices API.
180
+ #
181
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
182
+ # Defaults to `:v1`.
183
+ # @return [BackendServices::Rest::Client] A client object for the specified version.
184
+ #
185
+ def self.backend_services version: :v1, &block
186
+ require "google/cloud/compute/#{version.to_s.downcase}"
187
+
188
+ package_name = Google::Cloud::Compute
189
+ .constants
190
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
191
+ .first
192
+ package_module = Google::Cloud::Compute.const_get package_name
193
+ package_module.const_get(:BackendServices).const_get(:Rest).const_get(:Client).new(&block)
194
+ end
195
+
196
+ ##
197
+ # Create a new client object for DiskTypes.
198
+ #
199
+ # By default, this returns an instance of
200
+ # [Google::Cloud::Compute::V1::DiskTypes::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/DiskTypes/Rest/Client.html)
201
+ # for version V1 of the API.
202
+ # However, you can specify specify a different API version by passing it in the
203
+ # `version` parameter. If the DiskTypes service is
204
+ # supported by that API version, and the corresponding gem is available, the
205
+ # appropriate versioned client will be returned.
206
+ #
207
+ # ## About DiskTypes
208
+ #
209
+ # The DiskTypes API.
210
+ #
211
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
212
+ # Defaults to `:v1`.
213
+ # @return [DiskTypes::Rest::Client] A client object for the specified version.
214
+ #
215
+ def self.disk_types version: :v1, &block
216
+ require "google/cloud/compute/#{version.to_s.downcase}"
217
+
218
+ package_name = Google::Cloud::Compute
219
+ .constants
220
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
221
+ .first
222
+ package_module = Google::Cloud::Compute.const_get package_name
223
+ package_module.const_get(:DiskTypes).const_get(:Rest).const_get(:Client).new(&block)
224
+ end
225
+
226
+ ##
227
+ # Create a new client object for Disks.
228
+ #
229
+ # By default, this returns an instance of
230
+ # [Google::Cloud::Compute::V1::Disks::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Disks/Rest/Client.html)
231
+ # for version V1 of the API.
232
+ # However, you can specify specify a different API version by passing it in the
233
+ # `version` parameter. If the Disks service is
234
+ # supported by that API version, and the corresponding gem is available, the
235
+ # appropriate versioned client will be returned.
236
+ #
237
+ # ## About Disks
238
+ #
239
+ # The Disks API.
240
+ #
241
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
242
+ # Defaults to `:v1`.
243
+ # @return [Disks::Rest::Client] A client object for the specified version.
244
+ #
245
+ def self.disks version: :v1, &block
246
+ require "google/cloud/compute/#{version.to_s.downcase}"
247
+
248
+ package_name = Google::Cloud::Compute
249
+ .constants
250
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
251
+ .first
252
+ package_module = Google::Cloud::Compute.const_get package_name
253
+ package_module.const_get(:Disks).const_get(:Rest).const_get(:Client).new(&block)
254
+ end
255
+
256
+ ##
257
+ # Create a new client object for ExternalVpnGateways.
258
+ #
259
+ # By default, this returns an instance of
260
+ # [Google::Cloud::Compute::V1::ExternalVpnGateways::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/ExternalVpnGateways/Rest/Client.html)
261
+ # for version V1 of the API.
262
+ # However, you can specify specify a different API version by passing it in the
263
+ # `version` parameter. If the ExternalVpnGateways service is
264
+ # supported by that API version, and the corresponding gem is available, the
265
+ # appropriate versioned client will be returned.
266
+ #
267
+ # ## About ExternalVpnGateways
268
+ #
269
+ # The ExternalVpnGateways API.
270
+ #
271
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
272
+ # Defaults to `:v1`.
273
+ # @return [ExternalVpnGateways::Rest::Client] A client object for the specified version.
274
+ #
275
+ def self.external_vpn_gateways version: :v1, &block
276
+ require "google/cloud/compute/#{version.to_s.downcase}"
277
+
278
+ package_name = Google::Cloud::Compute
279
+ .constants
280
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
281
+ .first
282
+ package_module = Google::Cloud::Compute.const_get package_name
283
+ package_module.const_get(:ExternalVpnGateways).const_get(:Rest).const_get(:Client).new(&block)
284
+ end
285
+
286
+ ##
287
+ # Create a new client object for FirewallPolicies.
288
+ #
289
+ # By default, this returns an instance of
290
+ # [Google::Cloud::Compute::V1::FirewallPolicies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/FirewallPolicies/Rest/Client.html)
291
+ # for version V1 of the API.
292
+ # However, you can specify specify a different API version by passing it in the
293
+ # `version` parameter. If the FirewallPolicies service is
294
+ # supported by that API version, and the corresponding gem is available, the
295
+ # appropriate versioned client will be returned.
296
+ #
297
+ # ## About FirewallPolicies
298
+ #
299
+ # The FirewallPolicies API.
300
+ #
301
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
302
+ # Defaults to `:v1`.
303
+ # @return [FirewallPolicies::Rest::Client] A client object for the specified version.
304
+ #
305
+ def self.firewall_policies version: :v1, &block
306
+ require "google/cloud/compute/#{version.to_s.downcase}"
307
+
308
+ package_name = Google::Cloud::Compute
309
+ .constants
310
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
311
+ .first
312
+ package_module = Google::Cloud::Compute.const_get package_name
313
+ package_module.const_get(:FirewallPolicies).const_get(:Rest).const_get(:Client).new(&block)
314
+ end
315
+
316
+ ##
317
+ # Create a new client object for Firewalls.
318
+ #
319
+ # By default, this returns an instance of
320
+ # [Google::Cloud::Compute::V1::Firewalls::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Firewalls/Rest/Client.html)
321
+ # for version V1 of the API.
322
+ # However, you can specify specify a different API version by passing it in the
323
+ # `version` parameter. If the Firewalls service is
324
+ # supported by that API version, and the corresponding gem is available, the
325
+ # appropriate versioned client will be returned.
326
+ #
327
+ # ## About Firewalls
328
+ #
329
+ # The Firewalls API.
330
+ #
331
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
332
+ # Defaults to `:v1`.
333
+ # @return [Firewalls::Rest::Client] A client object for the specified version.
334
+ #
335
+ def self.firewalls version: :v1, &block
336
+ require "google/cloud/compute/#{version.to_s.downcase}"
337
+
338
+ package_name = Google::Cloud::Compute
339
+ .constants
340
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
341
+ .first
342
+ package_module = Google::Cloud::Compute.const_get package_name
343
+ package_module.const_get(:Firewalls).const_get(:Rest).const_get(:Client).new(&block)
344
+ end
345
+
346
+ ##
347
+ # Create a new client object for ForwardingRules.
348
+ #
349
+ # By default, this returns an instance of
350
+ # [Google::Cloud::Compute::V1::ForwardingRules::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/ForwardingRules/Rest/Client.html)
351
+ # for version V1 of the API.
352
+ # However, you can specify specify a different API version by passing it in the
353
+ # `version` parameter. If the ForwardingRules service is
354
+ # supported by that API version, and the corresponding gem is available, the
355
+ # appropriate versioned client will be returned.
356
+ #
357
+ # ## About ForwardingRules
358
+ #
359
+ # The ForwardingRules API.
360
+ #
361
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
362
+ # Defaults to `:v1`.
363
+ # @return [ForwardingRules::Rest::Client] A client object for the specified version.
364
+ #
365
+ def self.forwarding_rules version: :v1, &block
366
+ require "google/cloud/compute/#{version.to_s.downcase}"
367
+
368
+ package_name = Google::Cloud::Compute
369
+ .constants
370
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
371
+ .first
372
+ package_module = Google::Cloud::Compute.const_get package_name
373
+ package_module.const_get(:ForwardingRules).const_get(:Rest).const_get(:Client).new(&block)
374
+ end
375
+
376
+ ##
377
+ # Create a new client object for GlobalAddresses.
378
+ #
379
+ # By default, this returns an instance of
380
+ # [Google::Cloud::Compute::V1::GlobalAddresses::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/GlobalAddresses/Rest/Client.html)
381
+ # for version V1 of the API.
382
+ # However, you can specify specify a different API version by passing it in the
383
+ # `version` parameter. If the GlobalAddresses service is
384
+ # supported by that API version, and the corresponding gem is available, the
385
+ # appropriate versioned client will be returned.
386
+ #
387
+ # ## About GlobalAddresses
388
+ #
389
+ # The GlobalAddresses API.
390
+ #
391
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
392
+ # Defaults to `:v1`.
393
+ # @return [GlobalAddresses::Rest::Client] A client object for the specified version.
394
+ #
395
+ def self.global_addresses version: :v1, &block
396
+ require "google/cloud/compute/#{version.to_s.downcase}"
397
+
398
+ package_name = Google::Cloud::Compute
399
+ .constants
400
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
401
+ .first
402
+ package_module = Google::Cloud::Compute.const_get package_name
403
+ package_module.const_get(:GlobalAddresses).const_get(:Rest).const_get(:Client).new(&block)
404
+ end
405
+
406
+ ##
407
+ # Create a new client object for GlobalForwardingRules.
408
+ #
409
+ # By default, this returns an instance of
410
+ # [Google::Cloud::Compute::V1::GlobalForwardingRules::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/GlobalForwardingRules/Rest/Client.html)
411
+ # for version V1 of the API.
412
+ # However, you can specify specify a different API version by passing it in the
413
+ # `version` parameter. If the GlobalForwardingRules service is
414
+ # supported by that API version, and the corresponding gem is available, the
415
+ # appropriate versioned client will be returned.
416
+ #
417
+ # ## About GlobalForwardingRules
418
+ #
419
+ # The GlobalForwardingRules API.
420
+ #
421
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
422
+ # Defaults to `:v1`.
423
+ # @return [GlobalForwardingRules::Rest::Client] A client object for the specified version.
424
+ #
425
+ def self.global_forwarding_rules version: :v1, &block
426
+ require "google/cloud/compute/#{version.to_s.downcase}"
427
+
428
+ package_name = Google::Cloud::Compute
429
+ .constants
430
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
431
+ .first
432
+ package_module = Google::Cloud::Compute.const_get package_name
433
+ package_module.const_get(:GlobalForwardingRules).const_get(:Rest).const_get(:Client).new(&block)
434
+ end
435
+
436
+ ##
437
+ # Create a new client object for GlobalNetworkEndpointGroups.
438
+ #
439
+ # By default, this returns an instance of
440
+ # [Google::Cloud::Compute::V1::GlobalNetworkEndpointGroups::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/GlobalNetworkEndpointGroups/Rest/Client.html)
441
+ # for version V1 of the API.
442
+ # However, you can specify specify a different API version by passing it in the
443
+ # `version` parameter. If the GlobalNetworkEndpointGroups service is
444
+ # supported by that API version, and the corresponding gem is available, the
445
+ # appropriate versioned client will be returned.
446
+ #
447
+ # ## About GlobalNetworkEndpointGroups
448
+ #
449
+ # The GlobalNetworkEndpointGroups API.
450
+ #
451
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
452
+ # Defaults to `:v1`.
453
+ # @return [GlobalNetworkEndpointGroups::Rest::Client] A client object for the specified version.
454
+ #
455
+ def self.global_network_endpoint_groups version: :v1, &block
456
+ require "google/cloud/compute/#{version.to_s.downcase}"
457
+
458
+ package_name = Google::Cloud::Compute
459
+ .constants
460
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
461
+ .first
462
+ package_module = Google::Cloud::Compute.const_get package_name
463
+ package_module.const_get(:GlobalNetworkEndpointGroups).const_get(:Rest).const_get(:Client).new(&block)
464
+ end
465
+
466
+ ##
467
+ # Create a new client object for GlobalOperations.
468
+ #
469
+ # By default, this returns an instance of
470
+ # [Google::Cloud::Compute::V1::GlobalOperations::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/GlobalOperations/Rest/Client.html)
471
+ # for version V1 of the API.
472
+ # However, you can specify specify a different API version by passing it in the
473
+ # `version` parameter. If the GlobalOperations service is
474
+ # supported by that API version, and the corresponding gem is available, the
475
+ # appropriate versioned client will be returned.
476
+ #
477
+ # ## About GlobalOperations
478
+ #
479
+ # The GlobalOperations API.
480
+ #
481
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
482
+ # Defaults to `:v1`.
483
+ # @return [GlobalOperations::Rest::Client] A client object for the specified version.
484
+ #
485
+ def self.global_operations version: :v1, &block
486
+ require "google/cloud/compute/#{version.to_s.downcase}"
487
+
488
+ package_name = Google::Cloud::Compute
489
+ .constants
490
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
491
+ .first
492
+ package_module = Google::Cloud::Compute.const_get package_name
493
+ package_module.const_get(:GlobalOperations).const_get(:Rest).const_get(:Client).new(&block)
494
+ end
495
+
496
+ ##
497
+ # Create a new client object for GlobalOrganizationOperations.
498
+ #
499
+ # By default, this returns an instance of
500
+ # [Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/GlobalOrganizationOperations/Rest/Client.html)
501
+ # for version V1 of the API.
502
+ # However, you can specify specify a different API version by passing it in the
503
+ # `version` parameter. If the GlobalOrganizationOperations service is
504
+ # supported by that API version, and the corresponding gem is available, the
505
+ # appropriate versioned client will be returned.
506
+ #
507
+ # ## About GlobalOrganizationOperations
508
+ #
509
+ # The GlobalOrganizationOperations API.
510
+ #
511
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
512
+ # Defaults to `:v1`.
513
+ # @return [GlobalOrganizationOperations::Rest::Client] A client object for the specified version.
514
+ #
515
+ def self.global_organization_operations version: :v1, &block
516
+ require "google/cloud/compute/#{version.to_s.downcase}"
517
+
518
+ package_name = Google::Cloud::Compute
519
+ .constants
520
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
521
+ .first
522
+ package_module = Google::Cloud::Compute.const_get package_name
523
+ package_module.const_get(:GlobalOrganizationOperations).const_get(:Rest).const_get(:Client).new(&block)
524
+ end
525
+
526
+ ##
527
+ # Create a new client object for GlobalPublicDelegatedPrefixes.
528
+ #
529
+ # By default, this returns an instance of
530
+ # [Google::Cloud::Compute::V1::GlobalPublicDelegatedPrefixes::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/GlobalPublicDelegatedPrefixes/Rest/Client.html)
531
+ # for version V1 of the API.
532
+ # However, you can specify specify a different API version by passing it in the
533
+ # `version` parameter. If the GlobalPublicDelegatedPrefixes service is
534
+ # supported by that API version, and the corresponding gem is available, the
535
+ # appropriate versioned client will be returned.
536
+ #
537
+ # ## About GlobalPublicDelegatedPrefixes
538
+ #
539
+ # The GlobalPublicDelegatedPrefixes API.
540
+ #
541
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
542
+ # Defaults to `:v1`.
543
+ # @return [GlobalPublicDelegatedPrefixes::Rest::Client] A client object for the specified version.
544
+ #
545
+ def self.global_public_delegated_prefixes version: :v1, &block
546
+ require "google/cloud/compute/#{version.to_s.downcase}"
547
+
548
+ package_name = Google::Cloud::Compute
549
+ .constants
550
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
551
+ .first
552
+ package_module = Google::Cloud::Compute.const_get package_name
553
+ package_module.const_get(:GlobalPublicDelegatedPrefixes).const_get(:Rest).const_get(:Client).new(&block)
554
+ end
555
+
556
+ ##
557
+ # Create a new client object for HealthChecks.
558
+ #
559
+ # By default, this returns an instance of
560
+ # [Google::Cloud::Compute::V1::HealthChecks::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/HealthChecks/Rest/Client.html)
561
+ # for version V1 of the API.
562
+ # However, you can specify specify a different API version by passing it in the
563
+ # `version` parameter. If the HealthChecks service is
564
+ # supported by that API version, and the corresponding gem is available, the
565
+ # appropriate versioned client will be returned.
566
+ #
567
+ # ## About HealthChecks
568
+ #
569
+ # The HealthChecks API.
570
+ #
571
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
572
+ # Defaults to `:v1`.
573
+ # @return [HealthChecks::Rest::Client] A client object for the specified version.
574
+ #
575
+ def self.health_checks version: :v1, &block
576
+ require "google/cloud/compute/#{version.to_s.downcase}"
577
+
578
+ package_name = Google::Cloud::Compute
579
+ .constants
580
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
581
+ .first
582
+ package_module = Google::Cloud::Compute.const_get package_name
583
+ package_module.const_get(:HealthChecks).const_get(:Rest).const_get(:Client).new(&block)
584
+ end
585
+
586
+ ##
587
+ # Create a new client object for ImageFamilyViews.
588
+ #
589
+ # By default, this returns an instance of
590
+ # [Google::Cloud::Compute::V1::ImageFamilyViews::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/ImageFamilyViews/Rest/Client.html)
591
+ # for version V1 of the API.
592
+ # However, you can specify specify a different API version by passing it in the
593
+ # `version` parameter. If the ImageFamilyViews service is
594
+ # supported by that API version, and the corresponding gem is available, the
595
+ # appropriate versioned client will be returned.
596
+ #
597
+ # ## About ImageFamilyViews
598
+ #
599
+ # The ImageFamilyViews API.
600
+ #
601
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
602
+ # Defaults to `:v1`.
603
+ # @return [ImageFamilyViews::Rest::Client] A client object for the specified version.
604
+ #
605
+ def self.image_family_views version: :v1, &block
606
+ require "google/cloud/compute/#{version.to_s.downcase}"
607
+
608
+ package_name = Google::Cloud::Compute
609
+ .constants
610
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
611
+ .first
612
+ package_module = Google::Cloud::Compute.const_get package_name
613
+ package_module.const_get(:ImageFamilyViews).const_get(:Rest).const_get(:Client).new(&block)
614
+ end
615
+
616
+ ##
617
+ # Create a new client object for Images.
618
+ #
619
+ # By default, this returns an instance of
620
+ # [Google::Cloud::Compute::V1::Images::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Images/Rest/Client.html)
621
+ # for version V1 of the API.
622
+ # However, you can specify specify a different API version by passing it in the
623
+ # `version` parameter. If the Images service is
624
+ # supported by that API version, and the corresponding gem is available, the
625
+ # appropriate versioned client will be returned.
626
+ #
627
+ # ## About Images
628
+ #
629
+ # The Images API.
630
+ #
631
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
632
+ # Defaults to `:v1`.
633
+ # @return [Images::Rest::Client] A client object for the specified version.
634
+ #
635
+ def self.images version: :v1, &block
636
+ require "google/cloud/compute/#{version.to_s.downcase}"
637
+
638
+ package_name = Google::Cloud::Compute
639
+ .constants
640
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
641
+ .first
642
+ package_module = Google::Cloud::Compute.const_get package_name
643
+ package_module.const_get(:Images).const_get(:Rest).const_get(:Client).new(&block)
644
+ end
645
+
646
+ ##
647
+ # Create a new client object for InstanceGroupManagers.
648
+ #
649
+ # By default, this returns an instance of
650
+ # [Google::Cloud::Compute::V1::InstanceGroupManagers::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/InstanceGroupManagers/Rest/Client.html)
651
+ # for version V1 of the API.
652
+ # However, you can specify specify a different API version by passing it in the
653
+ # `version` parameter. If the InstanceGroupManagers service is
654
+ # supported by that API version, and the corresponding gem is available, the
655
+ # appropriate versioned client will be returned.
656
+ #
657
+ # ## About InstanceGroupManagers
658
+ #
659
+ # The InstanceGroupManagers API.
660
+ #
661
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
662
+ # Defaults to `:v1`.
663
+ # @return [InstanceGroupManagers::Rest::Client] A client object for the specified version.
664
+ #
665
+ def self.instance_group_managers version: :v1, &block
666
+ require "google/cloud/compute/#{version.to_s.downcase}"
667
+
668
+ package_name = Google::Cloud::Compute
669
+ .constants
670
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
671
+ .first
672
+ package_module = Google::Cloud::Compute.const_get package_name
673
+ package_module.const_get(:InstanceGroupManagers).const_get(:Rest).const_get(:Client).new(&block)
674
+ end
675
+
676
+ ##
677
+ # Create a new client object for InstanceGroups.
678
+ #
679
+ # By default, this returns an instance of
680
+ # [Google::Cloud::Compute::V1::InstanceGroups::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/InstanceGroups/Rest/Client.html)
681
+ # for version V1 of the API.
682
+ # However, you can specify specify a different API version by passing it in the
683
+ # `version` parameter. If the InstanceGroups service is
684
+ # supported by that API version, and the corresponding gem is available, the
685
+ # appropriate versioned client will be returned.
686
+ #
687
+ # ## About InstanceGroups
688
+ #
689
+ # The InstanceGroups API.
690
+ #
691
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
692
+ # Defaults to `:v1`.
693
+ # @return [InstanceGroups::Rest::Client] A client object for the specified version.
694
+ #
695
+ def self.instance_groups version: :v1, &block
696
+ require "google/cloud/compute/#{version.to_s.downcase}"
697
+
698
+ package_name = Google::Cloud::Compute
699
+ .constants
700
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
701
+ .first
702
+ package_module = Google::Cloud::Compute.const_get package_name
703
+ package_module.const_get(:InstanceGroups).const_get(:Rest).const_get(:Client).new(&block)
704
+ end
705
+
706
+ ##
707
+ # Create a new client object for InstanceTemplates.
708
+ #
709
+ # By default, this returns an instance of
710
+ # [Google::Cloud::Compute::V1::InstanceTemplates::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/InstanceTemplates/Rest/Client.html)
711
+ # for version V1 of the API.
712
+ # However, you can specify specify a different API version by passing it in the
713
+ # `version` parameter. If the InstanceTemplates service is
714
+ # supported by that API version, and the corresponding gem is available, the
715
+ # appropriate versioned client will be returned.
716
+ #
717
+ # ## About InstanceTemplates
718
+ #
719
+ # The InstanceTemplates API.
720
+ #
721
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
722
+ # Defaults to `:v1`.
723
+ # @return [InstanceTemplates::Rest::Client] A client object for the specified version.
724
+ #
725
+ def self.instance_templates version: :v1, &block
726
+ require "google/cloud/compute/#{version.to_s.downcase}"
727
+
728
+ package_name = Google::Cloud::Compute
729
+ .constants
730
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
731
+ .first
732
+ package_module = Google::Cloud::Compute.const_get package_name
733
+ package_module.const_get(:InstanceTemplates).const_get(:Rest).const_get(:Client).new(&block)
734
+ end
735
+
736
+ ##
737
+ # Create a new client object for Instances.
738
+ #
739
+ # By default, this returns an instance of
740
+ # [Google::Cloud::Compute::V1::Instances::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Instances/Rest/Client.html)
741
+ # for version V1 of the API.
742
+ # However, you can specify specify a different API version by passing it in the
743
+ # `version` parameter. If the Instances service is
744
+ # supported by that API version, and the corresponding gem is available, the
745
+ # appropriate versioned client will be returned.
746
+ #
747
+ # ## About Instances
748
+ #
749
+ # The Instances API.
750
+ #
751
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
752
+ # Defaults to `:v1`.
753
+ # @return [Instances::Rest::Client] A client object for the specified version.
754
+ #
755
+ def self.instances version: :v1, &block
756
+ require "google/cloud/compute/#{version.to_s.downcase}"
757
+
758
+ package_name = Google::Cloud::Compute
759
+ .constants
760
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
761
+ .first
762
+ package_module = Google::Cloud::Compute.const_get package_name
763
+ package_module.const_get(:Instances).const_get(:Rest).const_get(:Client).new(&block)
764
+ end
765
+
766
+ ##
767
+ # Create a new client object for InterconnectAttachments.
768
+ #
769
+ # By default, this returns an instance of
770
+ # [Google::Cloud::Compute::V1::InterconnectAttachments::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/InterconnectAttachments/Rest/Client.html)
771
+ # for version V1 of the API.
772
+ # However, you can specify specify a different API version by passing it in the
773
+ # `version` parameter. If the InterconnectAttachments service is
774
+ # supported by that API version, and the corresponding gem is available, the
775
+ # appropriate versioned client will be returned.
776
+ #
777
+ # ## About InterconnectAttachments
778
+ #
779
+ # The InterconnectAttachments API.
780
+ #
781
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
782
+ # Defaults to `:v1`.
783
+ # @return [InterconnectAttachments::Rest::Client] A client object for the specified version.
784
+ #
785
+ def self.interconnect_attachments version: :v1, &block
786
+ require "google/cloud/compute/#{version.to_s.downcase}"
787
+
788
+ package_name = Google::Cloud::Compute
789
+ .constants
790
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
791
+ .first
792
+ package_module = Google::Cloud::Compute.const_get package_name
793
+ package_module.const_get(:InterconnectAttachments).const_get(:Rest).const_get(:Client).new(&block)
794
+ end
795
+
796
+ ##
797
+ # Create a new client object for InterconnectLocations.
798
+ #
799
+ # By default, this returns an instance of
800
+ # [Google::Cloud::Compute::V1::InterconnectLocations::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/InterconnectLocations/Rest/Client.html)
801
+ # for version V1 of the API.
802
+ # However, you can specify specify a different API version by passing it in the
803
+ # `version` parameter. If the InterconnectLocations service is
804
+ # supported by that API version, and the corresponding gem is available, the
805
+ # appropriate versioned client will be returned.
806
+ #
807
+ # ## About InterconnectLocations
808
+ #
809
+ # The InterconnectLocations API.
810
+ #
811
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
812
+ # Defaults to `:v1`.
813
+ # @return [InterconnectLocations::Rest::Client] A client object for the specified version.
814
+ #
815
+ def self.interconnect_locations version: :v1, &block
816
+ require "google/cloud/compute/#{version.to_s.downcase}"
817
+
818
+ package_name = Google::Cloud::Compute
819
+ .constants
820
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
821
+ .first
822
+ package_module = Google::Cloud::Compute.const_get package_name
823
+ package_module.const_get(:InterconnectLocations).const_get(:Rest).const_get(:Client).new(&block)
824
+ end
825
+
826
+ ##
827
+ # Create a new client object for Interconnects.
828
+ #
829
+ # By default, this returns an instance of
830
+ # [Google::Cloud::Compute::V1::Interconnects::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Interconnects/Rest/Client.html)
831
+ # for version V1 of the API.
832
+ # However, you can specify specify a different API version by passing it in the
833
+ # `version` parameter. If the Interconnects service is
834
+ # supported by that API version, and the corresponding gem is available, the
835
+ # appropriate versioned client will be returned.
836
+ #
837
+ # ## About Interconnects
838
+ #
839
+ # The Interconnects API.
840
+ #
841
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
842
+ # Defaults to `:v1`.
843
+ # @return [Interconnects::Rest::Client] A client object for the specified version.
844
+ #
845
+ def self.interconnects version: :v1, &block
846
+ require "google/cloud/compute/#{version.to_s.downcase}"
847
+
848
+ package_name = Google::Cloud::Compute
849
+ .constants
850
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
851
+ .first
852
+ package_module = Google::Cloud::Compute.const_get package_name
853
+ package_module.const_get(:Interconnects).const_get(:Rest).const_get(:Client).new(&block)
854
+ end
855
+
856
+ ##
857
+ # Create a new client object for LicenseCodes.
858
+ #
859
+ # By default, this returns an instance of
860
+ # [Google::Cloud::Compute::V1::LicenseCodes::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/LicenseCodes/Rest/Client.html)
861
+ # for version V1 of the API.
862
+ # However, you can specify specify a different API version by passing it in the
863
+ # `version` parameter. If the LicenseCodes service is
864
+ # supported by that API version, and the corresponding gem is available, the
865
+ # appropriate versioned client will be returned.
866
+ #
867
+ # ## About LicenseCodes
868
+ #
869
+ # The LicenseCodes API.
870
+ #
871
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
872
+ # Defaults to `:v1`.
873
+ # @return [LicenseCodes::Rest::Client] A client object for the specified version.
874
+ #
875
+ def self.license_codes version: :v1, &block
876
+ require "google/cloud/compute/#{version.to_s.downcase}"
877
+
878
+ package_name = Google::Cloud::Compute
879
+ .constants
880
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
881
+ .first
882
+ package_module = Google::Cloud::Compute.const_get package_name
883
+ package_module.const_get(:LicenseCodes).const_get(:Rest).const_get(:Client).new(&block)
884
+ end
885
+
886
+ ##
887
+ # Create a new client object for Licenses.
888
+ #
889
+ # By default, this returns an instance of
890
+ # [Google::Cloud::Compute::V1::Licenses::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Licenses/Rest/Client.html)
891
+ # for version V1 of the API.
892
+ # However, you can specify specify a different API version by passing it in the
893
+ # `version` parameter. If the Licenses service is
894
+ # supported by that API version, and the corresponding gem is available, the
895
+ # appropriate versioned client will be returned.
896
+ #
897
+ # ## About Licenses
898
+ #
899
+ # The Licenses API.
900
+ #
901
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
902
+ # Defaults to `:v1`.
903
+ # @return [Licenses::Rest::Client] A client object for the specified version.
904
+ #
905
+ def self.licenses version: :v1, &block
906
+ require "google/cloud/compute/#{version.to_s.downcase}"
907
+
908
+ package_name = Google::Cloud::Compute
909
+ .constants
910
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
911
+ .first
912
+ package_module = Google::Cloud::Compute.const_get package_name
913
+ package_module.const_get(:Licenses).const_get(:Rest).const_get(:Client).new(&block)
914
+ end
915
+
916
+ ##
917
+ # Create a new client object for MachineTypes.
918
+ #
919
+ # By default, this returns an instance of
920
+ # [Google::Cloud::Compute::V1::MachineTypes::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/MachineTypes/Rest/Client.html)
921
+ # for version V1 of the API.
922
+ # However, you can specify specify a different API version by passing it in the
923
+ # `version` parameter. If the MachineTypes service is
924
+ # supported by that API version, and the corresponding gem is available, the
925
+ # appropriate versioned client will be returned.
926
+ #
927
+ # ## About MachineTypes
928
+ #
929
+ # The MachineTypes API.
930
+ #
931
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
932
+ # Defaults to `:v1`.
933
+ # @return [MachineTypes::Rest::Client] A client object for the specified version.
934
+ #
935
+ def self.machine_types version: :v1, &block
936
+ require "google/cloud/compute/#{version.to_s.downcase}"
937
+
938
+ package_name = Google::Cloud::Compute
939
+ .constants
940
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
941
+ .first
942
+ package_module = Google::Cloud::Compute.const_get package_name
943
+ package_module.const_get(:MachineTypes).const_get(:Rest).const_get(:Client).new(&block)
944
+ end
945
+
946
+ ##
947
+ # Create a new client object for NetworkEndpointGroups.
948
+ #
949
+ # By default, this returns an instance of
950
+ # [Google::Cloud::Compute::V1::NetworkEndpointGroups::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/NetworkEndpointGroups/Rest/Client.html)
951
+ # for version V1 of the API.
952
+ # However, you can specify specify a different API version by passing it in the
953
+ # `version` parameter. If the NetworkEndpointGroups service is
954
+ # supported by that API version, and the corresponding gem is available, the
955
+ # appropriate versioned client will be returned.
956
+ #
957
+ # ## About NetworkEndpointGroups
958
+ #
959
+ # The NetworkEndpointGroups API.
960
+ #
961
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
962
+ # Defaults to `:v1`.
963
+ # @return [NetworkEndpointGroups::Rest::Client] A client object for the specified version.
964
+ #
965
+ def self.network_endpoint_groups version: :v1, &block
966
+ require "google/cloud/compute/#{version.to_s.downcase}"
967
+
968
+ package_name = Google::Cloud::Compute
969
+ .constants
970
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
971
+ .first
972
+ package_module = Google::Cloud::Compute.const_get package_name
973
+ package_module.const_get(:NetworkEndpointGroups).const_get(:Rest).const_get(:Client).new(&block)
974
+ end
975
+
976
+ ##
977
+ # Create a new client object for Networks.
978
+ #
979
+ # By default, this returns an instance of
980
+ # [Google::Cloud::Compute::V1::Networks::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Networks/Rest/Client.html)
981
+ # for version V1 of the API.
982
+ # However, you can specify specify a different API version by passing it in the
983
+ # `version` parameter. If the Networks service is
984
+ # supported by that API version, and the corresponding gem is available, the
985
+ # appropriate versioned client will be returned.
986
+ #
987
+ # ## About Networks
988
+ #
989
+ # The Networks API.
990
+ #
991
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
992
+ # Defaults to `:v1`.
993
+ # @return [Networks::Rest::Client] A client object for the specified version.
994
+ #
995
+ def self.networks version: :v1, &block
996
+ require "google/cloud/compute/#{version.to_s.downcase}"
997
+
998
+ package_name = Google::Cloud::Compute
999
+ .constants
1000
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1001
+ .first
1002
+ package_module = Google::Cloud::Compute.const_get package_name
1003
+ package_module.const_get(:Networks).const_get(:Rest).const_get(:Client).new(&block)
1004
+ end
1005
+
1006
+ ##
1007
+ # Create a new client object for NodeGroups.
1008
+ #
1009
+ # By default, this returns an instance of
1010
+ # [Google::Cloud::Compute::V1::NodeGroups::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/NodeGroups/Rest/Client.html)
1011
+ # for version V1 of the API.
1012
+ # However, you can specify specify a different API version by passing it in the
1013
+ # `version` parameter. If the NodeGroups service is
1014
+ # supported by that API version, and the corresponding gem is available, the
1015
+ # appropriate versioned client will be returned.
1016
+ #
1017
+ # ## About NodeGroups
1018
+ #
1019
+ # The NodeGroups API.
1020
+ #
1021
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1022
+ # Defaults to `:v1`.
1023
+ # @return [NodeGroups::Rest::Client] A client object for the specified version.
1024
+ #
1025
+ def self.node_groups version: :v1, &block
1026
+ require "google/cloud/compute/#{version.to_s.downcase}"
1027
+
1028
+ package_name = Google::Cloud::Compute
1029
+ .constants
1030
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1031
+ .first
1032
+ package_module = Google::Cloud::Compute.const_get package_name
1033
+ package_module.const_get(:NodeGroups).const_get(:Rest).const_get(:Client).new(&block)
1034
+ end
1035
+
1036
+ ##
1037
+ # Create a new client object for NodeTemplates.
1038
+ #
1039
+ # By default, this returns an instance of
1040
+ # [Google::Cloud::Compute::V1::NodeTemplates::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/NodeTemplates/Rest/Client.html)
1041
+ # for version V1 of the API.
1042
+ # However, you can specify specify a different API version by passing it in the
1043
+ # `version` parameter. If the NodeTemplates service is
1044
+ # supported by that API version, and the corresponding gem is available, the
1045
+ # appropriate versioned client will be returned.
1046
+ #
1047
+ # ## About NodeTemplates
1048
+ #
1049
+ # The NodeTemplates API.
1050
+ #
1051
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1052
+ # Defaults to `:v1`.
1053
+ # @return [NodeTemplates::Rest::Client] A client object for the specified version.
1054
+ #
1055
+ def self.node_templates version: :v1, &block
1056
+ require "google/cloud/compute/#{version.to_s.downcase}"
1057
+
1058
+ package_name = Google::Cloud::Compute
1059
+ .constants
1060
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1061
+ .first
1062
+ package_module = Google::Cloud::Compute.const_get package_name
1063
+ package_module.const_get(:NodeTemplates).const_get(:Rest).const_get(:Client).new(&block)
1064
+ end
1065
+
1066
+ ##
1067
+ # Create a new client object for NodeTypes.
1068
+ #
1069
+ # By default, this returns an instance of
1070
+ # [Google::Cloud::Compute::V1::NodeTypes::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/NodeTypes/Rest/Client.html)
1071
+ # for version V1 of the API.
1072
+ # However, you can specify specify a different API version by passing it in the
1073
+ # `version` parameter. If the NodeTypes service is
1074
+ # supported by that API version, and the corresponding gem is available, the
1075
+ # appropriate versioned client will be returned.
1076
+ #
1077
+ # ## About NodeTypes
1078
+ #
1079
+ # The NodeTypes API.
1080
+ #
1081
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1082
+ # Defaults to `:v1`.
1083
+ # @return [NodeTypes::Rest::Client] A client object for the specified version.
1084
+ #
1085
+ def self.node_types version: :v1, &block
1086
+ require "google/cloud/compute/#{version.to_s.downcase}"
1087
+
1088
+ package_name = Google::Cloud::Compute
1089
+ .constants
1090
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1091
+ .first
1092
+ package_module = Google::Cloud::Compute.const_get package_name
1093
+ package_module.const_get(:NodeTypes).const_get(:Rest).const_get(:Client).new(&block)
1094
+ end
1095
+
1096
+ ##
1097
+ # Create a new client object for PacketMirrorings.
1098
+ #
1099
+ # By default, this returns an instance of
1100
+ # [Google::Cloud::Compute::V1::PacketMirrorings::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/PacketMirrorings/Rest/Client.html)
1101
+ # for version V1 of the API.
1102
+ # However, you can specify specify a different API version by passing it in the
1103
+ # `version` parameter. If the PacketMirrorings service is
1104
+ # supported by that API version, and the corresponding gem is available, the
1105
+ # appropriate versioned client will be returned.
1106
+ #
1107
+ # ## About PacketMirrorings
1108
+ #
1109
+ # The PacketMirrorings API.
1110
+ #
1111
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1112
+ # Defaults to `:v1`.
1113
+ # @return [PacketMirrorings::Rest::Client] A client object for the specified version.
1114
+ #
1115
+ def self.packet_mirrorings version: :v1, &block
1116
+ require "google/cloud/compute/#{version.to_s.downcase}"
1117
+
1118
+ package_name = Google::Cloud::Compute
1119
+ .constants
1120
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1121
+ .first
1122
+ package_module = Google::Cloud::Compute.const_get package_name
1123
+ package_module.const_get(:PacketMirrorings).const_get(:Rest).const_get(:Client).new(&block)
1124
+ end
1125
+
1126
+ ##
1127
+ # Create a new client object for Projects.
1128
+ #
1129
+ # By default, this returns an instance of
1130
+ # [Google::Cloud::Compute::V1::Projects::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Projects/Rest/Client.html)
1131
+ # for version V1 of the API.
1132
+ # However, you can specify specify a different API version by passing it in the
1133
+ # `version` parameter. If the Projects service is
1134
+ # supported by that API version, and the corresponding gem is available, the
1135
+ # appropriate versioned client will be returned.
1136
+ #
1137
+ # ## About Projects
1138
+ #
1139
+ # The Projects API.
1140
+ #
1141
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1142
+ # Defaults to `:v1`.
1143
+ # @return [Projects::Rest::Client] A client object for the specified version.
1144
+ #
1145
+ def self.projects version: :v1, &block
1146
+ require "google/cloud/compute/#{version.to_s.downcase}"
1147
+
1148
+ package_name = Google::Cloud::Compute
1149
+ .constants
1150
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1151
+ .first
1152
+ package_module = Google::Cloud::Compute.const_get package_name
1153
+ package_module.const_get(:Projects).const_get(:Rest).const_get(:Client).new(&block)
1154
+ end
1155
+
1156
+ ##
1157
+ # Create a new client object for PublicAdvertisedPrefixes.
1158
+ #
1159
+ # By default, this returns an instance of
1160
+ # [Google::Cloud::Compute::V1::PublicAdvertisedPrefixes::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/PublicAdvertisedPrefixes/Rest/Client.html)
1161
+ # for version V1 of the API.
1162
+ # However, you can specify specify a different API version by passing it in the
1163
+ # `version` parameter. If the PublicAdvertisedPrefixes service is
1164
+ # supported by that API version, and the corresponding gem is available, the
1165
+ # appropriate versioned client will be returned.
1166
+ #
1167
+ # ## About PublicAdvertisedPrefixes
1168
+ #
1169
+ # The PublicAdvertisedPrefixes API.
1170
+ #
1171
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1172
+ # Defaults to `:v1`.
1173
+ # @return [PublicAdvertisedPrefixes::Rest::Client] A client object for the specified version.
1174
+ #
1175
+ def self.public_advertised_prefixes version: :v1, &block
1176
+ require "google/cloud/compute/#{version.to_s.downcase}"
1177
+
1178
+ package_name = Google::Cloud::Compute
1179
+ .constants
1180
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1181
+ .first
1182
+ package_module = Google::Cloud::Compute.const_get package_name
1183
+ package_module.const_get(:PublicAdvertisedPrefixes).const_get(:Rest).const_get(:Client).new(&block)
1184
+ end
1185
+
1186
+ ##
1187
+ # Create a new client object for PublicDelegatedPrefixes.
1188
+ #
1189
+ # By default, this returns an instance of
1190
+ # [Google::Cloud::Compute::V1::PublicDelegatedPrefixes::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/PublicDelegatedPrefixes/Rest/Client.html)
1191
+ # for version V1 of the API.
1192
+ # However, you can specify specify a different API version by passing it in the
1193
+ # `version` parameter. If the PublicDelegatedPrefixes service is
1194
+ # supported by that API version, and the corresponding gem is available, the
1195
+ # appropriate versioned client will be returned.
1196
+ #
1197
+ # ## About PublicDelegatedPrefixes
1198
+ #
1199
+ # The PublicDelegatedPrefixes API.
1200
+ #
1201
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1202
+ # Defaults to `:v1`.
1203
+ # @return [PublicDelegatedPrefixes::Rest::Client] A client object for the specified version.
1204
+ #
1205
+ def self.public_delegated_prefixes version: :v1, &block
1206
+ require "google/cloud/compute/#{version.to_s.downcase}"
1207
+
1208
+ package_name = Google::Cloud::Compute
1209
+ .constants
1210
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1211
+ .first
1212
+ package_module = Google::Cloud::Compute.const_get package_name
1213
+ package_module.const_get(:PublicDelegatedPrefixes).const_get(:Rest).const_get(:Client).new(&block)
1214
+ end
1215
+
1216
+ ##
1217
+ # Create a new client object for RegionAutoscalers.
1218
+ #
1219
+ # By default, this returns an instance of
1220
+ # [Google::Cloud::Compute::V1::RegionAutoscalers::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionAutoscalers/Rest/Client.html)
1221
+ # for version V1 of the API.
1222
+ # However, you can specify specify a different API version by passing it in the
1223
+ # `version` parameter. If the RegionAutoscalers service is
1224
+ # supported by that API version, and the corresponding gem is available, the
1225
+ # appropriate versioned client will be returned.
1226
+ #
1227
+ # ## About RegionAutoscalers
1228
+ #
1229
+ # The RegionAutoscalers API.
1230
+ #
1231
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1232
+ # Defaults to `:v1`.
1233
+ # @return [RegionAutoscalers::Rest::Client] A client object for the specified version.
1234
+ #
1235
+ def self.region_autoscalers version: :v1, &block
1236
+ require "google/cloud/compute/#{version.to_s.downcase}"
1237
+
1238
+ package_name = Google::Cloud::Compute
1239
+ .constants
1240
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1241
+ .first
1242
+ package_module = Google::Cloud::Compute.const_get package_name
1243
+ package_module.const_get(:RegionAutoscalers).const_get(:Rest).const_get(:Client).new(&block)
1244
+ end
1245
+
1246
+ ##
1247
+ # Create a new client object for RegionBackendServices.
1248
+ #
1249
+ # By default, this returns an instance of
1250
+ # [Google::Cloud::Compute::V1::RegionBackendServices::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionBackendServices/Rest/Client.html)
1251
+ # for version V1 of the API.
1252
+ # However, you can specify specify a different API version by passing it in the
1253
+ # `version` parameter. If the RegionBackendServices service is
1254
+ # supported by that API version, and the corresponding gem is available, the
1255
+ # appropriate versioned client will be returned.
1256
+ #
1257
+ # ## About RegionBackendServices
1258
+ #
1259
+ # The RegionBackendServices API.
1260
+ #
1261
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1262
+ # Defaults to `:v1`.
1263
+ # @return [RegionBackendServices::Rest::Client] A client object for the specified version.
1264
+ #
1265
+ def self.region_backend_services version: :v1, &block
1266
+ require "google/cloud/compute/#{version.to_s.downcase}"
1267
+
1268
+ package_name = Google::Cloud::Compute
1269
+ .constants
1270
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1271
+ .first
1272
+ package_module = Google::Cloud::Compute.const_get package_name
1273
+ package_module.const_get(:RegionBackendServices).const_get(:Rest).const_get(:Client).new(&block)
1274
+ end
1275
+
1276
+ ##
1277
+ # Create a new client object for RegionCommitments.
1278
+ #
1279
+ # By default, this returns an instance of
1280
+ # [Google::Cloud::Compute::V1::RegionCommitments::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionCommitments/Rest/Client.html)
1281
+ # for version V1 of the API.
1282
+ # However, you can specify specify a different API version by passing it in the
1283
+ # `version` parameter. If the RegionCommitments service is
1284
+ # supported by that API version, and the corresponding gem is available, the
1285
+ # appropriate versioned client will be returned.
1286
+ #
1287
+ # ## About RegionCommitments
1288
+ #
1289
+ # The RegionCommitments API.
1290
+ #
1291
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1292
+ # Defaults to `:v1`.
1293
+ # @return [RegionCommitments::Rest::Client] A client object for the specified version.
1294
+ #
1295
+ def self.region_commitments version: :v1, &block
1296
+ require "google/cloud/compute/#{version.to_s.downcase}"
1297
+
1298
+ package_name = Google::Cloud::Compute
1299
+ .constants
1300
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1301
+ .first
1302
+ package_module = Google::Cloud::Compute.const_get package_name
1303
+ package_module.const_get(:RegionCommitments).const_get(:Rest).const_get(:Client).new(&block)
1304
+ end
1305
+
1306
+ ##
1307
+ # Create a new client object for RegionDiskTypes.
1308
+ #
1309
+ # By default, this returns an instance of
1310
+ # [Google::Cloud::Compute::V1::RegionDiskTypes::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionDiskTypes/Rest/Client.html)
1311
+ # for version V1 of the API.
1312
+ # However, you can specify specify a different API version by passing it in the
1313
+ # `version` parameter. If the RegionDiskTypes service is
1314
+ # supported by that API version, and the corresponding gem is available, the
1315
+ # appropriate versioned client will be returned.
1316
+ #
1317
+ # ## About RegionDiskTypes
1318
+ #
1319
+ # The RegionDiskTypes API.
1320
+ #
1321
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1322
+ # Defaults to `:v1`.
1323
+ # @return [RegionDiskTypes::Rest::Client] A client object for the specified version.
1324
+ #
1325
+ def self.region_disk_types version: :v1, &block
1326
+ require "google/cloud/compute/#{version.to_s.downcase}"
1327
+
1328
+ package_name = Google::Cloud::Compute
1329
+ .constants
1330
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1331
+ .first
1332
+ package_module = Google::Cloud::Compute.const_get package_name
1333
+ package_module.const_get(:RegionDiskTypes).const_get(:Rest).const_get(:Client).new(&block)
1334
+ end
1335
+
1336
+ ##
1337
+ # Create a new client object for RegionDisks.
1338
+ #
1339
+ # By default, this returns an instance of
1340
+ # [Google::Cloud::Compute::V1::RegionDisks::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionDisks/Rest/Client.html)
1341
+ # for version V1 of the API.
1342
+ # However, you can specify specify a different API version by passing it in the
1343
+ # `version` parameter. If the RegionDisks service is
1344
+ # supported by that API version, and the corresponding gem is available, the
1345
+ # appropriate versioned client will be returned.
1346
+ #
1347
+ # ## About RegionDisks
1348
+ #
1349
+ # The RegionDisks API.
1350
+ #
1351
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1352
+ # Defaults to `:v1`.
1353
+ # @return [RegionDisks::Rest::Client] A client object for the specified version.
1354
+ #
1355
+ def self.region_disks version: :v1, &block
1356
+ require "google/cloud/compute/#{version.to_s.downcase}"
1357
+
1358
+ package_name = Google::Cloud::Compute
1359
+ .constants
1360
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1361
+ .first
1362
+ package_module = Google::Cloud::Compute.const_get package_name
1363
+ package_module.const_get(:RegionDisks).const_get(:Rest).const_get(:Client).new(&block)
1364
+ end
1365
+
1366
+ ##
1367
+ # Create a new client object for RegionHealthCheckServices.
1368
+ #
1369
+ # By default, this returns an instance of
1370
+ # [Google::Cloud::Compute::V1::RegionHealthCheckServices::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionHealthCheckServices/Rest/Client.html)
1371
+ # for version V1 of the API.
1372
+ # However, you can specify specify a different API version by passing it in the
1373
+ # `version` parameter. If the RegionHealthCheckServices service is
1374
+ # supported by that API version, and the corresponding gem is available, the
1375
+ # appropriate versioned client will be returned.
1376
+ #
1377
+ # ## About RegionHealthCheckServices
1378
+ #
1379
+ # The RegionHealthCheckServices API.
1380
+ #
1381
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1382
+ # Defaults to `:v1`.
1383
+ # @return [RegionHealthCheckServices::Rest::Client] A client object for the specified version.
1384
+ #
1385
+ def self.region_health_check_services version: :v1, &block
1386
+ require "google/cloud/compute/#{version.to_s.downcase}"
1387
+
1388
+ package_name = Google::Cloud::Compute
1389
+ .constants
1390
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1391
+ .first
1392
+ package_module = Google::Cloud::Compute.const_get package_name
1393
+ package_module.const_get(:RegionHealthCheckServices).const_get(:Rest).const_get(:Client).new(&block)
1394
+ end
1395
+
1396
+ ##
1397
+ # Create a new client object for RegionHealthChecks.
1398
+ #
1399
+ # By default, this returns an instance of
1400
+ # [Google::Cloud::Compute::V1::RegionHealthChecks::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionHealthChecks/Rest/Client.html)
1401
+ # for version V1 of the API.
1402
+ # However, you can specify specify a different API version by passing it in the
1403
+ # `version` parameter. If the RegionHealthChecks service is
1404
+ # supported by that API version, and the corresponding gem is available, the
1405
+ # appropriate versioned client will be returned.
1406
+ #
1407
+ # ## About RegionHealthChecks
1408
+ #
1409
+ # The RegionHealthChecks API.
1410
+ #
1411
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1412
+ # Defaults to `:v1`.
1413
+ # @return [RegionHealthChecks::Rest::Client] A client object for the specified version.
1414
+ #
1415
+ def self.region_health_checks version: :v1, &block
1416
+ require "google/cloud/compute/#{version.to_s.downcase}"
1417
+
1418
+ package_name = Google::Cloud::Compute
1419
+ .constants
1420
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1421
+ .first
1422
+ package_module = Google::Cloud::Compute.const_get package_name
1423
+ package_module.const_get(:RegionHealthChecks).const_get(:Rest).const_get(:Client).new(&block)
1424
+ end
1425
+
1426
+ ##
1427
+ # Create a new client object for RegionInstanceGroupManagers.
1428
+ #
1429
+ # By default, this returns an instance of
1430
+ # [Google::Cloud::Compute::V1::RegionInstanceGroupManagers::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionInstanceGroupManagers/Rest/Client.html)
1431
+ # for version V1 of the API.
1432
+ # However, you can specify specify a different API version by passing it in the
1433
+ # `version` parameter. If the RegionInstanceGroupManagers service is
1434
+ # supported by that API version, and the corresponding gem is available, the
1435
+ # appropriate versioned client will be returned.
1436
+ #
1437
+ # ## About RegionInstanceGroupManagers
1438
+ #
1439
+ # The RegionInstanceGroupManagers API.
1440
+ #
1441
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1442
+ # Defaults to `:v1`.
1443
+ # @return [RegionInstanceGroupManagers::Rest::Client] A client object for the specified version.
1444
+ #
1445
+ def self.region_instance_group_managers version: :v1, &block
1446
+ require "google/cloud/compute/#{version.to_s.downcase}"
1447
+
1448
+ package_name = Google::Cloud::Compute
1449
+ .constants
1450
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1451
+ .first
1452
+ package_module = Google::Cloud::Compute.const_get package_name
1453
+ package_module.const_get(:RegionInstanceGroupManagers).const_get(:Rest).const_get(:Client).new(&block)
1454
+ end
1455
+
1456
+ ##
1457
+ # Create a new client object for RegionInstanceGroups.
1458
+ #
1459
+ # By default, this returns an instance of
1460
+ # [Google::Cloud::Compute::V1::RegionInstanceGroups::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionInstanceGroups/Rest/Client.html)
1461
+ # for version V1 of the API.
1462
+ # However, you can specify specify a different API version by passing it in the
1463
+ # `version` parameter. If the RegionInstanceGroups service is
1464
+ # supported by that API version, and the corresponding gem is available, the
1465
+ # appropriate versioned client will be returned.
1466
+ #
1467
+ # ## About RegionInstanceGroups
1468
+ #
1469
+ # The RegionInstanceGroups API.
1470
+ #
1471
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1472
+ # Defaults to `:v1`.
1473
+ # @return [RegionInstanceGroups::Rest::Client] A client object for the specified version.
1474
+ #
1475
+ def self.region_instance_groups version: :v1, &block
1476
+ require "google/cloud/compute/#{version.to_s.downcase}"
1477
+
1478
+ package_name = Google::Cloud::Compute
1479
+ .constants
1480
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1481
+ .first
1482
+ package_module = Google::Cloud::Compute.const_get package_name
1483
+ package_module.const_get(:RegionInstanceGroups).const_get(:Rest).const_get(:Client).new(&block)
1484
+ end
1485
+
1486
+ ##
1487
+ # Create a new client object for RegionInstances.
1488
+ #
1489
+ # By default, this returns an instance of
1490
+ # [Google::Cloud::Compute::V1::RegionInstances::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionInstances/Rest/Client.html)
1491
+ # for version V1 of the API.
1492
+ # However, you can specify specify a different API version by passing it in the
1493
+ # `version` parameter. If the RegionInstances service is
1494
+ # supported by that API version, and the corresponding gem is available, the
1495
+ # appropriate versioned client will be returned.
1496
+ #
1497
+ # ## About RegionInstances
1498
+ #
1499
+ # The RegionInstances API.
1500
+ #
1501
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1502
+ # Defaults to `:v1`.
1503
+ # @return [RegionInstances::Rest::Client] A client object for the specified version.
1504
+ #
1505
+ def self.region_instances version: :v1, &block
1506
+ require "google/cloud/compute/#{version.to_s.downcase}"
1507
+
1508
+ package_name = Google::Cloud::Compute
1509
+ .constants
1510
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1511
+ .first
1512
+ package_module = Google::Cloud::Compute.const_get package_name
1513
+ package_module.const_get(:RegionInstances).const_get(:Rest).const_get(:Client).new(&block)
1514
+ end
1515
+
1516
+ ##
1517
+ # Create a new client object for RegionNetworkEndpointGroups.
1518
+ #
1519
+ # By default, this returns an instance of
1520
+ # [Google::Cloud::Compute::V1::RegionNetworkEndpointGroups::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionNetworkEndpointGroups/Rest/Client.html)
1521
+ # for version V1 of the API.
1522
+ # However, you can specify specify a different API version by passing it in the
1523
+ # `version` parameter. If the RegionNetworkEndpointGroups service is
1524
+ # supported by that API version, and the corresponding gem is available, the
1525
+ # appropriate versioned client will be returned.
1526
+ #
1527
+ # ## About RegionNetworkEndpointGroups
1528
+ #
1529
+ # The RegionNetworkEndpointGroups API.
1530
+ #
1531
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1532
+ # Defaults to `:v1`.
1533
+ # @return [RegionNetworkEndpointGroups::Rest::Client] A client object for the specified version.
1534
+ #
1535
+ def self.region_network_endpoint_groups version: :v1, &block
1536
+ require "google/cloud/compute/#{version.to_s.downcase}"
1537
+
1538
+ package_name = Google::Cloud::Compute
1539
+ .constants
1540
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1541
+ .first
1542
+ package_module = Google::Cloud::Compute.const_get package_name
1543
+ package_module.const_get(:RegionNetworkEndpointGroups).const_get(:Rest).const_get(:Client).new(&block)
1544
+ end
1545
+
1546
+ ##
1547
+ # Create a new client object for RegionNotificationEndpoints.
1548
+ #
1549
+ # By default, this returns an instance of
1550
+ # [Google::Cloud::Compute::V1::RegionNotificationEndpoints::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionNotificationEndpoints/Rest/Client.html)
1551
+ # for version V1 of the API.
1552
+ # However, you can specify specify a different API version by passing it in the
1553
+ # `version` parameter. If the RegionNotificationEndpoints service is
1554
+ # supported by that API version, and the corresponding gem is available, the
1555
+ # appropriate versioned client will be returned.
1556
+ #
1557
+ # ## About RegionNotificationEndpoints
1558
+ #
1559
+ # The RegionNotificationEndpoints API.
1560
+ #
1561
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1562
+ # Defaults to `:v1`.
1563
+ # @return [RegionNotificationEndpoints::Rest::Client] A client object for the specified version.
1564
+ #
1565
+ def self.region_notification_endpoints version: :v1, &block
1566
+ require "google/cloud/compute/#{version.to_s.downcase}"
1567
+
1568
+ package_name = Google::Cloud::Compute
1569
+ .constants
1570
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1571
+ .first
1572
+ package_module = Google::Cloud::Compute.const_get package_name
1573
+ package_module.const_get(:RegionNotificationEndpoints).const_get(:Rest).const_get(:Client).new(&block)
1574
+ end
1575
+
1576
+ ##
1577
+ # Create a new client object for RegionOperations.
1578
+ #
1579
+ # By default, this returns an instance of
1580
+ # [Google::Cloud::Compute::V1::RegionOperations::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionOperations/Rest/Client.html)
1581
+ # for version V1 of the API.
1582
+ # However, you can specify specify a different API version by passing it in the
1583
+ # `version` parameter. If the RegionOperations service is
1584
+ # supported by that API version, and the corresponding gem is available, the
1585
+ # appropriate versioned client will be returned.
1586
+ #
1587
+ # ## About RegionOperations
1588
+ #
1589
+ # The RegionOperations API.
1590
+ #
1591
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1592
+ # Defaults to `:v1`.
1593
+ # @return [RegionOperations::Rest::Client] A client object for the specified version.
1594
+ #
1595
+ def self.region_operations version: :v1, &block
1596
+ require "google/cloud/compute/#{version.to_s.downcase}"
1597
+
1598
+ package_name = Google::Cloud::Compute
1599
+ .constants
1600
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1601
+ .first
1602
+ package_module = Google::Cloud::Compute.const_get package_name
1603
+ package_module.const_get(:RegionOperations).const_get(:Rest).const_get(:Client).new(&block)
1604
+ end
1605
+
1606
+ ##
1607
+ # Create a new client object for RegionSslCertificates.
1608
+ #
1609
+ # By default, this returns an instance of
1610
+ # [Google::Cloud::Compute::V1::RegionSslCertificates::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionSslCertificates/Rest/Client.html)
1611
+ # for version V1 of the API.
1612
+ # However, you can specify specify a different API version by passing it in the
1613
+ # `version` parameter. If the RegionSslCertificates service is
1614
+ # supported by that API version, and the corresponding gem is available, the
1615
+ # appropriate versioned client will be returned.
1616
+ #
1617
+ # ## About RegionSslCertificates
1618
+ #
1619
+ # The RegionSslCertificates API.
1620
+ #
1621
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1622
+ # Defaults to `:v1`.
1623
+ # @return [RegionSslCertificates::Rest::Client] A client object for the specified version.
1624
+ #
1625
+ def self.region_ssl_certificates version: :v1, &block
1626
+ require "google/cloud/compute/#{version.to_s.downcase}"
1627
+
1628
+ package_name = Google::Cloud::Compute
1629
+ .constants
1630
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1631
+ .first
1632
+ package_module = Google::Cloud::Compute.const_get package_name
1633
+ package_module.const_get(:RegionSslCertificates).const_get(:Rest).const_get(:Client).new(&block)
1634
+ end
1635
+
1636
+ ##
1637
+ # Create a new client object for RegionTargetHttpProxies.
1638
+ #
1639
+ # By default, this returns an instance of
1640
+ # [Google::Cloud::Compute::V1::RegionTargetHttpProxies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionTargetHttpProxies/Rest/Client.html)
1641
+ # for version V1 of the API.
1642
+ # However, you can specify specify a different API version by passing it in the
1643
+ # `version` parameter. If the RegionTargetHttpProxies service is
1644
+ # supported by that API version, and the corresponding gem is available, the
1645
+ # appropriate versioned client will be returned.
1646
+ #
1647
+ # ## About RegionTargetHttpProxies
1648
+ #
1649
+ # The RegionTargetHttpProxies API.
1650
+ #
1651
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1652
+ # Defaults to `:v1`.
1653
+ # @return [RegionTargetHttpProxies::Rest::Client] A client object for the specified version.
1654
+ #
1655
+ def self.region_target_http_proxies version: :v1, &block
1656
+ require "google/cloud/compute/#{version.to_s.downcase}"
1657
+
1658
+ package_name = Google::Cloud::Compute
1659
+ .constants
1660
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1661
+ .first
1662
+ package_module = Google::Cloud::Compute.const_get package_name
1663
+ package_module.const_get(:RegionTargetHttpProxies).const_get(:Rest).const_get(:Client).new(&block)
1664
+ end
1665
+
1666
+ ##
1667
+ # Create a new client object for RegionTargetHttpsProxies.
1668
+ #
1669
+ # By default, this returns an instance of
1670
+ # [Google::Cloud::Compute::V1::RegionTargetHttpsProxies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionTargetHttpsProxies/Rest/Client.html)
1671
+ # for version V1 of the API.
1672
+ # However, you can specify specify a different API version by passing it in the
1673
+ # `version` parameter. If the RegionTargetHttpsProxies service is
1674
+ # supported by that API version, and the corresponding gem is available, the
1675
+ # appropriate versioned client will be returned.
1676
+ #
1677
+ # ## About RegionTargetHttpsProxies
1678
+ #
1679
+ # The RegionTargetHttpsProxies API.
1680
+ #
1681
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1682
+ # Defaults to `:v1`.
1683
+ # @return [RegionTargetHttpsProxies::Rest::Client] A client object for the specified version.
1684
+ #
1685
+ def self.region_target_https_proxies version: :v1, &block
1686
+ require "google/cloud/compute/#{version.to_s.downcase}"
1687
+
1688
+ package_name = Google::Cloud::Compute
1689
+ .constants
1690
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1691
+ .first
1692
+ package_module = Google::Cloud::Compute.const_get package_name
1693
+ package_module.const_get(:RegionTargetHttpsProxies).const_get(:Rest).const_get(:Client).new(&block)
1694
+ end
1695
+
1696
+ ##
1697
+ # Create a new client object for RegionUrlMaps.
1698
+ #
1699
+ # By default, this returns an instance of
1700
+ # [Google::Cloud::Compute::V1::RegionUrlMaps::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/RegionUrlMaps/Rest/Client.html)
1701
+ # for version V1 of the API.
1702
+ # However, you can specify specify a different API version by passing it in the
1703
+ # `version` parameter. If the RegionUrlMaps service is
1704
+ # supported by that API version, and the corresponding gem is available, the
1705
+ # appropriate versioned client will be returned.
1706
+ #
1707
+ # ## About RegionUrlMaps
1708
+ #
1709
+ # The RegionUrlMaps API.
1710
+ #
1711
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1712
+ # Defaults to `:v1`.
1713
+ # @return [RegionUrlMaps::Rest::Client] A client object for the specified version.
1714
+ #
1715
+ def self.region_url_maps version: :v1, &block
1716
+ require "google/cloud/compute/#{version.to_s.downcase}"
1717
+
1718
+ package_name = Google::Cloud::Compute
1719
+ .constants
1720
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1721
+ .first
1722
+ package_module = Google::Cloud::Compute.const_get package_name
1723
+ package_module.const_get(:RegionUrlMaps).const_get(:Rest).const_get(:Client).new(&block)
1724
+ end
1725
+
1726
+ ##
1727
+ # Create a new client object for Regions.
1728
+ #
1729
+ # By default, this returns an instance of
1730
+ # [Google::Cloud::Compute::V1::Regions::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Regions/Rest/Client.html)
1731
+ # for version V1 of the API.
1732
+ # However, you can specify specify a different API version by passing it in the
1733
+ # `version` parameter. If the Regions service is
1734
+ # supported by that API version, and the corresponding gem is available, the
1735
+ # appropriate versioned client will be returned.
1736
+ #
1737
+ # ## About Regions
1738
+ #
1739
+ # The Regions API.
1740
+ #
1741
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1742
+ # Defaults to `:v1`.
1743
+ # @return [Regions::Rest::Client] A client object for the specified version.
1744
+ #
1745
+ def self.regions version: :v1, &block
1746
+ require "google/cloud/compute/#{version.to_s.downcase}"
1747
+
1748
+ package_name = Google::Cloud::Compute
1749
+ .constants
1750
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1751
+ .first
1752
+ package_module = Google::Cloud::Compute.const_get package_name
1753
+ package_module.const_get(:Regions).const_get(:Rest).const_get(:Client).new(&block)
1754
+ end
1755
+
1756
+ ##
1757
+ # Create a new client object for Reservations.
1758
+ #
1759
+ # By default, this returns an instance of
1760
+ # [Google::Cloud::Compute::V1::Reservations::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Reservations/Rest/Client.html)
1761
+ # for version V1 of the API.
1762
+ # However, you can specify specify a different API version by passing it in the
1763
+ # `version` parameter. If the Reservations service is
1764
+ # supported by that API version, and the corresponding gem is available, the
1765
+ # appropriate versioned client will be returned.
1766
+ #
1767
+ # ## About Reservations
1768
+ #
1769
+ # The Reservations API.
1770
+ #
1771
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1772
+ # Defaults to `:v1`.
1773
+ # @return [Reservations::Rest::Client] A client object for the specified version.
1774
+ #
1775
+ def self.reservations version: :v1, &block
1776
+ require "google/cloud/compute/#{version.to_s.downcase}"
1777
+
1778
+ package_name = Google::Cloud::Compute
1779
+ .constants
1780
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1781
+ .first
1782
+ package_module = Google::Cloud::Compute.const_get package_name
1783
+ package_module.const_get(:Reservations).const_get(:Rest).const_get(:Client).new(&block)
1784
+ end
1785
+
1786
+ ##
1787
+ # Create a new client object for ResourcePolicies.
1788
+ #
1789
+ # By default, this returns an instance of
1790
+ # [Google::Cloud::Compute::V1::ResourcePolicies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/ResourcePolicies/Rest/Client.html)
1791
+ # for version V1 of the API.
1792
+ # However, you can specify specify a different API version by passing it in the
1793
+ # `version` parameter. If the ResourcePolicies service is
1794
+ # supported by that API version, and the corresponding gem is available, the
1795
+ # appropriate versioned client will be returned.
1796
+ #
1797
+ # ## About ResourcePolicies
1798
+ #
1799
+ # The ResourcePolicies API.
1800
+ #
1801
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1802
+ # Defaults to `:v1`.
1803
+ # @return [ResourcePolicies::Rest::Client] A client object for the specified version.
1804
+ #
1805
+ def self.resource_policies version: :v1, &block
1806
+ require "google/cloud/compute/#{version.to_s.downcase}"
1807
+
1808
+ package_name = Google::Cloud::Compute
1809
+ .constants
1810
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1811
+ .first
1812
+ package_module = Google::Cloud::Compute.const_get package_name
1813
+ package_module.const_get(:ResourcePolicies).const_get(:Rest).const_get(:Client).new(&block)
1814
+ end
1815
+
1816
+ ##
1817
+ # Create a new client object for Routers.
1818
+ #
1819
+ # By default, this returns an instance of
1820
+ # [Google::Cloud::Compute::V1::Routers::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Routers/Rest/Client.html)
1821
+ # for version V1 of the API.
1822
+ # However, you can specify specify a different API version by passing it in the
1823
+ # `version` parameter. If the Routers service is
1824
+ # supported by that API version, and the corresponding gem is available, the
1825
+ # appropriate versioned client will be returned.
1826
+ #
1827
+ # ## About Routers
1828
+ #
1829
+ # The Routers API.
1830
+ #
1831
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1832
+ # Defaults to `:v1`.
1833
+ # @return [Routers::Rest::Client] A client object for the specified version.
1834
+ #
1835
+ def self.routers version: :v1, &block
1836
+ require "google/cloud/compute/#{version.to_s.downcase}"
1837
+
1838
+ package_name = Google::Cloud::Compute
1839
+ .constants
1840
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1841
+ .first
1842
+ package_module = Google::Cloud::Compute.const_get package_name
1843
+ package_module.const_get(:Routers).const_get(:Rest).const_get(:Client).new(&block)
1844
+ end
1845
+
1846
+ ##
1847
+ # Create a new client object for Routes.
1848
+ #
1849
+ # By default, this returns an instance of
1850
+ # [Google::Cloud::Compute::V1::Routes::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Routes/Rest/Client.html)
1851
+ # for version V1 of the API.
1852
+ # However, you can specify specify a different API version by passing it in the
1853
+ # `version` parameter. If the Routes service is
1854
+ # supported by that API version, and the corresponding gem is available, the
1855
+ # appropriate versioned client will be returned.
1856
+ #
1857
+ # ## About Routes
1858
+ #
1859
+ # The Routes API.
1860
+ #
1861
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1862
+ # Defaults to `:v1`.
1863
+ # @return [Routes::Rest::Client] A client object for the specified version.
1864
+ #
1865
+ def self.routes version: :v1, &block
1866
+ require "google/cloud/compute/#{version.to_s.downcase}"
1867
+
1868
+ package_name = Google::Cloud::Compute
1869
+ .constants
1870
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1871
+ .first
1872
+ package_module = Google::Cloud::Compute.const_get package_name
1873
+ package_module.const_get(:Routes).const_get(:Rest).const_get(:Client).new(&block)
1874
+ end
1875
+
1876
+ ##
1877
+ # Create a new client object for SecurityPolicies.
1878
+ #
1879
+ # By default, this returns an instance of
1880
+ # [Google::Cloud::Compute::V1::SecurityPolicies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/SecurityPolicies/Rest/Client.html)
1881
+ # for version V1 of the API.
1882
+ # However, you can specify specify a different API version by passing it in the
1883
+ # `version` parameter. If the SecurityPolicies service is
1884
+ # supported by that API version, and the corresponding gem is available, the
1885
+ # appropriate versioned client will be returned.
1886
+ #
1887
+ # ## About SecurityPolicies
1888
+ #
1889
+ # The SecurityPolicies API.
1890
+ #
1891
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1892
+ # Defaults to `:v1`.
1893
+ # @return [SecurityPolicies::Rest::Client] A client object for the specified version.
1894
+ #
1895
+ def self.security_policies version: :v1, &block
1896
+ require "google/cloud/compute/#{version.to_s.downcase}"
1897
+
1898
+ package_name = Google::Cloud::Compute
1899
+ .constants
1900
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1901
+ .first
1902
+ package_module = Google::Cloud::Compute.const_get package_name
1903
+ package_module.const_get(:SecurityPolicies).const_get(:Rest).const_get(:Client).new(&block)
1904
+ end
1905
+
1906
+ ##
1907
+ # Create a new client object for ServiceAttachments.
1908
+ #
1909
+ # By default, this returns an instance of
1910
+ # [Google::Cloud::Compute::V1::ServiceAttachments::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/ServiceAttachments/Rest/Client.html)
1911
+ # for version V1 of the API.
1912
+ # However, you can specify specify a different API version by passing it in the
1913
+ # `version` parameter. If the ServiceAttachments service is
1914
+ # supported by that API version, and the corresponding gem is available, the
1915
+ # appropriate versioned client will be returned.
1916
+ #
1917
+ # ## About ServiceAttachments
1918
+ #
1919
+ # The ServiceAttachments API.
1920
+ #
1921
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1922
+ # Defaults to `:v1`.
1923
+ # @return [ServiceAttachments::Rest::Client] A client object for the specified version.
1924
+ #
1925
+ def self.service_attachments version: :v1, &block
1926
+ require "google/cloud/compute/#{version.to_s.downcase}"
1927
+
1928
+ package_name = Google::Cloud::Compute
1929
+ .constants
1930
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1931
+ .first
1932
+ package_module = Google::Cloud::Compute.const_get package_name
1933
+ package_module.const_get(:ServiceAttachments).const_get(:Rest).const_get(:Client).new(&block)
1934
+ end
1935
+
1936
+ ##
1937
+ # Create a new client object for Snapshots.
1938
+ #
1939
+ # By default, this returns an instance of
1940
+ # [Google::Cloud::Compute::V1::Snapshots::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Snapshots/Rest/Client.html)
1941
+ # for version V1 of the API.
1942
+ # However, you can specify specify a different API version by passing it in the
1943
+ # `version` parameter. If the Snapshots service is
1944
+ # supported by that API version, and the corresponding gem is available, the
1945
+ # appropriate versioned client will be returned.
1946
+ #
1947
+ # ## About Snapshots
1948
+ #
1949
+ # The Snapshots API.
1950
+ #
1951
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1952
+ # Defaults to `:v1`.
1953
+ # @return [Snapshots::Rest::Client] A client object for the specified version.
1954
+ #
1955
+ def self.snapshots version: :v1, &block
1956
+ require "google/cloud/compute/#{version.to_s.downcase}"
1957
+
1958
+ package_name = Google::Cloud::Compute
1959
+ .constants
1960
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1961
+ .first
1962
+ package_module = Google::Cloud::Compute.const_get package_name
1963
+ package_module.const_get(:Snapshots).const_get(:Rest).const_get(:Client).new(&block)
1964
+ end
1965
+
1966
+ ##
1967
+ # Create a new client object for SslCertificates.
1968
+ #
1969
+ # By default, this returns an instance of
1970
+ # [Google::Cloud::Compute::V1::SslCertificates::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/SslCertificates/Rest/Client.html)
1971
+ # for version V1 of the API.
1972
+ # However, you can specify specify a different API version by passing it in the
1973
+ # `version` parameter. If the SslCertificates service is
1974
+ # supported by that API version, and the corresponding gem is available, the
1975
+ # appropriate versioned client will be returned.
1976
+ #
1977
+ # ## About SslCertificates
1978
+ #
1979
+ # The SslCertificates API.
1980
+ #
1981
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1982
+ # Defaults to `:v1`.
1983
+ # @return [SslCertificates::Rest::Client] A client object for the specified version.
1984
+ #
1985
+ def self.ssl_certificates version: :v1, &block
1986
+ require "google/cloud/compute/#{version.to_s.downcase}"
1987
+
1988
+ package_name = Google::Cloud::Compute
1989
+ .constants
1990
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1991
+ .first
1992
+ package_module = Google::Cloud::Compute.const_get package_name
1993
+ package_module.const_get(:SslCertificates).const_get(:Rest).const_get(:Client).new(&block)
1994
+ end
1995
+
1996
+ ##
1997
+ # Create a new client object for SslPolicies.
1998
+ #
1999
+ # By default, this returns an instance of
2000
+ # [Google::Cloud::Compute::V1::SslPolicies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/SslPolicies/Rest/Client.html)
2001
+ # for version V1 of the API.
2002
+ # However, you can specify specify a different API version by passing it in the
2003
+ # `version` parameter. If the SslPolicies service is
2004
+ # supported by that API version, and the corresponding gem is available, the
2005
+ # appropriate versioned client will be returned.
2006
+ #
2007
+ # ## About SslPolicies
2008
+ #
2009
+ # The SslPolicies API.
2010
+ #
2011
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2012
+ # Defaults to `:v1`.
2013
+ # @return [SslPolicies::Rest::Client] A client object for the specified version.
2014
+ #
2015
+ def self.ssl_policies version: :v1, &block
2016
+ require "google/cloud/compute/#{version.to_s.downcase}"
2017
+
2018
+ package_name = Google::Cloud::Compute
2019
+ .constants
2020
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2021
+ .first
2022
+ package_module = Google::Cloud::Compute.const_get package_name
2023
+ package_module.const_get(:SslPolicies).const_get(:Rest).const_get(:Client).new(&block)
2024
+ end
2025
+
2026
+ ##
2027
+ # Create a new client object for Subnetworks.
2028
+ #
2029
+ # By default, this returns an instance of
2030
+ # [Google::Cloud::Compute::V1::Subnetworks::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Subnetworks/Rest/Client.html)
2031
+ # for version V1 of the API.
2032
+ # However, you can specify specify a different API version by passing it in the
2033
+ # `version` parameter. If the Subnetworks service is
2034
+ # supported by that API version, and the corresponding gem is available, the
2035
+ # appropriate versioned client will be returned.
2036
+ #
2037
+ # ## About Subnetworks
2038
+ #
2039
+ # The Subnetworks API.
2040
+ #
2041
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2042
+ # Defaults to `:v1`.
2043
+ # @return [Subnetworks::Rest::Client] A client object for the specified version.
2044
+ #
2045
+ def self.subnetworks version: :v1, &block
2046
+ require "google/cloud/compute/#{version.to_s.downcase}"
2047
+
2048
+ package_name = Google::Cloud::Compute
2049
+ .constants
2050
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2051
+ .first
2052
+ package_module = Google::Cloud::Compute.const_get package_name
2053
+ package_module.const_get(:Subnetworks).const_get(:Rest).const_get(:Client).new(&block)
2054
+ end
2055
+
2056
+ ##
2057
+ # Create a new client object for TargetGrpcProxies.
2058
+ #
2059
+ # By default, this returns an instance of
2060
+ # [Google::Cloud::Compute::V1::TargetGrpcProxies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/TargetGrpcProxies/Rest/Client.html)
2061
+ # for version V1 of the API.
2062
+ # However, you can specify specify a different API version by passing it in the
2063
+ # `version` parameter. If the TargetGrpcProxies service is
2064
+ # supported by that API version, and the corresponding gem is available, the
2065
+ # appropriate versioned client will be returned.
2066
+ #
2067
+ # ## About TargetGrpcProxies
2068
+ #
2069
+ # The TargetGrpcProxies API.
2070
+ #
2071
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2072
+ # Defaults to `:v1`.
2073
+ # @return [TargetGrpcProxies::Rest::Client] A client object for the specified version.
2074
+ #
2075
+ def self.target_grpc_proxies version: :v1, &block
2076
+ require "google/cloud/compute/#{version.to_s.downcase}"
2077
+
2078
+ package_name = Google::Cloud::Compute
2079
+ .constants
2080
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2081
+ .first
2082
+ package_module = Google::Cloud::Compute.const_get package_name
2083
+ package_module.const_get(:TargetGrpcProxies).const_get(:Rest).const_get(:Client).new(&block)
2084
+ end
2085
+
2086
+ ##
2087
+ # Create a new client object for TargetHttpProxies.
2088
+ #
2089
+ # By default, this returns an instance of
2090
+ # [Google::Cloud::Compute::V1::TargetHttpProxies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/TargetHttpProxies/Rest/Client.html)
2091
+ # for version V1 of the API.
2092
+ # However, you can specify specify a different API version by passing it in the
2093
+ # `version` parameter. If the TargetHttpProxies service is
2094
+ # supported by that API version, and the corresponding gem is available, the
2095
+ # appropriate versioned client will be returned.
2096
+ #
2097
+ # ## About TargetHttpProxies
2098
+ #
2099
+ # The TargetHttpProxies API.
2100
+ #
2101
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2102
+ # Defaults to `:v1`.
2103
+ # @return [TargetHttpProxies::Rest::Client] A client object for the specified version.
2104
+ #
2105
+ def self.target_http_proxies version: :v1, &block
2106
+ require "google/cloud/compute/#{version.to_s.downcase}"
2107
+
2108
+ package_name = Google::Cloud::Compute
2109
+ .constants
2110
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2111
+ .first
2112
+ package_module = Google::Cloud::Compute.const_get package_name
2113
+ package_module.const_get(:TargetHttpProxies).const_get(:Rest).const_get(:Client).new(&block)
2114
+ end
2115
+
2116
+ ##
2117
+ # Create a new client object for TargetHttpsProxies.
2118
+ #
2119
+ # By default, this returns an instance of
2120
+ # [Google::Cloud::Compute::V1::TargetHttpsProxies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/TargetHttpsProxies/Rest/Client.html)
2121
+ # for version V1 of the API.
2122
+ # However, you can specify specify a different API version by passing it in the
2123
+ # `version` parameter. If the TargetHttpsProxies service is
2124
+ # supported by that API version, and the corresponding gem is available, the
2125
+ # appropriate versioned client will be returned.
2126
+ #
2127
+ # ## About TargetHttpsProxies
2128
+ #
2129
+ # The TargetHttpsProxies API.
2130
+ #
2131
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2132
+ # Defaults to `:v1`.
2133
+ # @return [TargetHttpsProxies::Rest::Client] A client object for the specified version.
2134
+ #
2135
+ def self.target_https_proxies version: :v1, &block
2136
+ require "google/cloud/compute/#{version.to_s.downcase}"
2137
+
2138
+ package_name = Google::Cloud::Compute
2139
+ .constants
2140
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2141
+ .first
2142
+ package_module = Google::Cloud::Compute.const_get package_name
2143
+ package_module.const_get(:TargetHttpsProxies).const_get(:Rest).const_get(:Client).new(&block)
2144
+ end
2145
+
2146
+ ##
2147
+ # Create a new client object for TargetInstances.
2148
+ #
2149
+ # By default, this returns an instance of
2150
+ # [Google::Cloud::Compute::V1::TargetInstances::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/TargetInstances/Rest/Client.html)
2151
+ # for version V1 of the API.
2152
+ # However, you can specify specify a different API version by passing it in the
2153
+ # `version` parameter. If the TargetInstances service is
2154
+ # supported by that API version, and the corresponding gem is available, the
2155
+ # appropriate versioned client will be returned.
2156
+ #
2157
+ # ## About TargetInstances
2158
+ #
2159
+ # The TargetInstances API.
2160
+ #
2161
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2162
+ # Defaults to `:v1`.
2163
+ # @return [TargetInstances::Rest::Client] A client object for the specified version.
2164
+ #
2165
+ def self.target_instances version: :v1, &block
2166
+ require "google/cloud/compute/#{version.to_s.downcase}"
2167
+
2168
+ package_name = Google::Cloud::Compute
2169
+ .constants
2170
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2171
+ .first
2172
+ package_module = Google::Cloud::Compute.const_get package_name
2173
+ package_module.const_get(:TargetInstances).const_get(:Rest).const_get(:Client).new(&block)
2174
+ end
2175
+
2176
+ ##
2177
+ # Create a new client object for TargetPools.
2178
+ #
2179
+ # By default, this returns an instance of
2180
+ # [Google::Cloud::Compute::V1::TargetPools::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/TargetPools/Rest/Client.html)
2181
+ # for version V1 of the API.
2182
+ # However, you can specify specify a different API version by passing it in the
2183
+ # `version` parameter. If the TargetPools service is
2184
+ # supported by that API version, and the corresponding gem is available, the
2185
+ # appropriate versioned client will be returned.
2186
+ #
2187
+ # ## About TargetPools
2188
+ #
2189
+ # The TargetPools API.
2190
+ #
2191
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2192
+ # Defaults to `:v1`.
2193
+ # @return [TargetPools::Rest::Client] A client object for the specified version.
2194
+ #
2195
+ def self.target_pools version: :v1, &block
2196
+ require "google/cloud/compute/#{version.to_s.downcase}"
2197
+
2198
+ package_name = Google::Cloud::Compute
2199
+ .constants
2200
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2201
+ .first
2202
+ package_module = Google::Cloud::Compute.const_get package_name
2203
+ package_module.const_get(:TargetPools).const_get(:Rest).const_get(:Client).new(&block)
2204
+ end
2205
+
2206
+ ##
2207
+ # Create a new client object for TargetSslProxies.
2208
+ #
2209
+ # By default, this returns an instance of
2210
+ # [Google::Cloud::Compute::V1::TargetSslProxies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/TargetSslProxies/Rest/Client.html)
2211
+ # for version V1 of the API.
2212
+ # However, you can specify specify a different API version by passing it in the
2213
+ # `version` parameter. If the TargetSslProxies service is
2214
+ # supported by that API version, and the corresponding gem is available, the
2215
+ # appropriate versioned client will be returned.
2216
+ #
2217
+ # ## About TargetSslProxies
2218
+ #
2219
+ # The TargetSslProxies API.
2220
+ #
2221
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2222
+ # Defaults to `:v1`.
2223
+ # @return [TargetSslProxies::Rest::Client] A client object for the specified version.
2224
+ #
2225
+ def self.target_ssl_proxies version: :v1, &block
2226
+ require "google/cloud/compute/#{version.to_s.downcase}"
2227
+
2228
+ package_name = Google::Cloud::Compute
2229
+ .constants
2230
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2231
+ .first
2232
+ package_module = Google::Cloud::Compute.const_get package_name
2233
+ package_module.const_get(:TargetSslProxies).const_get(:Rest).const_get(:Client).new(&block)
2234
+ end
2235
+
2236
+ ##
2237
+ # Create a new client object for TargetTcpProxies.
2238
+ #
2239
+ # By default, this returns an instance of
2240
+ # [Google::Cloud::Compute::V1::TargetTcpProxies::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/TargetTcpProxies/Rest/Client.html)
2241
+ # for version V1 of the API.
2242
+ # However, you can specify specify a different API version by passing it in the
2243
+ # `version` parameter. If the TargetTcpProxies service is
2244
+ # supported by that API version, and the corresponding gem is available, the
2245
+ # appropriate versioned client will be returned.
2246
+ #
2247
+ # ## About TargetTcpProxies
2248
+ #
2249
+ # The TargetTcpProxies API.
2250
+ #
2251
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2252
+ # Defaults to `:v1`.
2253
+ # @return [TargetTcpProxies::Rest::Client] A client object for the specified version.
2254
+ #
2255
+ def self.target_tcp_proxies version: :v1, &block
2256
+ require "google/cloud/compute/#{version.to_s.downcase}"
2257
+
2258
+ package_name = Google::Cloud::Compute
2259
+ .constants
2260
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2261
+ .first
2262
+ package_module = Google::Cloud::Compute.const_get package_name
2263
+ package_module.const_get(:TargetTcpProxies).const_get(:Rest).const_get(:Client).new(&block)
2264
+ end
2265
+
2266
+ ##
2267
+ # Create a new client object for TargetVpnGateways.
2268
+ #
2269
+ # By default, this returns an instance of
2270
+ # [Google::Cloud::Compute::V1::TargetVpnGateways::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/TargetVpnGateways/Rest/Client.html)
2271
+ # for version V1 of the API.
2272
+ # However, you can specify specify a different API version by passing it in the
2273
+ # `version` parameter. If the TargetVpnGateways service is
2274
+ # supported by that API version, and the corresponding gem is available, the
2275
+ # appropriate versioned client will be returned.
2276
+ #
2277
+ # ## About TargetVpnGateways
2278
+ #
2279
+ # The TargetVpnGateways API.
2280
+ #
2281
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2282
+ # Defaults to `:v1`.
2283
+ # @return [TargetVpnGateways::Rest::Client] A client object for the specified version.
2284
+ #
2285
+ def self.target_vpn_gateways version: :v1, &block
2286
+ require "google/cloud/compute/#{version.to_s.downcase}"
2287
+
2288
+ package_name = Google::Cloud::Compute
2289
+ .constants
2290
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2291
+ .first
2292
+ package_module = Google::Cloud::Compute.const_get package_name
2293
+ package_module.const_get(:TargetVpnGateways).const_get(:Rest).const_get(:Client).new(&block)
2294
+ end
2295
+
2296
+ ##
2297
+ # Create a new client object for UrlMaps.
2298
+ #
2299
+ # By default, this returns an instance of
2300
+ # [Google::Cloud::Compute::V1::UrlMaps::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/UrlMaps/Rest/Client.html)
2301
+ # for version V1 of the API.
2302
+ # However, you can specify specify a different API version by passing it in the
2303
+ # `version` parameter. If the UrlMaps service is
2304
+ # supported by that API version, and the corresponding gem is available, the
2305
+ # appropriate versioned client will be returned.
2306
+ #
2307
+ # ## About UrlMaps
2308
+ #
2309
+ # The UrlMaps API.
2310
+ #
2311
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2312
+ # Defaults to `:v1`.
2313
+ # @return [UrlMaps::Rest::Client] A client object for the specified version.
2314
+ #
2315
+ def self.url_maps version: :v1, &block
2316
+ require "google/cloud/compute/#{version.to_s.downcase}"
2317
+
2318
+ package_name = Google::Cloud::Compute
2319
+ .constants
2320
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2321
+ .first
2322
+ package_module = Google::Cloud::Compute.const_get package_name
2323
+ package_module.const_get(:UrlMaps).const_get(:Rest).const_get(:Client).new(&block)
2324
+ end
2325
+
2326
+ ##
2327
+ # Create a new client object for VpnGateways.
2328
+ #
2329
+ # By default, this returns an instance of
2330
+ # [Google::Cloud::Compute::V1::VpnGateways::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/VpnGateways/Rest/Client.html)
2331
+ # for version V1 of the API.
2332
+ # However, you can specify specify a different API version by passing it in the
2333
+ # `version` parameter. If the VpnGateways service is
2334
+ # supported by that API version, and the corresponding gem is available, the
2335
+ # appropriate versioned client will be returned.
2336
+ #
2337
+ # ## About VpnGateways
2338
+ #
2339
+ # The VpnGateways API.
2340
+ #
2341
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2342
+ # Defaults to `:v1`.
2343
+ # @return [VpnGateways::Rest::Client] A client object for the specified version.
2344
+ #
2345
+ def self.vpn_gateways version: :v1, &block
2346
+ require "google/cloud/compute/#{version.to_s.downcase}"
2347
+
2348
+ package_name = Google::Cloud::Compute
2349
+ .constants
2350
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2351
+ .first
2352
+ package_module = Google::Cloud::Compute.const_get package_name
2353
+ package_module.const_get(:VpnGateways).const_get(:Rest).const_get(:Client).new(&block)
2354
+ end
2355
+
2356
+ ##
2357
+ # Create a new client object for VpnTunnels.
2358
+ #
2359
+ # By default, this returns an instance of
2360
+ # [Google::Cloud::Compute::V1::VpnTunnels::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/VpnTunnels/Rest/Client.html)
2361
+ # for version V1 of the API.
2362
+ # However, you can specify specify a different API version by passing it in the
2363
+ # `version` parameter. If the VpnTunnels service is
2364
+ # supported by that API version, and the corresponding gem is available, the
2365
+ # appropriate versioned client will be returned.
2366
+ #
2367
+ # ## About VpnTunnels
2368
+ #
2369
+ # The VpnTunnels API.
2370
+ #
2371
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2372
+ # Defaults to `:v1`.
2373
+ # @return [VpnTunnels::Rest::Client] A client object for the specified version.
2374
+ #
2375
+ def self.vpn_tunnels version: :v1, &block
2376
+ require "google/cloud/compute/#{version.to_s.downcase}"
2377
+
2378
+ package_name = Google::Cloud::Compute
2379
+ .constants
2380
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2381
+ .first
2382
+ package_module = Google::Cloud::Compute.const_get package_name
2383
+ package_module.const_get(:VpnTunnels).const_get(:Rest).const_get(:Client).new(&block)
2384
+ end
2385
+
2386
+ ##
2387
+ # Create a new client object for ZoneOperations.
2388
+ #
2389
+ # By default, this returns an instance of
2390
+ # [Google::Cloud::Compute::V1::ZoneOperations::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/ZoneOperations/Rest/Client.html)
2391
+ # for version V1 of the API.
2392
+ # However, you can specify specify a different API version by passing it in the
2393
+ # `version` parameter. If the ZoneOperations service is
2394
+ # supported by that API version, and the corresponding gem is available, the
2395
+ # appropriate versioned client will be returned.
2396
+ #
2397
+ # ## About ZoneOperations
2398
+ #
2399
+ # The ZoneOperations API.
2400
+ #
2401
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2402
+ # Defaults to `:v1`.
2403
+ # @return [ZoneOperations::Rest::Client] A client object for the specified version.
2404
+ #
2405
+ def self.zone_operations version: :v1, &block
2406
+ require "google/cloud/compute/#{version.to_s.downcase}"
2407
+
2408
+ package_name = Google::Cloud::Compute
2409
+ .constants
2410
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2411
+ .first
2412
+ package_module = Google::Cloud::Compute.const_get package_name
2413
+ package_module.const_get(:ZoneOperations).const_get(:Rest).const_get(:Client).new(&block)
2414
+ end
2415
+
2416
+ ##
2417
+ # Create a new client object for Zones.
2418
+ #
2419
+ # By default, this returns an instance of
2420
+ # [Google::Cloud::Compute::V1::Zones::Rest::Client](https://googleapis.dev/ruby/google-cloud-compute-v1/latest/Google/Cloud/Compute/V1/Zones/Rest/Client.html)
2421
+ # for version V1 of the API.
2422
+ # However, you can specify specify a different API version by passing it in the
2423
+ # `version` parameter. If the Zones service is
2424
+ # supported by that API version, and the corresponding gem is available, the
2425
+ # appropriate versioned client will be returned.
2426
+ #
2427
+ # ## About Zones
2428
+ #
2429
+ # The Zones API.
2430
+ #
2431
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
2432
+ # Defaults to `:v1`.
2433
+ # @return [Zones::Rest::Client] A client object for the specified version.
2434
+ #
2435
+ def self.zones version: :v1, &block
2436
+ require "google/cloud/compute/#{version.to_s.downcase}"
2437
+
2438
+ package_name = Google::Cloud::Compute
2439
+ .constants
2440
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
2441
+ .first
2442
+ package_module = Google::Cloud::Compute.const_get package_name
2443
+ package_module.const_get(:Zones).const_get(:Rest).const_get(:Client).new(&block)
2444
+ end
2445
+
2446
+ ##
2447
+ # Configure the google-cloud-compute library.
2448
+ #
2449
+ # The following configuration parameters are supported:
2450
+ #
2451
+ # * `credentials` (*type:* `String, Hash, Google::Auth::Credentials`) -
2452
+ # The path to the keyfile as a String, the contents of the keyfile as a
2453
+ # Hash, or a Google::Auth::Credentials object.
2454
+ # * `lib_name` (*type:* `String`) -
2455
+ # The library name as recorded in instrumentation and logging.
2456
+ # * `lib_version` (*type:* `String`) -
2457
+ # The library version as recorded in instrumentation and logging.
2458
+ # * `timeout` (*type:* `Numeric`) -
2459
+ # Default timeout in seconds.
2460
+ # * `metadata` (*type:* `Hash{Symbol=>String}`) -
2461
+ # Additional REST headers to be sent with the call.
2462
+ #
2463
+ # @return [::Google::Cloud::Config] The default configuration used by this library
2464
+ #
2465
+ def self.configure
2466
+ yield ::Google::Cloud.configure.compute if block_given?
2467
+
2468
+ ::Google::Cloud.configure.compute
2469
+ end
2470
+ end
2471
+ end
2472
+ end
2473
+
2474
+ helper_path = ::File.join __dir__, "compute", "helpers.rb"
2475
+ require "google/cloud/compute/helpers" if ::File.file? helper_path