google-cloud-bigquery-connection-v1 0.11.0 → 0.13.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.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/google/cloud/bigquery/connection/v1/connection_pb.rb +15 -0
- data/lib/google/cloud/bigquery/connection/v1/connection_service/client.rb +2 -2
- data/lib/google/cloud/bigquery/connection/v1/connection_service/paths.rb +38 -0
- data/lib/google/cloud/bigquery/connection/v1/connection_service/rest/client.rb +906 -0
- data/lib/google/cloud/bigquery/connection/v1/connection_service/rest/service_stub.rb +527 -0
- data/lib/google/cloud/bigquery/connection/v1/connection_service/rest.rb +54 -0
- data/lib/google/cloud/bigquery/connection/v1/connection_service.rb +6 -0
- data/lib/google/cloud/bigquery/connection/v1/rest.rb +39 -0
- data/lib/google/cloud/bigquery/connection/v1/version.rb +1 -1
- data/lib/google/cloud/bigquery/connection/v1.rb +5 -0
- data/proto_docs/google/api/client.rb +9 -3
- data/proto_docs/google/cloud/bigquery/connection/v1/connection.rb +56 -0
- data/proto_docs/google/iam/v1/policy.rb +8 -4
- metadata +6 -2
@@ -0,0 +1,527 @@
|
|
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/connection/v1/connection_pb"
|
20
|
+
|
21
|
+
module Google
|
22
|
+
module Cloud
|
23
|
+
module Bigquery
|
24
|
+
module Connection
|
25
|
+
module V1
|
26
|
+
module ConnectionService
|
27
|
+
module Rest
|
28
|
+
##
|
29
|
+
# REST service stub for the ConnectionService 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:, 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, credentials: credentials,
|
40
|
+
numeric_enums: true,
|
41
|
+
raise_faraday_errors: false
|
42
|
+
end
|
43
|
+
|
44
|
+
##
|
45
|
+
# Baseline implementation for the create_connection REST call
|
46
|
+
#
|
47
|
+
# @param request_pb [::Google::Cloud::Bigquery::Connection::V1::CreateConnectionRequest]
|
48
|
+
# A request object representing the call parameters. Required.
|
49
|
+
# @param options [::Gapic::CallOptions]
|
50
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
51
|
+
#
|
52
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
53
|
+
# @yieldparam result [::Google::Cloud::Bigquery::Connection::V1::Connection]
|
54
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
55
|
+
#
|
56
|
+
# @return [::Google::Cloud::Bigquery::Connection::V1::Connection]
|
57
|
+
# A result object deserialized from the server's reply
|
58
|
+
def create_connection request_pb, options = nil
|
59
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
60
|
+
|
61
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_create_connection_request request_pb
|
62
|
+
query_string_params = if query_string_params.any?
|
63
|
+
query_string_params.to_h { |p| p.split("=", 2) }
|
64
|
+
else
|
65
|
+
{}
|
66
|
+
end
|
67
|
+
|
68
|
+
response = @client_stub.make_http_request(
|
69
|
+
verb,
|
70
|
+
uri: uri,
|
71
|
+
body: body || "",
|
72
|
+
params: query_string_params,
|
73
|
+
options: options
|
74
|
+
)
|
75
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
76
|
+
result = ::Google::Cloud::Bigquery::Connection::V1::Connection.decode_json response.body, ignore_unknown_fields: true
|
77
|
+
|
78
|
+
yield result, operation if block_given?
|
79
|
+
result
|
80
|
+
end
|
81
|
+
|
82
|
+
##
|
83
|
+
# Baseline implementation for the get_connection REST call
|
84
|
+
#
|
85
|
+
# @param request_pb [::Google::Cloud::Bigquery::Connection::V1::GetConnectionRequest]
|
86
|
+
# A request object representing the call parameters. Required.
|
87
|
+
# @param options [::Gapic::CallOptions]
|
88
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
89
|
+
#
|
90
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
91
|
+
# @yieldparam result [::Google::Cloud::Bigquery::Connection::V1::Connection]
|
92
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
93
|
+
#
|
94
|
+
# @return [::Google::Cloud::Bigquery::Connection::V1::Connection]
|
95
|
+
# A result object deserialized from the server's reply
|
96
|
+
def get_connection request_pb, options = nil
|
97
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
98
|
+
|
99
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_connection_request request_pb
|
100
|
+
query_string_params = if query_string_params.any?
|
101
|
+
query_string_params.to_h { |p| p.split("=", 2) }
|
102
|
+
else
|
103
|
+
{}
|
104
|
+
end
|
105
|
+
|
106
|
+
response = @client_stub.make_http_request(
|
107
|
+
verb,
|
108
|
+
uri: uri,
|
109
|
+
body: body || "",
|
110
|
+
params: query_string_params,
|
111
|
+
options: options
|
112
|
+
)
|
113
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
114
|
+
result = ::Google::Cloud::Bigquery::Connection::V1::Connection.decode_json response.body, ignore_unknown_fields: true
|
115
|
+
|
116
|
+
yield result, operation if block_given?
|
117
|
+
result
|
118
|
+
end
|
119
|
+
|
120
|
+
##
|
121
|
+
# Baseline implementation for the list_connections REST call
|
122
|
+
#
|
123
|
+
# @param request_pb [::Google::Cloud::Bigquery::Connection::V1::ListConnectionsRequest]
|
124
|
+
# A request object representing the call parameters. Required.
|
125
|
+
# @param options [::Gapic::CallOptions]
|
126
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
127
|
+
#
|
128
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
129
|
+
# @yieldparam result [::Google::Cloud::Bigquery::Connection::V1::ListConnectionsResponse]
|
130
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
131
|
+
#
|
132
|
+
# @return [::Google::Cloud::Bigquery::Connection::V1::ListConnectionsResponse]
|
133
|
+
# A result object deserialized from the server's reply
|
134
|
+
def list_connections request_pb, options = nil
|
135
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
136
|
+
|
137
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_connections_request request_pb
|
138
|
+
query_string_params = if query_string_params.any?
|
139
|
+
query_string_params.to_h { |p| p.split("=", 2) }
|
140
|
+
else
|
141
|
+
{}
|
142
|
+
end
|
143
|
+
|
144
|
+
response = @client_stub.make_http_request(
|
145
|
+
verb,
|
146
|
+
uri: uri,
|
147
|
+
body: body || "",
|
148
|
+
params: query_string_params,
|
149
|
+
options: options
|
150
|
+
)
|
151
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
152
|
+
result = ::Google::Cloud::Bigquery::Connection::V1::ListConnectionsResponse.decode_json response.body, ignore_unknown_fields: true
|
153
|
+
|
154
|
+
yield result, operation if block_given?
|
155
|
+
result
|
156
|
+
end
|
157
|
+
|
158
|
+
##
|
159
|
+
# Baseline implementation for the update_connection REST call
|
160
|
+
#
|
161
|
+
# @param request_pb [::Google::Cloud::Bigquery::Connection::V1::UpdateConnectionRequest]
|
162
|
+
# A request object representing the call parameters. Required.
|
163
|
+
# @param options [::Gapic::CallOptions]
|
164
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
165
|
+
#
|
166
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
167
|
+
# @yieldparam result [::Google::Cloud::Bigquery::Connection::V1::Connection]
|
168
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
169
|
+
#
|
170
|
+
# @return [::Google::Cloud::Bigquery::Connection::V1::Connection]
|
171
|
+
# A result object deserialized from the server's reply
|
172
|
+
def update_connection request_pb, options = nil
|
173
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
174
|
+
|
175
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_update_connection_request request_pb
|
176
|
+
query_string_params = if query_string_params.any?
|
177
|
+
query_string_params.to_h { |p| p.split("=", 2) }
|
178
|
+
else
|
179
|
+
{}
|
180
|
+
end
|
181
|
+
|
182
|
+
response = @client_stub.make_http_request(
|
183
|
+
verb,
|
184
|
+
uri: uri,
|
185
|
+
body: body || "",
|
186
|
+
params: query_string_params,
|
187
|
+
options: options
|
188
|
+
)
|
189
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
190
|
+
result = ::Google::Cloud::Bigquery::Connection::V1::Connection.decode_json response.body, ignore_unknown_fields: true
|
191
|
+
|
192
|
+
yield result, operation if block_given?
|
193
|
+
result
|
194
|
+
end
|
195
|
+
|
196
|
+
##
|
197
|
+
# Baseline implementation for the delete_connection REST call
|
198
|
+
#
|
199
|
+
# @param request_pb [::Google::Cloud::Bigquery::Connection::V1::DeleteConnectionRequest]
|
200
|
+
# A request object representing the call parameters. Required.
|
201
|
+
# @param options [::Gapic::CallOptions]
|
202
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
203
|
+
#
|
204
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
205
|
+
# @yieldparam result [::Google::Protobuf::Empty]
|
206
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
207
|
+
#
|
208
|
+
# @return [::Google::Protobuf::Empty]
|
209
|
+
# A result object deserialized from the server's reply
|
210
|
+
def delete_connection request_pb, options = nil
|
211
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
212
|
+
|
213
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_delete_connection_request request_pb
|
214
|
+
query_string_params = if query_string_params.any?
|
215
|
+
query_string_params.to_h { |p| p.split("=", 2) }
|
216
|
+
else
|
217
|
+
{}
|
218
|
+
end
|
219
|
+
|
220
|
+
response = @client_stub.make_http_request(
|
221
|
+
verb,
|
222
|
+
uri: uri,
|
223
|
+
body: body || "",
|
224
|
+
params: query_string_params,
|
225
|
+
options: options
|
226
|
+
)
|
227
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
228
|
+
result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true
|
229
|
+
|
230
|
+
yield result, operation if block_given?
|
231
|
+
result
|
232
|
+
end
|
233
|
+
|
234
|
+
##
|
235
|
+
# Baseline implementation for the get_iam_policy REST call
|
236
|
+
#
|
237
|
+
# @param request_pb [::Google::Iam::V1::GetIamPolicyRequest]
|
238
|
+
# A request object representing the call parameters. Required.
|
239
|
+
# @param options [::Gapic::CallOptions]
|
240
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
241
|
+
#
|
242
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
243
|
+
# @yieldparam result [::Google::Iam::V1::Policy]
|
244
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
245
|
+
#
|
246
|
+
# @return [::Google::Iam::V1::Policy]
|
247
|
+
# A result object deserialized from the server's reply
|
248
|
+
def get_iam_policy request_pb, options = nil
|
249
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
250
|
+
|
251
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_iam_policy_request request_pb
|
252
|
+
query_string_params = if query_string_params.any?
|
253
|
+
query_string_params.to_h { |p| p.split("=", 2) }
|
254
|
+
else
|
255
|
+
{}
|
256
|
+
end
|
257
|
+
|
258
|
+
response = @client_stub.make_http_request(
|
259
|
+
verb,
|
260
|
+
uri: uri,
|
261
|
+
body: body || "",
|
262
|
+
params: query_string_params,
|
263
|
+
options: options
|
264
|
+
)
|
265
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
266
|
+
result = ::Google::Iam::V1::Policy.decode_json response.body, ignore_unknown_fields: true
|
267
|
+
|
268
|
+
yield result, operation if block_given?
|
269
|
+
result
|
270
|
+
end
|
271
|
+
|
272
|
+
##
|
273
|
+
# Baseline implementation for the set_iam_policy REST call
|
274
|
+
#
|
275
|
+
# @param request_pb [::Google::Iam::V1::SetIamPolicyRequest]
|
276
|
+
# A request object representing the call parameters. Required.
|
277
|
+
# @param options [::Gapic::CallOptions]
|
278
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
279
|
+
#
|
280
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
281
|
+
# @yieldparam result [::Google::Iam::V1::Policy]
|
282
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
283
|
+
#
|
284
|
+
# @return [::Google::Iam::V1::Policy]
|
285
|
+
# A result object deserialized from the server's reply
|
286
|
+
def set_iam_policy request_pb, options = nil
|
287
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
288
|
+
|
289
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_set_iam_policy_request request_pb
|
290
|
+
query_string_params = if query_string_params.any?
|
291
|
+
query_string_params.to_h { |p| p.split("=", 2) }
|
292
|
+
else
|
293
|
+
{}
|
294
|
+
end
|
295
|
+
|
296
|
+
response = @client_stub.make_http_request(
|
297
|
+
verb,
|
298
|
+
uri: uri,
|
299
|
+
body: body || "",
|
300
|
+
params: query_string_params,
|
301
|
+
options: options
|
302
|
+
)
|
303
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
304
|
+
result = ::Google::Iam::V1::Policy.decode_json response.body, ignore_unknown_fields: true
|
305
|
+
|
306
|
+
yield result, operation if block_given?
|
307
|
+
result
|
308
|
+
end
|
309
|
+
|
310
|
+
##
|
311
|
+
# Baseline implementation for the test_iam_permissions REST call
|
312
|
+
#
|
313
|
+
# @param request_pb [::Google::Iam::V1::TestIamPermissionsRequest]
|
314
|
+
# A request object representing the call parameters. Required.
|
315
|
+
# @param options [::Gapic::CallOptions]
|
316
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
317
|
+
#
|
318
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
319
|
+
# @yieldparam result [::Google::Iam::V1::TestIamPermissionsResponse]
|
320
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
321
|
+
#
|
322
|
+
# @return [::Google::Iam::V1::TestIamPermissionsResponse]
|
323
|
+
# A result object deserialized from the server's reply
|
324
|
+
def test_iam_permissions request_pb, options = nil
|
325
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
326
|
+
|
327
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_test_iam_permissions_request request_pb
|
328
|
+
query_string_params = if query_string_params.any?
|
329
|
+
query_string_params.to_h { |p| p.split("=", 2) }
|
330
|
+
else
|
331
|
+
{}
|
332
|
+
end
|
333
|
+
|
334
|
+
response = @client_stub.make_http_request(
|
335
|
+
verb,
|
336
|
+
uri: uri,
|
337
|
+
body: body || "",
|
338
|
+
params: query_string_params,
|
339
|
+
options: options
|
340
|
+
)
|
341
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
342
|
+
result = ::Google::Iam::V1::TestIamPermissionsResponse.decode_json response.body, ignore_unknown_fields: true
|
343
|
+
|
344
|
+
yield result, operation if block_given?
|
345
|
+
result
|
346
|
+
end
|
347
|
+
|
348
|
+
##
|
349
|
+
# @private
|
350
|
+
#
|
351
|
+
# GRPC transcoding helper method for the create_connection REST call
|
352
|
+
#
|
353
|
+
# @param request_pb [::Google::Cloud::Bigquery::Connection::V1::CreateConnectionRequest]
|
354
|
+
# A request object representing the call parameters. Required.
|
355
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
356
|
+
# Uri, Body, Query string parameters
|
357
|
+
def self.transcode_create_connection_request request_pb
|
358
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
359
|
+
.with_bindings(
|
360
|
+
uri_method: :post,
|
361
|
+
uri_template: "/v1/{parent}/connections",
|
362
|
+
body: "connection",
|
363
|
+
matches: [
|
364
|
+
["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
|
365
|
+
]
|
366
|
+
)
|
367
|
+
transcoder.transcode request_pb
|
368
|
+
end
|
369
|
+
|
370
|
+
##
|
371
|
+
# @private
|
372
|
+
#
|
373
|
+
# GRPC transcoding helper method for the get_connection REST call
|
374
|
+
#
|
375
|
+
# @param request_pb [::Google::Cloud::Bigquery::Connection::V1::GetConnectionRequest]
|
376
|
+
# A request object representing the call parameters. Required.
|
377
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
378
|
+
# Uri, Body, Query string parameters
|
379
|
+
def self.transcode_get_connection_request request_pb
|
380
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
381
|
+
.with_bindings(
|
382
|
+
uri_method: :get,
|
383
|
+
uri_template: "/v1/{name}",
|
384
|
+
matches: [
|
385
|
+
["name", %r{^projects/[^/]+/locations/[^/]+/connections/[^/]+/?$}, false]
|
386
|
+
]
|
387
|
+
)
|
388
|
+
transcoder.transcode request_pb
|
389
|
+
end
|
390
|
+
|
391
|
+
##
|
392
|
+
# @private
|
393
|
+
#
|
394
|
+
# GRPC transcoding helper method for the list_connections REST call
|
395
|
+
#
|
396
|
+
# @param request_pb [::Google::Cloud::Bigquery::Connection::V1::ListConnectionsRequest]
|
397
|
+
# A request object representing the call parameters. Required.
|
398
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
399
|
+
# Uri, Body, Query string parameters
|
400
|
+
def self.transcode_list_connections_request request_pb
|
401
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
402
|
+
.with_bindings(
|
403
|
+
uri_method: :get,
|
404
|
+
uri_template: "/v1/{parent}/connections",
|
405
|
+
matches: [
|
406
|
+
["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
|
407
|
+
]
|
408
|
+
)
|
409
|
+
transcoder.transcode request_pb
|
410
|
+
end
|
411
|
+
|
412
|
+
##
|
413
|
+
# @private
|
414
|
+
#
|
415
|
+
# GRPC transcoding helper method for the update_connection REST call
|
416
|
+
#
|
417
|
+
# @param request_pb [::Google::Cloud::Bigquery::Connection::V1::UpdateConnectionRequest]
|
418
|
+
# A request object representing the call parameters. Required.
|
419
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
420
|
+
# Uri, Body, Query string parameters
|
421
|
+
def self.transcode_update_connection_request request_pb
|
422
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
423
|
+
.with_bindings(
|
424
|
+
uri_method: :patch,
|
425
|
+
uri_template: "/v1/{name}",
|
426
|
+
body: "connection",
|
427
|
+
matches: [
|
428
|
+
["name", %r{^projects/[^/]+/locations/[^/]+/connections/[^/]+/?$}, false]
|
429
|
+
]
|
430
|
+
)
|
431
|
+
transcoder.transcode request_pb
|
432
|
+
end
|
433
|
+
|
434
|
+
##
|
435
|
+
# @private
|
436
|
+
#
|
437
|
+
# GRPC transcoding helper method for the delete_connection REST call
|
438
|
+
#
|
439
|
+
# @param request_pb [::Google::Cloud::Bigquery::Connection::V1::DeleteConnectionRequest]
|
440
|
+
# A request object representing the call parameters. Required.
|
441
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
442
|
+
# Uri, Body, Query string parameters
|
443
|
+
def self.transcode_delete_connection_request request_pb
|
444
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
445
|
+
.with_bindings(
|
446
|
+
uri_method: :delete,
|
447
|
+
uri_template: "/v1/{name}",
|
448
|
+
matches: [
|
449
|
+
["name", %r{^projects/[^/]+/locations/[^/]+/connections/[^/]+/?$}, false]
|
450
|
+
]
|
451
|
+
)
|
452
|
+
transcoder.transcode request_pb
|
453
|
+
end
|
454
|
+
|
455
|
+
##
|
456
|
+
# @private
|
457
|
+
#
|
458
|
+
# GRPC transcoding helper method for the get_iam_policy REST call
|
459
|
+
#
|
460
|
+
# @param request_pb [::Google::Iam::V1::GetIamPolicyRequest]
|
461
|
+
# A request object representing the call parameters. Required.
|
462
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
463
|
+
# Uri, Body, Query string parameters
|
464
|
+
def self.transcode_get_iam_policy_request request_pb
|
465
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
466
|
+
.with_bindings(
|
467
|
+
uri_method: :post,
|
468
|
+
uri_template: "/v1/{resource}:getIamPolicy",
|
469
|
+
body: "*",
|
470
|
+
matches: [
|
471
|
+
["resource", %r{^projects/[^/]+/locations/[^/]+/connections/[^/]+/?$}, false]
|
472
|
+
]
|
473
|
+
)
|
474
|
+
transcoder.transcode request_pb
|
475
|
+
end
|
476
|
+
|
477
|
+
##
|
478
|
+
# @private
|
479
|
+
#
|
480
|
+
# GRPC transcoding helper method for the set_iam_policy REST call
|
481
|
+
#
|
482
|
+
# @param request_pb [::Google::Iam::V1::SetIamPolicyRequest]
|
483
|
+
# A request object representing the call parameters. Required.
|
484
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
485
|
+
# Uri, Body, Query string parameters
|
486
|
+
def self.transcode_set_iam_policy_request request_pb
|
487
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
488
|
+
.with_bindings(
|
489
|
+
uri_method: :post,
|
490
|
+
uri_template: "/v1/{resource}:setIamPolicy",
|
491
|
+
body: "*",
|
492
|
+
matches: [
|
493
|
+
["resource", %r{^projects/[^/]+/locations/[^/]+/connections/[^/]+/?$}, false]
|
494
|
+
]
|
495
|
+
)
|
496
|
+
transcoder.transcode request_pb
|
497
|
+
end
|
498
|
+
|
499
|
+
##
|
500
|
+
# @private
|
501
|
+
#
|
502
|
+
# GRPC transcoding helper method for the test_iam_permissions REST call
|
503
|
+
#
|
504
|
+
# @param request_pb [::Google::Iam::V1::TestIamPermissionsRequest]
|
505
|
+
# A request object representing the call parameters. Required.
|
506
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
507
|
+
# Uri, Body, Query string parameters
|
508
|
+
def self.transcode_test_iam_permissions_request request_pb
|
509
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
510
|
+
.with_bindings(
|
511
|
+
uri_method: :post,
|
512
|
+
uri_template: "/v1/{resource}:testIamPermissions",
|
513
|
+
body: "*",
|
514
|
+
matches: [
|
515
|
+
["resource", %r{^projects/[^/]+/locations/[^/]+/connections/[^/]+/?$}, false]
|
516
|
+
]
|
517
|
+
)
|
518
|
+
transcoder.transcode request_pb
|
519
|
+
end
|
520
|
+
end
|
521
|
+
end
|
522
|
+
end
|
523
|
+
end
|
524
|
+
end
|
525
|
+
end
|
526
|
+
end
|
527
|
+
end
|
@@ -0,0 +1,54 @@
|
|
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 "gapic/rest"
|
20
|
+
require "gapic/config"
|
21
|
+
require "gapic/config/method"
|
22
|
+
|
23
|
+
require "google/cloud/bigquery/connection/v1/version"
|
24
|
+
|
25
|
+
require "google/cloud/bigquery/connection/v1/connection_service/credentials"
|
26
|
+
require "google/cloud/bigquery/connection/v1/connection_service/paths"
|
27
|
+
require "google/cloud/bigquery/connection/v1/connection_service/rest/client"
|
28
|
+
|
29
|
+
module Google
|
30
|
+
module Cloud
|
31
|
+
module Bigquery
|
32
|
+
module Connection
|
33
|
+
module V1
|
34
|
+
##
|
35
|
+
# Manages external data source connections and credentials.
|
36
|
+
#
|
37
|
+
# To load this service and instantiate a REST client:
|
38
|
+
#
|
39
|
+
# require "google/cloud/bigquery/connection/v1/connection_service/rest"
|
40
|
+
# client = ::Google::Cloud::Bigquery::Connection::V1::ConnectionService::Rest::Client.new
|
41
|
+
#
|
42
|
+
module ConnectionService
|
43
|
+
# Client for the REST transport
|
44
|
+
module Rest
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
52
|
+
|
53
|
+
helper_path = ::File.join __dir__, "rest", "helpers.rb"
|
54
|
+
require "google/cloud/bigquery/connection/v1/connection_service/rest/helpers" if ::File.file? helper_path
|
@@ -25,6 +25,7 @@ require "google/cloud/bigquery/connection/v1/version"
|
|
25
25
|
require "google/cloud/bigquery/connection/v1/connection_service/credentials"
|
26
26
|
require "google/cloud/bigquery/connection/v1/connection_service/paths"
|
27
27
|
require "google/cloud/bigquery/connection/v1/connection_service/client"
|
28
|
+
require "google/cloud/bigquery/connection/v1/connection_service/rest"
|
28
29
|
|
29
30
|
module Google
|
30
31
|
module Cloud
|
@@ -39,6 +40,11 @@ module Google
|
|
39
40
|
# require "google/cloud/bigquery/connection/v1/connection_service"
|
40
41
|
# client = ::Google::Cloud::Bigquery::Connection::V1::ConnectionService::Client.new
|
41
42
|
#
|
43
|
+
# @example Load this service and instantiate a REST client
|
44
|
+
#
|
45
|
+
# require "google/cloud/bigquery/connection/v1/connection_service/rest"
|
46
|
+
# client = ::Google::Cloud::Bigquery::Connection::V1::ConnectionService::Rest::Client.new
|
47
|
+
#
|
42
48
|
module ConnectionService
|
43
49
|
end
|
44
50
|
end
|
@@ -0,0 +1,39 @@
|
|
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/connection/v1/connection_service/rest"
|
20
|
+
require "google/cloud/bigquery/connection/v1/version"
|
21
|
+
|
22
|
+
module Google
|
23
|
+
module Cloud
|
24
|
+
module Bigquery
|
25
|
+
module Connection
|
26
|
+
##
|
27
|
+
# To load just the REST part of this package, including all its services, and instantiate a REST client:
|
28
|
+
#
|
29
|
+
# @example
|
30
|
+
#
|
31
|
+
# require "google/cloud/bigquery/connection/v1/rest"
|
32
|
+
# client = ::Google::Cloud::Bigquery::Connection::V1::ConnectionService::Rest::Client.new
|
33
|
+
#
|
34
|
+
module V1
|
35
|
+
end
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -31,6 +31,11 @@ module Google
|
|
31
31
|
# require "google/cloud/bigquery/connection/v1"
|
32
32
|
# client = ::Google::Cloud::Bigquery::Connection::V1::ConnectionService::Client.new
|
33
33
|
#
|
34
|
+
# @example Load this package, including all its services, and instantiate a REST client
|
35
|
+
#
|
36
|
+
# require "google/cloud/bigquery/connection/v1"
|
37
|
+
# client = ::Google::Cloud::Bigquery::Connection::V1::ConnectionService::Rest::Client.new
|
38
|
+
#
|
34
39
|
module V1
|
35
40
|
end
|
36
41
|
end
|