google-cloud-bigquery-analytics_hub-v1 0.3.0 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,1402 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2023 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+ require "google/cloud/bigquery/analyticshub/v1/analyticshub_pb"
20
+
21
+ module Google
22
+ module Cloud
23
+ module Bigquery
24
+ module AnalyticsHub
25
+ module V1
26
+ module AnalyticsHubService
27
+ module Rest
28
+ ##
29
+ # REST service stub for the AnalyticsHubService service.
30
+ # Service stub contains baseline method implementations
31
+ # including transcoding, making the REST call, and deserialing the response.
32
+ #
33
+ class ServiceStub
34
+ def initialize endpoint:, endpoint_template:, universe_domain:, credentials:
35
+ # These require statements are intentionally placed here to initialize
36
+ # the REST modules only when it's required.
37
+ require "gapic/rest"
38
+
39
+ @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
40
+ endpoint_template: endpoint_template,
41
+ universe_domain: universe_domain,
42
+ credentials: credentials,
43
+ numeric_enums: false,
44
+ raise_faraday_errors: false
45
+ end
46
+
47
+ ##
48
+ # The effective universe domain
49
+ #
50
+ # @return [String]
51
+ #
52
+ def universe_domain
53
+ @client_stub.universe_domain
54
+ end
55
+
56
+ ##
57
+ # Baseline implementation for the list_data_exchanges REST call
58
+ #
59
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListDataExchangesRequest]
60
+ # A request object representing the call parameters. Required.
61
+ # @param options [::Gapic::CallOptions]
62
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
63
+ #
64
+ # @yield [result, operation] Access the result along with the TransportOperation object
65
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListDataExchangesResponse]
66
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
67
+ #
68
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListDataExchangesResponse]
69
+ # A result object deserialized from the server's reply
70
+ def list_data_exchanges request_pb, options = nil
71
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
72
+
73
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_data_exchanges_request request_pb
74
+ query_string_params = if query_string_params.any?
75
+ query_string_params.to_h { |p| p.split "=", 2 }
76
+ else
77
+ {}
78
+ end
79
+
80
+ response = @client_stub.make_http_request(
81
+ verb,
82
+ uri: uri,
83
+ body: body || "",
84
+ params: query_string_params,
85
+ options: options
86
+ )
87
+ operation = ::Gapic::Rest::TransportOperation.new response
88
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::ListDataExchangesResponse.decode_json response.body, ignore_unknown_fields: true
89
+
90
+ yield result, operation if block_given?
91
+ result
92
+ end
93
+
94
+ ##
95
+ # Baseline implementation for the list_org_data_exchanges REST call
96
+ #
97
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListOrgDataExchangesRequest]
98
+ # A request object representing the call parameters. Required.
99
+ # @param options [::Gapic::CallOptions]
100
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
101
+ #
102
+ # @yield [result, operation] Access the result along with the TransportOperation object
103
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListOrgDataExchangesResponse]
104
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
105
+ #
106
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListOrgDataExchangesResponse]
107
+ # A result object deserialized from the server's reply
108
+ def list_org_data_exchanges request_pb, options = nil
109
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
110
+
111
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_org_data_exchanges_request request_pb
112
+ query_string_params = if query_string_params.any?
113
+ query_string_params.to_h { |p| p.split "=", 2 }
114
+ else
115
+ {}
116
+ end
117
+
118
+ response = @client_stub.make_http_request(
119
+ verb,
120
+ uri: uri,
121
+ body: body || "",
122
+ params: query_string_params,
123
+ options: options
124
+ )
125
+ operation = ::Gapic::Rest::TransportOperation.new response
126
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::ListOrgDataExchangesResponse.decode_json response.body, ignore_unknown_fields: true
127
+
128
+ yield result, operation if block_given?
129
+ result
130
+ end
131
+
132
+ ##
133
+ # Baseline implementation for the get_data_exchange REST call
134
+ #
135
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::GetDataExchangeRequest]
136
+ # A request object representing the call parameters. Required.
137
+ # @param options [::Gapic::CallOptions]
138
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
139
+ #
140
+ # @yield [result, operation] Access the result along with the TransportOperation object
141
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::DataExchange]
142
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
143
+ #
144
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::DataExchange]
145
+ # A result object deserialized from the server's reply
146
+ def get_data_exchange request_pb, options = nil
147
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
148
+
149
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_data_exchange_request request_pb
150
+ query_string_params = if query_string_params.any?
151
+ query_string_params.to_h { |p| p.split "=", 2 }
152
+ else
153
+ {}
154
+ end
155
+
156
+ response = @client_stub.make_http_request(
157
+ verb,
158
+ uri: uri,
159
+ body: body || "",
160
+ params: query_string_params,
161
+ options: options
162
+ )
163
+ operation = ::Gapic::Rest::TransportOperation.new response
164
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::DataExchange.decode_json response.body, ignore_unknown_fields: true
165
+
166
+ yield result, operation if block_given?
167
+ result
168
+ end
169
+
170
+ ##
171
+ # Baseline implementation for the create_data_exchange REST call
172
+ #
173
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::CreateDataExchangeRequest]
174
+ # A request object representing the call parameters. Required.
175
+ # @param options [::Gapic::CallOptions]
176
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
177
+ #
178
+ # @yield [result, operation] Access the result along with the TransportOperation object
179
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::DataExchange]
180
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
181
+ #
182
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::DataExchange]
183
+ # A result object deserialized from the server's reply
184
+ def create_data_exchange request_pb, options = nil
185
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
186
+
187
+ verb, uri, query_string_params, body = ServiceStub.transcode_create_data_exchange_request request_pb
188
+ query_string_params = if query_string_params.any?
189
+ query_string_params.to_h { |p| p.split "=", 2 }
190
+ else
191
+ {}
192
+ end
193
+
194
+ response = @client_stub.make_http_request(
195
+ verb,
196
+ uri: uri,
197
+ body: body || "",
198
+ params: query_string_params,
199
+ options: options
200
+ )
201
+ operation = ::Gapic::Rest::TransportOperation.new response
202
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::DataExchange.decode_json response.body, ignore_unknown_fields: true
203
+
204
+ yield result, operation if block_given?
205
+ result
206
+ end
207
+
208
+ ##
209
+ # Baseline implementation for the update_data_exchange REST call
210
+ #
211
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::UpdateDataExchangeRequest]
212
+ # A request object representing the call parameters. Required.
213
+ # @param options [::Gapic::CallOptions]
214
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
215
+ #
216
+ # @yield [result, operation] Access the result along with the TransportOperation object
217
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::DataExchange]
218
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
219
+ #
220
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::DataExchange]
221
+ # A result object deserialized from the server's reply
222
+ def update_data_exchange request_pb, options = nil
223
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
224
+
225
+ verb, uri, query_string_params, body = ServiceStub.transcode_update_data_exchange_request request_pb
226
+ query_string_params = if query_string_params.any?
227
+ query_string_params.to_h { |p| p.split "=", 2 }
228
+ else
229
+ {}
230
+ end
231
+
232
+ response = @client_stub.make_http_request(
233
+ verb,
234
+ uri: uri,
235
+ body: body || "",
236
+ params: query_string_params,
237
+ options: options
238
+ )
239
+ operation = ::Gapic::Rest::TransportOperation.new response
240
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::DataExchange.decode_json response.body, ignore_unknown_fields: true
241
+
242
+ yield result, operation if block_given?
243
+ result
244
+ end
245
+
246
+ ##
247
+ # Baseline implementation for the delete_data_exchange REST call
248
+ #
249
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::DeleteDataExchangeRequest]
250
+ # A request object representing the call parameters. Required.
251
+ # @param options [::Gapic::CallOptions]
252
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
253
+ #
254
+ # @yield [result, operation] Access the result along with the TransportOperation object
255
+ # @yieldparam result [::Google::Protobuf::Empty]
256
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
257
+ #
258
+ # @return [::Google::Protobuf::Empty]
259
+ # A result object deserialized from the server's reply
260
+ def delete_data_exchange request_pb, options = nil
261
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
262
+
263
+ verb, uri, query_string_params, body = ServiceStub.transcode_delete_data_exchange_request request_pb
264
+ query_string_params = if query_string_params.any?
265
+ query_string_params.to_h { |p| p.split "=", 2 }
266
+ else
267
+ {}
268
+ end
269
+
270
+ response = @client_stub.make_http_request(
271
+ verb,
272
+ uri: uri,
273
+ body: body || "",
274
+ params: query_string_params,
275
+ options: options
276
+ )
277
+ operation = ::Gapic::Rest::TransportOperation.new response
278
+ result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true
279
+
280
+ yield result, operation if block_given?
281
+ result
282
+ end
283
+
284
+ ##
285
+ # Baseline implementation for the list_listings REST call
286
+ #
287
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListListingsRequest]
288
+ # A request object representing the call parameters. Required.
289
+ # @param options [::Gapic::CallOptions]
290
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
291
+ #
292
+ # @yield [result, operation] Access the result along with the TransportOperation object
293
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListListingsResponse]
294
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
295
+ #
296
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListListingsResponse]
297
+ # A result object deserialized from the server's reply
298
+ def list_listings request_pb, options = nil
299
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
300
+
301
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_listings_request request_pb
302
+ query_string_params = if query_string_params.any?
303
+ query_string_params.to_h { |p| p.split "=", 2 }
304
+ else
305
+ {}
306
+ end
307
+
308
+ response = @client_stub.make_http_request(
309
+ verb,
310
+ uri: uri,
311
+ body: body || "",
312
+ params: query_string_params,
313
+ options: options
314
+ )
315
+ operation = ::Gapic::Rest::TransportOperation.new response
316
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::ListListingsResponse.decode_json response.body, ignore_unknown_fields: true
317
+
318
+ yield result, operation if block_given?
319
+ result
320
+ end
321
+
322
+ ##
323
+ # Baseline implementation for the get_listing REST call
324
+ #
325
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::GetListingRequest]
326
+ # A request object representing the call parameters. Required.
327
+ # @param options [::Gapic::CallOptions]
328
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
329
+ #
330
+ # @yield [result, operation] Access the result along with the TransportOperation object
331
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::Listing]
332
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
333
+ #
334
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::Listing]
335
+ # A result object deserialized from the server's reply
336
+ def get_listing request_pb, options = nil
337
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
338
+
339
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_listing_request request_pb
340
+ query_string_params = if query_string_params.any?
341
+ query_string_params.to_h { |p| p.split "=", 2 }
342
+ else
343
+ {}
344
+ end
345
+
346
+ response = @client_stub.make_http_request(
347
+ verb,
348
+ uri: uri,
349
+ body: body || "",
350
+ params: query_string_params,
351
+ options: options
352
+ )
353
+ operation = ::Gapic::Rest::TransportOperation.new response
354
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::Listing.decode_json response.body, ignore_unknown_fields: true
355
+
356
+ yield result, operation if block_given?
357
+ result
358
+ end
359
+
360
+ ##
361
+ # Baseline implementation for the create_listing REST call
362
+ #
363
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::CreateListingRequest]
364
+ # A request object representing the call parameters. Required.
365
+ # @param options [::Gapic::CallOptions]
366
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
367
+ #
368
+ # @yield [result, operation] Access the result along with the TransportOperation object
369
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::Listing]
370
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
371
+ #
372
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::Listing]
373
+ # A result object deserialized from the server's reply
374
+ def create_listing request_pb, options = nil
375
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
376
+
377
+ verb, uri, query_string_params, body = ServiceStub.transcode_create_listing_request request_pb
378
+ query_string_params = if query_string_params.any?
379
+ query_string_params.to_h { |p| p.split "=", 2 }
380
+ else
381
+ {}
382
+ end
383
+
384
+ response = @client_stub.make_http_request(
385
+ verb,
386
+ uri: uri,
387
+ body: body || "",
388
+ params: query_string_params,
389
+ options: options
390
+ )
391
+ operation = ::Gapic::Rest::TransportOperation.new response
392
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::Listing.decode_json response.body, ignore_unknown_fields: true
393
+
394
+ yield result, operation if block_given?
395
+ result
396
+ end
397
+
398
+ ##
399
+ # Baseline implementation for the update_listing REST call
400
+ #
401
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::UpdateListingRequest]
402
+ # A request object representing the call parameters. Required.
403
+ # @param options [::Gapic::CallOptions]
404
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
405
+ #
406
+ # @yield [result, operation] Access the result along with the TransportOperation object
407
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::Listing]
408
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
409
+ #
410
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::Listing]
411
+ # A result object deserialized from the server's reply
412
+ def update_listing request_pb, options = nil
413
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
414
+
415
+ verb, uri, query_string_params, body = ServiceStub.transcode_update_listing_request request_pb
416
+ query_string_params = if query_string_params.any?
417
+ query_string_params.to_h { |p| p.split "=", 2 }
418
+ else
419
+ {}
420
+ end
421
+
422
+ response = @client_stub.make_http_request(
423
+ verb,
424
+ uri: uri,
425
+ body: body || "",
426
+ params: query_string_params,
427
+ options: options
428
+ )
429
+ operation = ::Gapic::Rest::TransportOperation.new response
430
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::Listing.decode_json response.body, ignore_unknown_fields: true
431
+
432
+ yield result, operation if block_given?
433
+ result
434
+ end
435
+
436
+ ##
437
+ # Baseline implementation for the delete_listing REST call
438
+ #
439
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::DeleteListingRequest]
440
+ # A request object representing the call parameters. Required.
441
+ # @param options [::Gapic::CallOptions]
442
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
443
+ #
444
+ # @yield [result, operation] Access the result along with the TransportOperation object
445
+ # @yieldparam result [::Google::Protobuf::Empty]
446
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
447
+ #
448
+ # @return [::Google::Protobuf::Empty]
449
+ # A result object deserialized from the server's reply
450
+ def delete_listing request_pb, options = nil
451
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
452
+
453
+ verb, uri, query_string_params, body = ServiceStub.transcode_delete_listing_request request_pb
454
+ query_string_params = if query_string_params.any?
455
+ query_string_params.to_h { |p| p.split "=", 2 }
456
+ else
457
+ {}
458
+ end
459
+
460
+ response = @client_stub.make_http_request(
461
+ verb,
462
+ uri: uri,
463
+ body: body || "",
464
+ params: query_string_params,
465
+ options: options
466
+ )
467
+ operation = ::Gapic::Rest::TransportOperation.new response
468
+ result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true
469
+
470
+ yield result, operation if block_given?
471
+ result
472
+ end
473
+
474
+ ##
475
+ # Baseline implementation for the subscribe_listing REST call
476
+ #
477
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::SubscribeListingRequest]
478
+ # A request object representing the call parameters. Required.
479
+ # @param options [::Gapic::CallOptions]
480
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
481
+ #
482
+ # @yield [result, operation] Access the result along with the TransportOperation object
483
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::SubscribeListingResponse]
484
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
485
+ #
486
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::SubscribeListingResponse]
487
+ # A result object deserialized from the server's reply
488
+ def subscribe_listing request_pb, options = nil
489
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
490
+
491
+ verb, uri, query_string_params, body = ServiceStub.transcode_subscribe_listing_request request_pb
492
+ query_string_params = if query_string_params.any?
493
+ query_string_params.to_h { |p| p.split "=", 2 }
494
+ else
495
+ {}
496
+ end
497
+
498
+ response = @client_stub.make_http_request(
499
+ verb,
500
+ uri: uri,
501
+ body: body || "",
502
+ params: query_string_params,
503
+ options: options
504
+ )
505
+ operation = ::Gapic::Rest::TransportOperation.new response
506
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::SubscribeListingResponse.decode_json response.body, ignore_unknown_fields: true
507
+
508
+ yield result, operation if block_given?
509
+ result
510
+ end
511
+
512
+ ##
513
+ # Baseline implementation for the subscribe_data_exchange REST call
514
+ #
515
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::SubscribeDataExchangeRequest]
516
+ # A request object representing the call parameters. Required.
517
+ # @param options [::Gapic::CallOptions]
518
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
519
+ #
520
+ # @yield [result, operation] Access the result along with the TransportOperation object
521
+ # @yieldparam result [::Google::Longrunning::Operation]
522
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
523
+ #
524
+ # @return [::Google::Longrunning::Operation]
525
+ # A result object deserialized from the server's reply
526
+ def subscribe_data_exchange request_pb, options = nil
527
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
528
+
529
+ verb, uri, query_string_params, body = ServiceStub.transcode_subscribe_data_exchange_request request_pb
530
+ query_string_params = if query_string_params.any?
531
+ query_string_params.to_h { |p| p.split "=", 2 }
532
+ else
533
+ {}
534
+ end
535
+
536
+ response = @client_stub.make_http_request(
537
+ verb,
538
+ uri: uri,
539
+ body: body || "",
540
+ params: query_string_params,
541
+ options: options
542
+ )
543
+ operation = ::Gapic::Rest::TransportOperation.new response
544
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
545
+
546
+ yield result, operation if block_given?
547
+ result
548
+ end
549
+
550
+ ##
551
+ # Baseline implementation for the refresh_subscription REST call
552
+ #
553
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::RefreshSubscriptionRequest]
554
+ # A request object representing the call parameters. Required.
555
+ # @param options [::Gapic::CallOptions]
556
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
557
+ #
558
+ # @yield [result, operation] Access the result along with the TransportOperation object
559
+ # @yieldparam result [::Google::Longrunning::Operation]
560
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
561
+ #
562
+ # @return [::Google::Longrunning::Operation]
563
+ # A result object deserialized from the server's reply
564
+ def refresh_subscription request_pb, options = nil
565
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
566
+
567
+ verb, uri, query_string_params, body = ServiceStub.transcode_refresh_subscription_request request_pb
568
+ query_string_params = if query_string_params.any?
569
+ query_string_params.to_h { |p| p.split "=", 2 }
570
+ else
571
+ {}
572
+ end
573
+
574
+ response = @client_stub.make_http_request(
575
+ verb,
576
+ uri: uri,
577
+ body: body || "",
578
+ params: query_string_params,
579
+ options: options
580
+ )
581
+ operation = ::Gapic::Rest::TransportOperation.new response
582
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
583
+
584
+ yield result, operation if block_given?
585
+ result
586
+ end
587
+
588
+ ##
589
+ # Baseline implementation for the get_subscription REST call
590
+ #
591
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::GetSubscriptionRequest]
592
+ # A request object representing the call parameters. Required.
593
+ # @param options [::Gapic::CallOptions]
594
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
595
+ #
596
+ # @yield [result, operation] Access the result along with the TransportOperation object
597
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::Subscription]
598
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
599
+ #
600
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::Subscription]
601
+ # A result object deserialized from the server's reply
602
+ def get_subscription request_pb, options = nil
603
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
604
+
605
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_subscription_request request_pb
606
+ query_string_params = if query_string_params.any?
607
+ query_string_params.to_h { |p| p.split "=", 2 }
608
+ else
609
+ {}
610
+ end
611
+
612
+ response = @client_stub.make_http_request(
613
+ verb,
614
+ uri: uri,
615
+ body: body || "",
616
+ params: query_string_params,
617
+ options: options
618
+ )
619
+ operation = ::Gapic::Rest::TransportOperation.new response
620
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::Subscription.decode_json response.body, ignore_unknown_fields: true
621
+
622
+ yield result, operation if block_given?
623
+ result
624
+ end
625
+
626
+ ##
627
+ # Baseline implementation for the list_subscriptions REST call
628
+ #
629
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListSubscriptionsRequest]
630
+ # A request object representing the call parameters. Required.
631
+ # @param options [::Gapic::CallOptions]
632
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
633
+ #
634
+ # @yield [result, operation] Access the result along with the TransportOperation object
635
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListSubscriptionsResponse]
636
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
637
+ #
638
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListSubscriptionsResponse]
639
+ # A result object deserialized from the server's reply
640
+ def list_subscriptions request_pb, options = nil
641
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
642
+
643
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_subscriptions_request request_pb
644
+ query_string_params = if query_string_params.any?
645
+ query_string_params.to_h { |p| p.split "=", 2 }
646
+ else
647
+ {}
648
+ end
649
+
650
+ response = @client_stub.make_http_request(
651
+ verb,
652
+ uri: uri,
653
+ body: body || "",
654
+ params: query_string_params,
655
+ options: options
656
+ )
657
+ operation = ::Gapic::Rest::TransportOperation.new response
658
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::ListSubscriptionsResponse.decode_json response.body, ignore_unknown_fields: true
659
+
660
+ yield result, operation if block_given?
661
+ result
662
+ end
663
+
664
+ ##
665
+ # Baseline implementation for the list_shared_resource_subscriptions REST call
666
+ #
667
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListSharedResourceSubscriptionsRequest]
668
+ # A request object representing the call parameters. Required.
669
+ # @param options [::Gapic::CallOptions]
670
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
671
+ #
672
+ # @yield [result, operation] Access the result along with the TransportOperation object
673
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListSharedResourceSubscriptionsResponse]
674
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
675
+ #
676
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListSharedResourceSubscriptionsResponse]
677
+ # A result object deserialized from the server's reply
678
+ def list_shared_resource_subscriptions request_pb, options = nil
679
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
680
+
681
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_shared_resource_subscriptions_request request_pb
682
+ query_string_params = if query_string_params.any?
683
+ query_string_params.to_h { |p| p.split "=", 2 }
684
+ else
685
+ {}
686
+ end
687
+
688
+ response = @client_stub.make_http_request(
689
+ verb,
690
+ uri: uri,
691
+ body: body || "",
692
+ params: query_string_params,
693
+ options: options
694
+ )
695
+ operation = ::Gapic::Rest::TransportOperation.new response
696
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::ListSharedResourceSubscriptionsResponse.decode_json response.body, ignore_unknown_fields: true
697
+
698
+ yield result, operation if block_given?
699
+ result
700
+ end
701
+
702
+ ##
703
+ # Baseline implementation for the revoke_subscription REST call
704
+ #
705
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::RevokeSubscriptionRequest]
706
+ # A request object representing the call parameters. Required.
707
+ # @param options [::Gapic::CallOptions]
708
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
709
+ #
710
+ # @yield [result, operation] Access the result along with the TransportOperation object
711
+ # @yieldparam result [::Google::Cloud::Bigquery::AnalyticsHub::V1::RevokeSubscriptionResponse]
712
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
713
+ #
714
+ # @return [::Google::Cloud::Bigquery::AnalyticsHub::V1::RevokeSubscriptionResponse]
715
+ # A result object deserialized from the server's reply
716
+ def revoke_subscription request_pb, options = nil
717
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
718
+
719
+ verb, uri, query_string_params, body = ServiceStub.transcode_revoke_subscription_request request_pb
720
+ query_string_params = if query_string_params.any?
721
+ query_string_params.to_h { |p| p.split "=", 2 }
722
+ else
723
+ {}
724
+ end
725
+
726
+ response = @client_stub.make_http_request(
727
+ verb,
728
+ uri: uri,
729
+ body: body || "",
730
+ params: query_string_params,
731
+ options: options
732
+ )
733
+ operation = ::Gapic::Rest::TransportOperation.new response
734
+ result = ::Google::Cloud::Bigquery::AnalyticsHub::V1::RevokeSubscriptionResponse.decode_json response.body, ignore_unknown_fields: true
735
+
736
+ yield result, operation if block_given?
737
+ result
738
+ end
739
+
740
+ ##
741
+ # Baseline implementation for the delete_subscription REST call
742
+ #
743
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::DeleteSubscriptionRequest]
744
+ # A request object representing the call parameters. Required.
745
+ # @param options [::Gapic::CallOptions]
746
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
747
+ #
748
+ # @yield [result, operation] Access the result along with the TransportOperation object
749
+ # @yieldparam result [::Google::Longrunning::Operation]
750
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
751
+ #
752
+ # @return [::Google::Longrunning::Operation]
753
+ # A result object deserialized from the server's reply
754
+ def delete_subscription request_pb, options = nil
755
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
756
+
757
+ verb, uri, query_string_params, body = ServiceStub.transcode_delete_subscription_request request_pb
758
+ query_string_params = if query_string_params.any?
759
+ query_string_params.to_h { |p| p.split "=", 2 }
760
+ else
761
+ {}
762
+ end
763
+
764
+ response = @client_stub.make_http_request(
765
+ verb,
766
+ uri: uri,
767
+ body: body || "",
768
+ params: query_string_params,
769
+ options: options
770
+ )
771
+ operation = ::Gapic::Rest::TransportOperation.new response
772
+ result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
773
+
774
+ yield result, operation if block_given?
775
+ result
776
+ end
777
+
778
+ ##
779
+ # Baseline implementation for the get_iam_policy REST call
780
+ #
781
+ # @param request_pb [::Google::Iam::V1::GetIamPolicyRequest]
782
+ # A request object representing the call parameters. Required.
783
+ # @param options [::Gapic::CallOptions]
784
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
785
+ #
786
+ # @yield [result, operation] Access the result along with the TransportOperation object
787
+ # @yieldparam result [::Google::Iam::V1::Policy]
788
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
789
+ #
790
+ # @return [::Google::Iam::V1::Policy]
791
+ # A result object deserialized from the server's reply
792
+ def get_iam_policy request_pb, options = nil
793
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
794
+
795
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_iam_policy_request request_pb
796
+ query_string_params = if query_string_params.any?
797
+ query_string_params.to_h { |p| p.split "=", 2 }
798
+ else
799
+ {}
800
+ end
801
+
802
+ response = @client_stub.make_http_request(
803
+ verb,
804
+ uri: uri,
805
+ body: body || "",
806
+ params: query_string_params,
807
+ options: options
808
+ )
809
+ operation = ::Gapic::Rest::TransportOperation.new response
810
+ result = ::Google::Iam::V1::Policy.decode_json response.body, ignore_unknown_fields: true
811
+
812
+ yield result, operation if block_given?
813
+ result
814
+ end
815
+
816
+ ##
817
+ # Baseline implementation for the set_iam_policy REST call
818
+ #
819
+ # @param request_pb [::Google::Iam::V1::SetIamPolicyRequest]
820
+ # A request object representing the call parameters. Required.
821
+ # @param options [::Gapic::CallOptions]
822
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
823
+ #
824
+ # @yield [result, operation] Access the result along with the TransportOperation object
825
+ # @yieldparam result [::Google::Iam::V1::Policy]
826
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
827
+ #
828
+ # @return [::Google::Iam::V1::Policy]
829
+ # A result object deserialized from the server's reply
830
+ def set_iam_policy request_pb, options = nil
831
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
832
+
833
+ verb, uri, query_string_params, body = ServiceStub.transcode_set_iam_policy_request request_pb
834
+ query_string_params = if query_string_params.any?
835
+ query_string_params.to_h { |p| p.split "=", 2 }
836
+ else
837
+ {}
838
+ end
839
+
840
+ response = @client_stub.make_http_request(
841
+ verb,
842
+ uri: uri,
843
+ body: body || "",
844
+ params: query_string_params,
845
+ options: options
846
+ )
847
+ operation = ::Gapic::Rest::TransportOperation.new response
848
+ result = ::Google::Iam::V1::Policy.decode_json response.body, ignore_unknown_fields: true
849
+
850
+ yield result, operation if block_given?
851
+ result
852
+ end
853
+
854
+ ##
855
+ # Baseline implementation for the test_iam_permissions REST call
856
+ #
857
+ # @param request_pb [::Google::Iam::V1::TestIamPermissionsRequest]
858
+ # A request object representing the call parameters. Required.
859
+ # @param options [::Gapic::CallOptions]
860
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
861
+ #
862
+ # @yield [result, operation] Access the result along with the TransportOperation object
863
+ # @yieldparam result [::Google::Iam::V1::TestIamPermissionsResponse]
864
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
865
+ #
866
+ # @return [::Google::Iam::V1::TestIamPermissionsResponse]
867
+ # A result object deserialized from the server's reply
868
+ def test_iam_permissions request_pb, options = nil
869
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
870
+
871
+ verb, uri, query_string_params, body = ServiceStub.transcode_test_iam_permissions_request request_pb
872
+ query_string_params = if query_string_params.any?
873
+ query_string_params.to_h { |p| p.split "=", 2 }
874
+ else
875
+ {}
876
+ end
877
+
878
+ response = @client_stub.make_http_request(
879
+ verb,
880
+ uri: uri,
881
+ body: body || "",
882
+ params: query_string_params,
883
+ options: options
884
+ )
885
+ operation = ::Gapic::Rest::TransportOperation.new response
886
+ result = ::Google::Iam::V1::TestIamPermissionsResponse.decode_json response.body, ignore_unknown_fields: true
887
+
888
+ yield result, operation if block_given?
889
+ result
890
+ end
891
+
892
+ ##
893
+ # @private
894
+ #
895
+ # GRPC transcoding helper method for the list_data_exchanges REST call
896
+ #
897
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListDataExchangesRequest]
898
+ # A request object representing the call parameters. Required.
899
+ # @return [Array(String, [String, nil], Hash{String => String})]
900
+ # Uri, Body, Query string parameters
901
+ def self.transcode_list_data_exchanges_request request_pb
902
+ transcoder = Gapic::Rest::GrpcTranscoder.new
903
+ .with_bindings(
904
+ uri_method: :get,
905
+ uri_template: "/v1/{parent}/dataExchanges",
906
+ matches: [
907
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
908
+ ]
909
+ )
910
+ transcoder.transcode request_pb
911
+ end
912
+
913
+ ##
914
+ # @private
915
+ #
916
+ # GRPC transcoding helper method for the list_org_data_exchanges REST call
917
+ #
918
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListOrgDataExchangesRequest]
919
+ # A request object representing the call parameters. Required.
920
+ # @return [Array(String, [String, nil], Hash{String => String})]
921
+ # Uri, Body, Query string parameters
922
+ def self.transcode_list_org_data_exchanges_request request_pb
923
+ transcoder = Gapic::Rest::GrpcTranscoder.new
924
+ .with_bindings(
925
+ uri_method: :get,
926
+ uri_template: "/v1/{organization}/dataExchanges",
927
+ matches: [
928
+ ["organization", %r{^organizations/[^/]+/locations/[^/]+/?$}, false]
929
+ ]
930
+ )
931
+ transcoder.transcode request_pb
932
+ end
933
+
934
+ ##
935
+ # @private
936
+ #
937
+ # GRPC transcoding helper method for the get_data_exchange REST call
938
+ #
939
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::GetDataExchangeRequest]
940
+ # A request object representing the call parameters. Required.
941
+ # @return [Array(String, [String, nil], Hash{String => String})]
942
+ # Uri, Body, Query string parameters
943
+ def self.transcode_get_data_exchange_request request_pb
944
+ transcoder = Gapic::Rest::GrpcTranscoder.new
945
+ .with_bindings(
946
+ uri_method: :get,
947
+ uri_template: "/v1/{name}",
948
+ matches: [
949
+ ["name", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/?$}, false]
950
+ ]
951
+ )
952
+ transcoder.transcode request_pb
953
+ end
954
+
955
+ ##
956
+ # @private
957
+ #
958
+ # GRPC transcoding helper method for the create_data_exchange REST call
959
+ #
960
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::CreateDataExchangeRequest]
961
+ # A request object representing the call parameters. Required.
962
+ # @return [Array(String, [String, nil], Hash{String => String})]
963
+ # Uri, Body, Query string parameters
964
+ def self.transcode_create_data_exchange_request request_pb
965
+ transcoder = Gapic::Rest::GrpcTranscoder.new
966
+ .with_bindings(
967
+ uri_method: :post,
968
+ uri_template: "/v1/{parent}/dataExchanges",
969
+ body: "data_exchange",
970
+ matches: [
971
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
972
+ ]
973
+ )
974
+ transcoder.transcode request_pb
975
+ end
976
+
977
+ ##
978
+ # @private
979
+ #
980
+ # GRPC transcoding helper method for the update_data_exchange REST call
981
+ #
982
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::UpdateDataExchangeRequest]
983
+ # A request object representing the call parameters. Required.
984
+ # @return [Array(String, [String, nil], Hash{String => String})]
985
+ # Uri, Body, Query string parameters
986
+ def self.transcode_update_data_exchange_request request_pb
987
+ transcoder = Gapic::Rest::GrpcTranscoder.new
988
+ .with_bindings(
989
+ uri_method: :patch,
990
+ uri_template: "/v1/{data_exchange.name}",
991
+ body: "data_exchange",
992
+ matches: [
993
+ ["data_exchange.name", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/?$}, false]
994
+ ]
995
+ )
996
+ transcoder.transcode request_pb
997
+ end
998
+
999
+ ##
1000
+ # @private
1001
+ #
1002
+ # GRPC transcoding helper method for the delete_data_exchange REST call
1003
+ #
1004
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::DeleteDataExchangeRequest]
1005
+ # A request object representing the call parameters. Required.
1006
+ # @return [Array(String, [String, nil], Hash{String => String})]
1007
+ # Uri, Body, Query string parameters
1008
+ def self.transcode_delete_data_exchange_request request_pb
1009
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1010
+ .with_bindings(
1011
+ uri_method: :delete,
1012
+ uri_template: "/v1/{name}",
1013
+ matches: [
1014
+ ["name", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/?$}, false]
1015
+ ]
1016
+ )
1017
+ transcoder.transcode request_pb
1018
+ end
1019
+
1020
+ ##
1021
+ # @private
1022
+ #
1023
+ # GRPC transcoding helper method for the list_listings REST call
1024
+ #
1025
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListListingsRequest]
1026
+ # A request object representing the call parameters. Required.
1027
+ # @return [Array(String, [String, nil], Hash{String => String})]
1028
+ # Uri, Body, Query string parameters
1029
+ def self.transcode_list_listings_request request_pb
1030
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1031
+ .with_bindings(
1032
+ uri_method: :get,
1033
+ uri_template: "/v1/{parent}/listings",
1034
+ matches: [
1035
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/?$}, false]
1036
+ ]
1037
+ )
1038
+ transcoder.transcode request_pb
1039
+ end
1040
+
1041
+ ##
1042
+ # @private
1043
+ #
1044
+ # GRPC transcoding helper method for the get_listing REST call
1045
+ #
1046
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::GetListingRequest]
1047
+ # A request object representing the call parameters. Required.
1048
+ # @return [Array(String, [String, nil], Hash{String => String})]
1049
+ # Uri, Body, Query string parameters
1050
+ def self.transcode_get_listing_request request_pb
1051
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1052
+ .with_bindings(
1053
+ uri_method: :get,
1054
+ uri_template: "/v1/{name}",
1055
+ matches: [
1056
+ ["name", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/listings/[^/]+/?$}, false]
1057
+ ]
1058
+ )
1059
+ transcoder.transcode request_pb
1060
+ end
1061
+
1062
+ ##
1063
+ # @private
1064
+ #
1065
+ # GRPC transcoding helper method for the create_listing REST call
1066
+ #
1067
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::CreateListingRequest]
1068
+ # A request object representing the call parameters. Required.
1069
+ # @return [Array(String, [String, nil], Hash{String => String})]
1070
+ # Uri, Body, Query string parameters
1071
+ def self.transcode_create_listing_request request_pb
1072
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1073
+ .with_bindings(
1074
+ uri_method: :post,
1075
+ uri_template: "/v1/{parent}/listings",
1076
+ body: "listing",
1077
+ matches: [
1078
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/?$}, false]
1079
+ ]
1080
+ )
1081
+ transcoder.transcode request_pb
1082
+ end
1083
+
1084
+ ##
1085
+ # @private
1086
+ #
1087
+ # GRPC transcoding helper method for the update_listing REST call
1088
+ #
1089
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::UpdateListingRequest]
1090
+ # A request object representing the call parameters. Required.
1091
+ # @return [Array(String, [String, nil], Hash{String => String})]
1092
+ # Uri, Body, Query string parameters
1093
+ def self.transcode_update_listing_request request_pb
1094
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1095
+ .with_bindings(
1096
+ uri_method: :patch,
1097
+ uri_template: "/v1/{listing.name}",
1098
+ body: "listing",
1099
+ matches: [
1100
+ ["listing.name", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/listings/[^/]+/?$}, false]
1101
+ ]
1102
+ )
1103
+ transcoder.transcode request_pb
1104
+ end
1105
+
1106
+ ##
1107
+ # @private
1108
+ #
1109
+ # GRPC transcoding helper method for the delete_listing REST call
1110
+ #
1111
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::DeleteListingRequest]
1112
+ # A request object representing the call parameters. Required.
1113
+ # @return [Array(String, [String, nil], Hash{String => String})]
1114
+ # Uri, Body, Query string parameters
1115
+ def self.transcode_delete_listing_request request_pb
1116
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1117
+ .with_bindings(
1118
+ uri_method: :delete,
1119
+ uri_template: "/v1/{name}",
1120
+ matches: [
1121
+ ["name", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/listings/[^/]+/?$}, false]
1122
+ ]
1123
+ )
1124
+ transcoder.transcode request_pb
1125
+ end
1126
+
1127
+ ##
1128
+ # @private
1129
+ #
1130
+ # GRPC transcoding helper method for the subscribe_listing REST call
1131
+ #
1132
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::SubscribeListingRequest]
1133
+ # A request object representing the call parameters. Required.
1134
+ # @return [Array(String, [String, nil], Hash{String => String})]
1135
+ # Uri, Body, Query string parameters
1136
+ def self.transcode_subscribe_listing_request request_pb
1137
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1138
+ .with_bindings(
1139
+ uri_method: :post,
1140
+ uri_template: "/v1/{name}:subscribe",
1141
+ body: "*",
1142
+ matches: [
1143
+ ["name", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/listings/[^/]+/?$}, false]
1144
+ ]
1145
+ )
1146
+ transcoder.transcode request_pb
1147
+ end
1148
+
1149
+ ##
1150
+ # @private
1151
+ #
1152
+ # GRPC transcoding helper method for the subscribe_data_exchange REST call
1153
+ #
1154
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::SubscribeDataExchangeRequest]
1155
+ # A request object representing the call parameters. Required.
1156
+ # @return [Array(String, [String, nil], Hash{String => String})]
1157
+ # Uri, Body, Query string parameters
1158
+ def self.transcode_subscribe_data_exchange_request request_pb
1159
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1160
+ .with_bindings(
1161
+ uri_method: :post,
1162
+ uri_template: "/v1/{name}:subscribe",
1163
+ body: "*",
1164
+ matches: [
1165
+ ["name", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/?$}, false]
1166
+ ]
1167
+ )
1168
+ transcoder.transcode request_pb
1169
+ end
1170
+
1171
+ ##
1172
+ # @private
1173
+ #
1174
+ # GRPC transcoding helper method for the refresh_subscription REST call
1175
+ #
1176
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::RefreshSubscriptionRequest]
1177
+ # A request object representing the call parameters. Required.
1178
+ # @return [Array(String, [String, nil], Hash{String => String})]
1179
+ # Uri, Body, Query string parameters
1180
+ def self.transcode_refresh_subscription_request request_pb
1181
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1182
+ .with_bindings(
1183
+ uri_method: :post,
1184
+ uri_template: "/v1/{name}:refresh",
1185
+ body: "*",
1186
+ matches: [
1187
+ ["name", %r{^projects/[^/]+/locations/[^/]+/subscriptions/[^/]+/?$}, false]
1188
+ ]
1189
+ )
1190
+ transcoder.transcode request_pb
1191
+ end
1192
+
1193
+ ##
1194
+ # @private
1195
+ #
1196
+ # GRPC transcoding helper method for the get_subscription REST call
1197
+ #
1198
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::GetSubscriptionRequest]
1199
+ # A request object representing the call parameters. Required.
1200
+ # @return [Array(String, [String, nil], Hash{String => String})]
1201
+ # Uri, Body, Query string parameters
1202
+ def self.transcode_get_subscription_request request_pb
1203
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1204
+ .with_bindings(
1205
+ uri_method: :get,
1206
+ uri_template: "/v1/{name}",
1207
+ matches: [
1208
+ ["name", %r{^projects/[^/]+/locations/[^/]+/subscriptions/[^/]+/?$}, false]
1209
+ ]
1210
+ )
1211
+ transcoder.transcode request_pb
1212
+ end
1213
+
1214
+ ##
1215
+ # @private
1216
+ #
1217
+ # GRPC transcoding helper method for the list_subscriptions REST call
1218
+ #
1219
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListSubscriptionsRequest]
1220
+ # A request object representing the call parameters. Required.
1221
+ # @return [Array(String, [String, nil], Hash{String => String})]
1222
+ # Uri, Body, Query string parameters
1223
+ def self.transcode_list_subscriptions_request request_pb
1224
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1225
+ .with_bindings(
1226
+ uri_method: :get,
1227
+ uri_template: "/v1/{parent}/subscriptions",
1228
+ matches: [
1229
+ ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
1230
+ ]
1231
+ )
1232
+ transcoder.transcode request_pb
1233
+ end
1234
+
1235
+ ##
1236
+ # @private
1237
+ #
1238
+ # GRPC transcoding helper method for the list_shared_resource_subscriptions REST call
1239
+ #
1240
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::ListSharedResourceSubscriptionsRequest]
1241
+ # A request object representing the call parameters. Required.
1242
+ # @return [Array(String, [String, nil], Hash{String => String})]
1243
+ # Uri, Body, Query string parameters
1244
+ def self.transcode_list_shared_resource_subscriptions_request request_pb
1245
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1246
+ .with_bindings(
1247
+ uri_method: :get,
1248
+ uri_template: "/v1/{resource}:listSubscriptions",
1249
+ matches: [
1250
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/?$}, false]
1251
+ ]
1252
+ )
1253
+ .with_bindings(
1254
+ uri_method: :get,
1255
+ uri_template: "/v1/{resource}:listSubscriptions",
1256
+ matches: [
1257
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/listings/[^/]+/?$}, false]
1258
+ ]
1259
+ )
1260
+ transcoder.transcode request_pb
1261
+ end
1262
+
1263
+ ##
1264
+ # @private
1265
+ #
1266
+ # GRPC transcoding helper method for the revoke_subscription REST call
1267
+ #
1268
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::RevokeSubscriptionRequest]
1269
+ # A request object representing the call parameters. Required.
1270
+ # @return [Array(String, [String, nil], Hash{String => String})]
1271
+ # Uri, Body, Query string parameters
1272
+ def self.transcode_revoke_subscription_request request_pb
1273
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1274
+ .with_bindings(
1275
+ uri_method: :post,
1276
+ uri_template: "/v1/{name}:revoke",
1277
+ body: "*",
1278
+ matches: [
1279
+ ["name", %r{^projects/[^/]+/locations/[^/]+/subscriptions/[^/]+/?$}, false]
1280
+ ]
1281
+ )
1282
+ transcoder.transcode request_pb
1283
+ end
1284
+
1285
+ ##
1286
+ # @private
1287
+ #
1288
+ # GRPC transcoding helper method for the delete_subscription REST call
1289
+ #
1290
+ # @param request_pb [::Google::Cloud::Bigquery::AnalyticsHub::V1::DeleteSubscriptionRequest]
1291
+ # A request object representing the call parameters. Required.
1292
+ # @return [Array(String, [String, nil], Hash{String => String})]
1293
+ # Uri, Body, Query string parameters
1294
+ def self.transcode_delete_subscription_request request_pb
1295
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1296
+ .with_bindings(
1297
+ uri_method: :delete,
1298
+ uri_template: "/v1/{name}",
1299
+ matches: [
1300
+ ["name", %r{^projects/[^/]+/locations/[^/]+/subscriptions/[^/]+/?$}, false]
1301
+ ]
1302
+ )
1303
+ transcoder.transcode request_pb
1304
+ end
1305
+
1306
+ ##
1307
+ # @private
1308
+ #
1309
+ # GRPC transcoding helper method for the get_iam_policy REST call
1310
+ #
1311
+ # @param request_pb [::Google::Iam::V1::GetIamPolicyRequest]
1312
+ # A request object representing the call parameters. Required.
1313
+ # @return [Array(String, [String, nil], Hash{String => String})]
1314
+ # Uri, Body, Query string parameters
1315
+ def self.transcode_get_iam_policy_request request_pb
1316
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1317
+ .with_bindings(
1318
+ uri_method: :post,
1319
+ uri_template: "/v1/{resource}:getIamPolicy",
1320
+ body: "*",
1321
+ matches: [
1322
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/?$}, false]
1323
+ ]
1324
+ )
1325
+ .with_bindings(
1326
+ uri_method: :post,
1327
+ uri_template: "/v1/{resource}:getIamPolicy",
1328
+ body: "*",
1329
+ matches: [
1330
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/listings/[^/]+/?$}, false]
1331
+ ]
1332
+ )
1333
+ transcoder.transcode request_pb
1334
+ end
1335
+
1336
+ ##
1337
+ # @private
1338
+ #
1339
+ # GRPC transcoding helper method for the set_iam_policy REST call
1340
+ #
1341
+ # @param request_pb [::Google::Iam::V1::SetIamPolicyRequest]
1342
+ # A request object representing the call parameters. Required.
1343
+ # @return [Array(String, [String, nil], Hash{String => String})]
1344
+ # Uri, Body, Query string parameters
1345
+ def self.transcode_set_iam_policy_request request_pb
1346
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1347
+ .with_bindings(
1348
+ uri_method: :post,
1349
+ uri_template: "/v1/{resource}:setIamPolicy",
1350
+ body: "*",
1351
+ matches: [
1352
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/?$}, false]
1353
+ ]
1354
+ )
1355
+ .with_bindings(
1356
+ uri_method: :post,
1357
+ uri_template: "/v1/{resource}:setIamPolicy",
1358
+ body: "*",
1359
+ matches: [
1360
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/listings/[^/]+/?$}, false]
1361
+ ]
1362
+ )
1363
+ transcoder.transcode request_pb
1364
+ end
1365
+
1366
+ ##
1367
+ # @private
1368
+ #
1369
+ # GRPC transcoding helper method for the test_iam_permissions REST call
1370
+ #
1371
+ # @param request_pb [::Google::Iam::V1::TestIamPermissionsRequest]
1372
+ # A request object representing the call parameters. Required.
1373
+ # @return [Array(String, [String, nil], Hash{String => String})]
1374
+ # Uri, Body, Query string parameters
1375
+ def self.transcode_test_iam_permissions_request request_pb
1376
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1377
+ .with_bindings(
1378
+ uri_method: :post,
1379
+ uri_template: "/v1/{resource}:testIamPermissions",
1380
+ body: "*",
1381
+ matches: [
1382
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/?$}, false]
1383
+ ]
1384
+ )
1385
+ .with_bindings(
1386
+ uri_method: :post,
1387
+ uri_template: "/v1/{resource}:testIamPermissions",
1388
+ body: "*",
1389
+ matches: [
1390
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/dataExchanges/[^/]+/listings/[^/]+/?$}, false]
1391
+ ]
1392
+ )
1393
+ transcoder.transcode request_pb
1394
+ end
1395
+ end
1396
+ end
1397
+ end
1398
+ end
1399
+ end
1400
+ end
1401
+ end
1402
+ end