google-cloud-data_catalog-v1beta1 0.a → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (65) hide show
  1. checksums.yaml +4 -4
  2. data/.yardopts +12 -0
  3. data/AUTHENTICATION.md +149 -0
  4. data/README.md +144 -8
  5. data/lib/google/cloud/data_catalog/v1beta1/data_catalog/client.rb +3294 -0
  6. data/lib/google/cloud/data_catalog/v1beta1/data_catalog/credentials.rb +47 -0
  7. data/lib/google/cloud/data_catalog/v1beta1/data_catalog/paths.rb +176 -0
  8. data/lib/google/cloud/data_catalog/v1beta1/data_catalog/rest/client.rb +2629 -0
  9. data/lib/google/cloud/data_catalog/v1beta1/data_catalog/rest/service_stub.rb +1782 -0
  10. data/lib/google/cloud/data_catalog/v1beta1/data_catalog/rest.rb +53 -0
  11. data/lib/google/cloud/data_catalog/v1beta1/data_catalog.rb +56 -0
  12. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager/client.rb +1581 -0
  13. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager/credentials.rb +47 -0
  14. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager/paths.rb +90 -0
  15. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager/rest/client.rb +1254 -0
  16. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager/rest/service_stub.rb +846 -0
  17. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager/rest.rb +53 -0
  18. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager.rb +56 -0
  19. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager_serialization/client.rb +513 -0
  20. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager_serialization/credentials.rb +47 -0
  21. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager_serialization/paths.rb +69 -0
  22. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager_serialization/rest/client.rb +447 -0
  23. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager_serialization/rest/service_stub.rb +167 -0
  24. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager_serialization/rest.rb +53 -0
  25. data/lib/google/cloud/data_catalog/v1beta1/policy_tag_manager_serialization.rb +56 -0
  26. data/lib/google/cloud/data_catalog/v1beta1/rest.rb +39 -0
  27. data/lib/google/cloud/data_catalog/v1beta1/version.rb +7 -2
  28. data/lib/google/cloud/data_catalog/v1beta1.rb +47 -0
  29. data/lib/google/cloud/datacatalog/v1beta1/common_pb.rb +43 -0
  30. data/lib/google/cloud/datacatalog/v1beta1/datacatalog_pb.rb +99 -0
  31. data/lib/google/cloud/datacatalog/v1beta1/datacatalog_services_pb.rb +229 -0
  32. data/lib/google/cloud/datacatalog/v1beta1/gcs_fileset_spec_pb.rb +47 -0
  33. data/lib/google/cloud/datacatalog/v1beta1/policytagmanager_pb.rb +70 -0
  34. data/lib/google/cloud/datacatalog/v1beta1/policytagmanager_services_pb.rb +73 -0
  35. data/lib/google/cloud/datacatalog/v1beta1/policytagmanagerserialization_pb.rb +55 -0
  36. data/lib/google/cloud/datacatalog/v1beta1/policytagmanagerserialization_services_pb.rb +55 -0
  37. data/lib/google/cloud/datacatalog/v1beta1/schema_pb.rb +45 -0
  38. data/lib/google/cloud/datacatalog/v1beta1/search_pb.rb +47 -0
  39. data/lib/google/cloud/datacatalog/v1beta1/table_spec_pb.rb +49 -0
  40. data/lib/google/cloud/datacatalog/v1beta1/tags_pb.rb +55 -0
  41. data/lib/google/cloud/datacatalog/v1beta1/timestamps_pb.rb +46 -0
  42. data/lib/google/cloud/datacatalog/v1beta1/usage_pb.rb +46 -0
  43. data/lib/google-cloud-data_catalog-v1beta1.rb +21 -0
  44. data/proto_docs/README.md +4 -0
  45. data/proto_docs/google/api/client.rb +381 -0
  46. data/proto_docs/google/api/field_behavior.rb +71 -0
  47. data/proto_docs/google/api/launch_stage.rb +71 -0
  48. data/proto_docs/google/api/resource.rb +222 -0
  49. data/proto_docs/google/cloud/datacatalog/v1beta1/common.rb +52 -0
  50. data/proto_docs/google/cloud/datacatalog/v1beta1/datacatalog.rb +830 -0
  51. data/proto_docs/google/cloud/datacatalog/v1beta1/gcs_fileset_spec.rb +81 -0
  52. data/proto_docs/google/cloud/datacatalog/v1beta1/policytagmanager.rb +300 -0
  53. data/proto_docs/google/cloud/datacatalog/v1beta1/policytagmanagerserialization.rb +131 -0
  54. data/proto_docs/google/cloud/datacatalog/v1beta1/schema.rb +61 -0
  55. data/proto_docs/google/cloud/datacatalog/v1beta1/search.rb +75 -0
  56. data/proto_docs/google/cloud/datacatalog/v1beta1/table_spec.rb +102 -0
  57. data/proto_docs/google/cloud/datacatalog/v1beta1/tags.rb +242 -0
  58. data/proto_docs/google/cloud/datacatalog/v1beta1/timestamps.rb +42 -0
  59. data/proto_docs/google/cloud/datacatalog/v1beta1/usage.rb +74 -0
  60. data/proto_docs/google/protobuf/duration.rb +98 -0
  61. data/proto_docs/google/protobuf/empty.rb +34 -0
  62. data/proto_docs/google/protobuf/field_mask.rb +229 -0
  63. data/proto_docs/google/protobuf/timestamp.rb +127 -0
  64. data/proto_docs/google/type/expr.rb +75 -0
  65. metadata +240 -11
@@ -0,0 +1,2629 @@
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/errors"
20
+ require "google/cloud/datacatalog/v1beta1/datacatalog_pb"
21
+ require "google/cloud/data_catalog/v1beta1/data_catalog/rest/service_stub"
22
+ require "google/iam/v1/rest"
23
+
24
+ module Google
25
+ module Cloud
26
+ module DataCatalog
27
+ module V1beta1
28
+ module DataCatalog
29
+ module Rest
30
+ ##
31
+ # REST client for the DataCatalog service.
32
+ #
33
+ # Data Catalog API service allows clients to discover, understand, and manage
34
+ # their data.
35
+ #
36
+ class Client
37
+ include Paths
38
+
39
+ # @private
40
+ attr_reader :data_catalog_stub
41
+
42
+ ##
43
+ # Configure the DataCatalog Client class.
44
+ #
45
+ # See {::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::Client::Configuration}
46
+ # for a description of the configuration fields.
47
+ #
48
+ # @example
49
+ #
50
+ # # Modify the configuration for all DataCatalog clients
51
+ # ::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::Client.configure do |config|
52
+ # config.timeout = 10.0
53
+ # end
54
+ #
55
+ # @yield [config] Configure the Client client.
56
+ # @yieldparam config [Client::Configuration]
57
+ #
58
+ # @return [Client::Configuration]
59
+ #
60
+ def self.configure
61
+ @configure ||= begin
62
+ namespace = ["Google", "Cloud", "DataCatalog", "V1beta1"]
63
+ parent_config = while namespace.any?
64
+ parent_name = namespace.join "::"
65
+ parent_const = const_get parent_name
66
+ break parent_const.configure if parent_const.respond_to? :configure
67
+ namespace.pop
68
+ end
69
+ default_config = Client::Configuration.new parent_config
70
+
71
+ default_config.timeout = 60.0
72
+ default_config.retry_policy = {
73
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [14, 8, 13]
74
+ }
75
+
76
+ default_config
77
+ end
78
+ yield @configure if block_given?
79
+ @configure
80
+ end
81
+
82
+ ##
83
+ # Configure the DataCatalog Client instance.
84
+ #
85
+ # The configuration is set to the derived mode, meaning that values can be changed,
86
+ # but structural changes (adding new fields, etc.) are not allowed. Structural changes
87
+ # should be made on {Client.configure}.
88
+ #
89
+ # See {::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::Client::Configuration}
90
+ # for a description of the configuration fields.
91
+ #
92
+ # @yield [config] Configure the Client client.
93
+ # @yieldparam config [Client::Configuration]
94
+ #
95
+ # @return [Client::Configuration]
96
+ #
97
+ def configure
98
+ yield @config if block_given?
99
+ @config
100
+ end
101
+
102
+ ##
103
+ # Create a new DataCatalog REST client object.
104
+ #
105
+ # @example
106
+ #
107
+ # # Create a client using the default configuration
108
+ # client = ::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::Client.new
109
+ #
110
+ # # Create a client using a custom configuration
111
+ # client = ::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::Client.new do |config|
112
+ # config.timeout = 10.0
113
+ # end
114
+ #
115
+ # @yield [config] Configure the DataCatalog client.
116
+ # @yieldparam config [Client::Configuration]
117
+ #
118
+ def initialize
119
+ # Create the configuration object
120
+ @config = Configuration.new Client.configure
121
+
122
+ # Yield the configuration if needed
123
+ yield @config if block_given?
124
+
125
+ # Create credentials
126
+ credentials = @config.credentials
127
+ # Use self-signed JWT if the endpoint is unchanged from default,
128
+ # but only if the default endpoint does not have a region prefix.
129
+ enable_self_signed_jwt = @config.endpoint == Configuration::DEFAULT_ENDPOINT &&
130
+ !@config.endpoint.split(".").first.include?("-")
131
+ credentials ||= Credentials.default scope: @config.scope,
132
+ enable_self_signed_jwt: enable_self_signed_jwt
133
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
134
+ credentials = Credentials.new credentials, scope: @config.scope
135
+ end
136
+
137
+ @quota_project_id = @config.quota_project
138
+ @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
139
+
140
+ @iam_policy_client = Google::Iam::V1::IAMPolicy::Rest::Client.new do |config|
141
+ config.credentials = credentials
142
+ config.quota_project = @quota_project_id
143
+ config.endpoint = @config.endpoint
144
+ end
145
+
146
+ @data_catalog_stub = ::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
147
+ end
148
+
149
+ ##
150
+ # Get the associated client for mix-in of the IAMPolicy.
151
+ #
152
+ # @return [Google::Iam::V1::IAMPolicy::Rest::Client]
153
+ #
154
+ attr_reader :iam_policy_client
155
+
156
+ # Service calls
157
+
158
+ ##
159
+ # Searches Data Catalog for multiple resources like entries, tags that
160
+ # match a query.
161
+ #
162
+ # This is a custom method
163
+ # (https://cloud.google.com/apis/design/custom_methods) and does not return
164
+ # the complete resource, only the resource identifier and high level
165
+ # fields. Clients can subsequently call `Get` methods.
166
+ #
167
+ # Note that Data Catalog search queries do not guarantee full recall. Query
168
+ # results that match your query may not be returned, even in subsequent
169
+ # result pages. Also note that results returned (and not returned) can vary
170
+ # across repeated search queries.
171
+ #
172
+ # See [Data Catalog Search
173
+ # Syntax](https://cloud.google.com/data-catalog/docs/how-to/search-reference)
174
+ # for more information.
175
+ #
176
+ # @overload search_catalog(request, options = nil)
177
+ # Pass arguments to `search_catalog` via a request object, either of type
178
+ # {::Google::Cloud::DataCatalog::V1beta1::SearchCatalogRequest} or an equivalent Hash.
179
+ #
180
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::SearchCatalogRequest, ::Hash]
181
+ # A request object representing the call parameters. Required. To specify no
182
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
183
+ # @param options [::Gapic::CallOptions, ::Hash]
184
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
185
+ #
186
+ # @overload search_catalog(scope: nil, query: nil, page_size: nil, page_token: nil, order_by: nil)
187
+ # Pass arguments to `search_catalog` via keyword arguments. Note that at
188
+ # least one keyword argument is required. To specify no parameters, or to keep all
189
+ # the default parameter values, pass an empty Hash as a request object (see above).
190
+ #
191
+ # @param scope [::Google::Cloud::DataCatalog::V1beta1::SearchCatalogRequest::Scope, ::Hash]
192
+ # Required. The scope of this search request. A `scope` that has empty
193
+ # `include_org_ids`, `include_project_ids` AND false
194
+ # `include_gcp_public_datasets` is considered invalid. Data Catalog will
195
+ # return an error in such a case.
196
+ # @param query [::String]
197
+ # Optional. The query string in search query syntax. An empty query string
198
+ # will result in all data assets (in the specified scope) that the user has
199
+ # access to. Query strings can be simple as "x" or more qualified as:
200
+ #
201
+ # * name:x
202
+ # * column:x
203
+ # * description:y
204
+ #
205
+ # Note: Query tokens need to have a minimum of 3 characters for substring
206
+ # matching to work correctly. See [Data Catalog Search
207
+ # Syntax](https://cloud.google.com/data-catalog/docs/how-to/search-reference)
208
+ # for more information.
209
+ # @param page_size [::Integer]
210
+ # Number of results in the search page. If <=0 then defaults to 10. Max limit
211
+ # for page_size is 1000. Throws an invalid argument for page_size > 1000.
212
+ # @param page_token [::String]
213
+ # Optional. Pagination token returned in an earlier
214
+ # {::Google::Cloud::DataCatalog::V1beta1::SearchCatalogResponse#next_page_token SearchCatalogResponse.next_page_token},
215
+ # which indicates that this is a continuation of a prior
216
+ # {::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::Client#search_catalog SearchCatalogRequest}
217
+ # call, and that the system should return the next page of data. If empty,
218
+ # the first page is returned.
219
+ # @param order_by [::String]
220
+ # Specifies the ordering of results, currently supported case-sensitive
221
+ # choices are:
222
+ #
223
+ # * `relevance`, only supports descending
224
+ # * `last_modified_timestamp [asc|desc]`, defaults to descending if not
225
+ # specified
226
+ # * `default` that can only be descending
227
+ #
228
+ # If not specified, defaults to `relevance` descending.
229
+ # @yield [result, operation] Access the result along with the TransportOperation object
230
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::SearchCatalogResponse]
231
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
232
+ #
233
+ # @return [::Google::Cloud::DataCatalog::V1beta1::SearchCatalogResponse]
234
+ #
235
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
236
+ def search_catalog request, options = nil
237
+ raise ::ArgumentError, "request must be provided" if request.nil?
238
+
239
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::SearchCatalogRequest
240
+
241
+ # Converts hash and nil to an options object
242
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
243
+
244
+ # Customize the options with defaults
245
+ call_metadata = @config.rpcs.search_catalog.metadata.to_h
246
+
247
+ # Set x-goog-api-client and x-goog-user-project headers
248
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
249
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
250
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
251
+ transports_version_send: [:rest]
252
+
253
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
254
+
255
+ options.apply_defaults timeout: @config.rpcs.search_catalog.timeout,
256
+ metadata: call_metadata,
257
+ retry_policy: @config.rpcs.search_catalog.retry_policy
258
+
259
+ options.apply_defaults timeout: @config.timeout,
260
+ metadata: @config.metadata,
261
+ retry_policy: @config.retry_policy
262
+
263
+ @data_catalog_stub.search_catalog request, options do |result, operation|
264
+ yield result, operation if block_given?
265
+ return result
266
+ end
267
+ rescue ::Gapic::Rest::Error => e
268
+ raise ::Google::Cloud::Error.from_error(e)
269
+ end
270
+
271
+ ##
272
+ # A maximum of 10,000 entry groups may be created per organization across all
273
+ # locations.
274
+ #
275
+ # Users should enable the Data Catalog API in the project identified by
276
+ # the `parent` parameter (see [Data Catalog Resource Project]
277
+ # (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for
278
+ # more information).
279
+ #
280
+ # @overload create_entry_group(request, options = nil)
281
+ # Pass arguments to `create_entry_group` via a request object, either of type
282
+ # {::Google::Cloud::DataCatalog::V1beta1::CreateEntryGroupRequest} or an equivalent Hash.
283
+ #
284
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::CreateEntryGroupRequest, ::Hash]
285
+ # A request object representing the call parameters. Required. To specify no
286
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
287
+ # @param options [::Gapic::CallOptions, ::Hash]
288
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
289
+ #
290
+ # @overload create_entry_group(parent: nil, entry_group_id: nil, entry_group: nil)
291
+ # Pass arguments to `create_entry_group` via keyword arguments. Note that at
292
+ # least one keyword argument is required. To specify no parameters, or to keep all
293
+ # the default parameter values, pass an empty Hash as a request object (see above).
294
+ #
295
+ # @param parent [::String]
296
+ # Required. The name of the project this entry group is in. Example:
297
+ #
298
+ # * projects/\\{project_id}/locations/\\{location}
299
+ #
300
+ # Note that this EntryGroup and its child resources may not actually be
301
+ # stored in the location in this name.
302
+ # @param entry_group_id [::String]
303
+ # Required. The id of the entry group to create.
304
+ # The id must begin with a letter or underscore, contain only English
305
+ # letters, numbers and underscores, and be at most 64 characters.
306
+ # @param entry_group [::Google::Cloud::DataCatalog::V1beta1::EntryGroup, ::Hash]
307
+ # The entry group to create. Defaults to an empty entry group.
308
+ # @yield [result, operation] Access the result along with the TransportOperation object
309
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::EntryGroup]
310
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
311
+ #
312
+ # @return [::Google::Cloud::DataCatalog::V1beta1::EntryGroup]
313
+ #
314
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
315
+ def create_entry_group request, options = nil
316
+ raise ::ArgumentError, "request must be provided" if request.nil?
317
+
318
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::CreateEntryGroupRequest
319
+
320
+ # Converts hash and nil to an options object
321
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
322
+
323
+ # Customize the options with defaults
324
+ call_metadata = @config.rpcs.create_entry_group.metadata.to_h
325
+
326
+ # Set x-goog-api-client and x-goog-user-project headers
327
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
328
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
329
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
330
+ transports_version_send: [:rest]
331
+
332
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
333
+
334
+ options.apply_defaults timeout: @config.rpcs.create_entry_group.timeout,
335
+ metadata: call_metadata,
336
+ retry_policy: @config.rpcs.create_entry_group.retry_policy
337
+
338
+ options.apply_defaults timeout: @config.timeout,
339
+ metadata: @config.metadata,
340
+ retry_policy: @config.retry_policy
341
+
342
+ @data_catalog_stub.create_entry_group request, options do |result, operation|
343
+ yield result, operation if block_given?
344
+ return result
345
+ end
346
+ rescue ::Gapic::Rest::Error => e
347
+ raise ::Google::Cloud::Error.from_error(e)
348
+ end
349
+
350
+ ##
351
+ # Updates an EntryGroup. The user should enable the Data Catalog API in the
352
+ # project identified by the `entry_group.name` parameter (see [Data Catalog
353
+ # Resource Project]
354
+ # (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for
355
+ # more information).
356
+ #
357
+ # @overload update_entry_group(request, options = nil)
358
+ # Pass arguments to `update_entry_group` via a request object, either of type
359
+ # {::Google::Cloud::DataCatalog::V1beta1::UpdateEntryGroupRequest} or an equivalent Hash.
360
+ #
361
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::UpdateEntryGroupRequest, ::Hash]
362
+ # A request object representing the call parameters. Required. To specify no
363
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
364
+ # @param options [::Gapic::CallOptions, ::Hash]
365
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
366
+ #
367
+ # @overload update_entry_group(entry_group: nil, update_mask: nil)
368
+ # Pass arguments to `update_entry_group` via keyword arguments. Note that at
369
+ # least one keyword argument is required. To specify no parameters, or to keep all
370
+ # the default parameter values, pass an empty Hash as a request object (see above).
371
+ #
372
+ # @param entry_group [::Google::Cloud::DataCatalog::V1beta1::EntryGroup, ::Hash]
373
+ # Required. The updated entry group. "name" field must be set.
374
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
375
+ # Names of fields whose values to overwrite on an entry group.
376
+ #
377
+ # If this parameter is absent or empty, all modifiable fields
378
+ # are overwritten. If such fields are non-required and omitted in the
379
+ # request body, their values are emptied.
380
+ # @yield [result, operation] Access the result along with the TransportOperation object
381
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::EntryGroup]
382
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
383
+ #
384
+ # @return [::Google::Cloud::DataCatalog::V1beta1::EntryGroup]
385
+ #
386
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
387
+ def update_entry_group request, options = nil
388
+ raise ::ArgumentError, "request must be provided" if request.nil?
389
+
390
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::UpdateEntryGroupRequest
391
+
392
+ # Converts hash and nil to an options object
393
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
394
+
395
+ # Customize the options with defaults
396
+ call_metadata = @config.rpcs.update_entry_group.metadata.to_h
397
+
398
+ # Set x-goog-api-client and x-goog-user-project headers
399
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
400
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
401
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
402
+ transports_version_send: [:rest]
403
+
404
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
405
+
406
+ options.apply_defaults timeout: @config.rpcs.update_entry_group.timeout,
407
+ metadata: call_metadata,
408
+ retry_policy: @config.rpcs.update_entry_group.retry_policy
409
+
410
+ options.apply_defaults timeout: @config.timeout,
411
+ metadata: @config.metadata,
412
+ retry_policy: @config.retry_policy
413
+
414
+ @data_catalog_stub.update_entry_group request, options do |result, operation|
415
+ yield result, operation if block_given?
416
+ return result
417
+ end
418
+ rescue ::Gapic::Rest::Error => e
419
+ raise ::Google::Cloud::Error.from_error(e)
420
+ end
421
+
422
+ ##
423
+ # Gets an EntryGroup.
424
+ #
425
+ # @overload get_entry_group(request, options = nil)
426
+ # Pass arguments to `get_entry_group` via a request object, either of type
427
+ # {::Google::Cloud::DataCatalog::V1beta1::GetEntryGroupRequest} or an equivalent Hash.
428
+ #
429
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::GetEntryGroupRequest, ::Hash]
430
+ # A request object representing the call parameters. Required. To specify no
431
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
432
+ # @param options [::Gapic::CallOptions, ::Hash]
433
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
434
+ #
435
+ # @overload get_entry_group(name: nil, read_mask: nil)
436
+ # Pass arguments to `get_entry_group` via keyword arguments. Note that at
437
+ # least one keyword argument is required. To specify no parameters, or to keep all
438
+ # the default parameter values, pass an empty Hash as a request object (see above).
439
+ #
440
+ # @param name [::String]
441
+ # Required. The name of the entry group. For example,
442
+ # `projects/{project_id}/locations/{location}/entryGroups/{entry_group_id}`.
443
+ # @param read_mask [::Google::Protobuf::FieldMask, ::Hash]
444
+ # The fields to return. If not set or empty, all fields are returned.
445
+ # @yield [result, operation] Access the result along with the TransportOperation object
446
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::EntryGroup]
447
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
448
+ #
449
+ # @return [::Google::Cloud::DataCatalog::V1beta1::EntryGroup]
450
+ #
451
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
452
+ def get_entry_group request, options = nil
453
+ raise ::ArgumentError, "request must be provided" if request.nil?
454
+
455
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::GetEntryGroupRequest
456
+
457
+ # Converts hash and nil to an options object
458
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
459
+
460
+ # Customize the options with defaults
461
+ call_metadata = @config.rpcs.get_entry_group.metadata.to_h
462
+
463
+ # Set x-goog-api-client and x-goog-user-project headers
464
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
465
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
466
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
467
+ transports_version_send: [:rest]
468
+
469
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
470
+
471
+ options.apply_defaults timeout: @config.rpcs.get_entry_group.timeout,
472
+ metadata: call_metadata,
473
+ retry_policy: @config.rpcs.get_entry_group.retry_policy
474
+
475
+ options.apply_defaults timeout: @config.timeout,
476
+ metadata: @config.metadata,
477
+ retry_policy: @config.retry_policy
478
+
479
+ @data_catalog_stub.get_entry_group request, options do |result, operation|
480
+ yield result, operation if block_given?
481
+ return result
482
+ end
483
+ rescue ::Gapic::Rest::Error => e
484
+ raise ::Google::Cloud::Error.from_error(e)
485
+ end
486
+
487
+ ##
488
+ # Deletes an EntryGroup. Only entry groups that do not contain entries can be
489
+ # deleted. Users should enable the Data Catalog API in the project
490
+ # identified by the `name` parameter (see [Data Catalog Resource Project]
491
+ # (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for
492
+ # more information).
493
+ #
494
+ # @overload delete_entry_group(request, options = nil)
495
+ # Pass arguments to `delete_entry_group` via a request object, either of type
496
+ # {::Google::Cloud::DataCatalog::V1beta1::DeleteEntryGroupRequest} or an equivalent Hash.
497
+ #
498
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::DeleteEntryGroupRequest, ::Hash]
499
+ # A request object representing the call parameters. Required. To specify no
500
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
501
+ # @param options [::Gapic::CallOptions, ::Hash]
502
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
503
+ #
504
+ # @overload delete_entry_group(name: nil, force: nil)
505
+ # Pass arguments to `delete_entry_group` via keyword arguments. Note that at
506
+ # least one keyword argument is required. To specify no parameters, or to keep all
507
+ # the default parameter values, pass an empty Hash as a request object (see above).
508
+ #
509
+ # @param name [::String]
510
+ # Required. The name of the entry group. For example,
511
+ # `projects/{project_id}/locations/{location}/entryGroups/{entry_group_id}`.
512
+ # @param force [::Boolean]
513
+ # Optional. If true, deletes all entries in the entry group.
514
+ # @yield [result, operation] Access the result along with the TransportOperation object
515
+ # @yieldparam result [::Google::Protobuf::Empty]
516
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
517
+ #
518
+ # @return [::Google::Protobuf::Empty]
519
+ #
520
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
521
+ def delete_entry_group request, options = nil
522
+ raise ::ArgumentError, "request must be provided" if request.nil?
523
+
524
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::DeleteEntryGroupRequest
525
+
526
+ # Converts hash and nil to an options object
527
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
528
+
529
+ # Customize the options with defaults
530
+ call_metadata = @config.rpcs.delete_entry_group.metadata.to_h
531
+
532
+ # Set x-goog-api-client and x-goog-user-project headers
533
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
534
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
535
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
536
+ transports_version_send: [:rest]
537
+
538
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
539
+
540
+ options.apply_defaults timeout: @config.rpcs.delete_entry_group.timeout,
541
+ metadata: call_metadata,
542
+ retry_policy: @config.rpcs.delete_entry_group.retry_policy
543
+
544
+ options.apply_defaults timeout: @config.timeout,
545
+ metadata: @config.metadata,
546
+ retry_policy: @config.retry_policy
547
+
548
+ @data_catalog_stub.delete_entry_group request, options do |result, operation|
549
+ yield result, operation if block_given?
550
+ return result
551
+ end
552
+ rescue ::Gapic::Rest::Error => e
553
+ raise ::Google::Cloud::Error.from_error(e)
554
+ end
555
+
556
+ ##
557
+ # Lists entry groups.
558
+ #
559
+ # @overload list_entry_groups(request, options = nil)
560
+ # Pass arguments to `list_entry_groups` via a request object, either of type
561
+ # {::Google::Cloud::DataCatalog::V1beta1::ListEntryGroupsRequest} or an equivalent Hash.
562
+ #
563
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::ListEntryGroupsRequest, ::Hash]
564
+ # A request object representing the call parameters. Required. To specify no
565
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
566
+ # @param options [::Gapic::CallOptions, ::Hash]
567
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
568
+ #
569
+ # @overload list_entry_groups(parent: nil, page_size: nil, page_token: nil)
570
+ # Pass arguments to `list_entry_groups` via keyword arguments. Note that at
571
+ # least one keyword argument is required. To specify no parameters, or to keep all
572
+ # the default parameter values, pass an empty Hash as a request object (see above).
573
+ #
574
+ # @param parent [::String]
575
+ # Required. The name of the location that contains the entry groups, which
576
+ # can be provided in URL format. Example:
577
+ #
578
+ # * projects/\\{project_id}/locations/\\{location}
579
+ # @param page_size [::Integer]
580
+ # Optional. The maximum number of items to return. Default is 10. Max limit
581
+ # is 1000. Throws an invalid argument for `page_size > 1000`.
582
+ # @param page_token [::String]
583
+ # Optional. Token that specifies which page is requested. If empty, the first
584
+ # page is returned.
585
+ # @yield [result, operation] Access the result along with the TransportOperation object
586
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::DataCatalog::V1beta1::EntryGroup>]
587
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
588
+ #
589
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::DataCatalog::V1beta1::EntryGroup>]
590
+ #
591
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
592
+ def list_entry_groups request, options = nil
593
+ raise ::ArgumentError, "request must be provided" if request.nil?
594
+
595
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::ListEntryGroupsRequest
596
+
597
+ # Converts hash and nil to an options object
598
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
599
+
600
+ # Customize the options with defaults
601
+ call_metadata = @config.rpcs.list_entry_groups.metadata.to_h
602
+
603
+ # Set x-goog-api-client and x-goog-user-project headers
604
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
605
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
606
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
607
+ transports_version_send: [:rest]
608
+
609
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
610
+
611
+ options.apply_defaults timeout: @config.rpcs.list_entry_groups.timeout,
612
+ metadata: call_metadata,
613
+ retry_policy: @config.rpcs.list_entry_groups.retry_policy
614
+
615
+ options.apply_defaults timeout: @config.timeout,
616
+ metadata: @config.metadata,
617
+ retry_policy: @config.retry_policy
618
+
619
+ @data_catalog_stub.list_entry_groups request, options do |result, operation|
620
+ result = ::Gapic::Rest::PagedEnumerable.new @data_catalog_stub, :list_entry_groups, "entry_groups", request, result, options
621
+ yield result, operation if block_given?
622
+ return result
623
+ end
624
+ rescue ::Gapic::Rest::Error => e
625
+ raise ::Google::Cloud::Error.from_error(e)
626
+ end
627
+
628
+ ##
629
+ # Creates an entry. Only entries of 'FILESET' type or user-specified type can
630
+ # be created.
631
+ #
632
+ # Users should enable the Data Catalog API in the project identified by
633
+ # the `parent` parameter (see [Data Catalog Resource Project]
634
+ # (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for
635
+ # more information).
636
+ #
637
+ # A maximum of 100,000 entries may be created per entry group.
638
+ #
639
+ # @overload create_entry(request, options = nil)
640
+ # Pass arguments to `create_entry` via a request object, either of type
641
+ # {::Google::Cloud::DataCatalog::V1beta1::CreateEntryRequest} or an equivalent Hash.
642
+ #
643
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::CreateEntryRequest, ::Hash]
644
+ # A request object representing the call parameters. Required. To specify no
645
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
646
+ # @param options [::Gapic::CallOptions, ::Hash]
647
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
648
+ #
649
+ # @overload create_entry(parent: nil, entry_id: nil, entry: nil)
650
+ # Pass arguments to `create_entry` via keyword arguments. Note that at
651
+ # least one keyword argument is required. To specify no parameters, or to keep all
652
+ # the default parameter values, pass an empty Hash as a request object (see above).
653
+ #
654
+ # @param parent [::String]
655
+ # Required. The name of the entry group this entry is in. Example:
656
+ #
657
+ # * projects/\\{project_id}/locations/\\{location}/entryGroups/\\{entry_group_id}
658
+ #
659
+ # Note that this Entry and its child resources may not actually be stored in
660
+ # the location in this name.
661
+ # @param entry_id [::String]
662
+ # Required. The id of the entry to create.
663
+ # @param entry [::Google::Cloud::DataCatalog::V1beta1::Entry, ::Hash]
664
+ # Required. The entry to create.
665
+ # @yield [result, operation] Access the result along with the TransportOperation object
666
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::Entry]
667
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
668
+ #
669
+ # @return [::Google::Cloud::DataCatalog::V1beta1::Entry]
670
+ #
671
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
672
+ def create_entry request, options = nil
673
+ raise ::ArgumentError, "request must be provided" if request.nil?
674
+
675
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::CreateEntryRequest
676
+
677
+ # Converts hash and nil to an options object
678
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
679
+
680
+ # Customize the options with defaults
681
+ call_metadata = @config.rpcs.create_entry.metadata.to_h
682
+
683
+ # Set x-goog-api-client and x-goog-user-project headers
684
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
685
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
686
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
687
+ transports_version_send: [:rest]
688
+
689
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
690
+
691
+ options.apply_defaults timeout: @config.rpcs.create_entry.timeout,
692
+ metadata: call_metadata,
693
+ retry_policy: @config.rpcs.create_entry.retry_policy
694
+
695
+ options.apply_defaults timeout: @config.timeout,
696
+ metadata: @config.metadata,
697
+ retry_policy: @config.retry_policy
698
+
699
+ @data_catalog_stub.create_entry request, options do |result, operation|
700
+ yield result, operation if block_given?
701
+ return result
702
+ end
703
+ rescue ::Gapic::Rest::Error => e
704
+ raise ::Google::Cloud::Error.from_error(e)
705
+ end
706
+
707
+ ##
708
+ # Updates an existing entry.
709
+ # Users should enable the Data Catalog API in the project identified by
710
+ # the `entry.name` parameter (see [Data Catalog Resource Project]
711
+ # (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for
712
+ # more information).
713
+ #
714
+ # @overload update_entry(request, options = nil)
715
+ # Pass arguments to `update_entry` via a request object, either of type
716
+ # {::Google::Cloud::DataCatalog::V1beta1::UpdateEntryRequest} or an equivalent Hash.
717
+ #
718
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::UpdateEntryRequest, ::Hash]
719
+ # A request object representing the call parameters. Required. To specify no
720
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
721
+ # @param options [::Gapic::CallOptions, ::Hash]
722
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
723
+ #
724
+ # @overload update_entry(entry: nil, update_mask: nil)
725
+ # Pass arguments to `update_entry` via keyword arguments. Note that at
726
+ # least one keyword argument is required. To specify no parameters, or to keep all
727
+ # the default parameter values, pass an empty Hash as a request object (see above).
728
+ #
729
+ # @param entry [::Google::Cloud::DataCatalog::V1beta1::Entry, ::Hash]
730
+ # Required. The updated entry. The "name" field must be set.
731
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
732
+ # Names of fields whose values to overwrite on an entry.
733
+ #
734
+ # If this parameter is absent or empty, all modifiable fields
735
+ # are overwritten. If such fields are non-required and omitted in the
736
+ # request body, their values are emptied.
737
+ #
738
+ # The following fields are modifiable:
739
+ #
740
+ # * For entries with type `DATA_STREAM`:
741
+ # * `schema`
742
+ # * For entries with type `FILESET`:
743
+ # * `schema`
744
+ # * `display_name`
745
+ # * `description`
746
+ # * `gcs_fileset_spec`
747
+ # * `gcs_fileset_spec.file_patterns`
748
+ # * For entries with `user_specified_type`:
749
+ # * `schema`
750
+ # * `display_name`
751
+ # * `description`
752
+ # * `user_specified_type`
753
+ # * `user_specified_system`
754
+ # * `linked_resource`
755
+ # * `source_system_timestamps`
756
+ # @yield [result, operation] Access the result along with the TransportOperation object
757
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::Entry]
758
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
759
+ #
760
+ # @return [::Google::Cloud::DataCatalog::V1beta1::Entry]
761
+ #
762
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
763
+ def update_entry request, options = nil
764
+ raise ::ArgumentError, "request must be provided" if request.nil?
765
+
766
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::UpdateEntryRequest
767
+
768
+ # Converts hash and nil to an options object
769
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
770
+
771
+ # Customize the options with defaults
772
+ call_metadata = @config.rpcs.update_entry.metadata.to_h
773
+
774
+ # Set x-goog-api-client and x-goog-user-project headers
775
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
776
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
777
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
778
+ transports_version_send: [:rest]
779
+
780
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
781
+
782
+ options.apply_defaults timeout: @config.rpcs.update_entry.timeout,
783
+ metadata: call_metadata,
784
+ retry_policy: @config.rpcs.update_entry.retry_policy
785
+
786
+ options.apply_defaults timeout: @config.timeout,
787
+ metadata: @config.metadata,
788
+ retry_policy: @config.retry_policy
789
+
790
+ @data_catalog_stub.update_entry request, options do |result, operation|
791
+ yield result, operation if block_given?
792
+ return result
793
+ end
794
+ rescue ::Gapic::Rest::Error => e
795
+ raise ::Google::Cloud::Error.from_error(e)
796
+ end
797
+
798
+ ##
799
+ # Deletes an existing entry. Only entries created through
800
+ # {::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::Client#create_entry CreateEntry}
801
+ # method can be deleted.
802
+ # Users should enable the Data Catalog API in the project identified by
803
+ # the `name` parameter (see [Data Catalog Resource Project]
804
+ # (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for
805
+ # more information).
806
+ #
807
+ # @overload delete_entry(request, options = nil)
808
+ # Pass arguments to `delete_entry` via a request object, either of type
809
+ # {::Google::Cloud::DataCatalog::V1beta1::DeleteEntryRequest} or an equivalent Hash.
810
+ #
811
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::DeleteEntryRequest, ::Hash]
812
+ # A request object representing the call parameters. Required. To specify no
813
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
814
+ # @param options [::Gapic::CallOptions, ::Hash]
815
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
816
+ #
817
+ # @overload delete_entry(name: nil)
818
+ # Pass arguments to `delete_entry` via keyword arguments. Note that at
819
+ # least one keyword argument is required. To specify no parameters, or to keep all
820
+ # the default parameter values, pass an empty Hash as a request object (see above).
821
+ #
822
+ # @param name [::String]
823
+ # Required. The name of the entry. Example:
824
+ #
825
+ # * projects/\\{project_id}/locations/\\{location}/entryGroups/\\{entry_group_id}/entries/\\{entry_id}
826
+ # @yield [result, operation] Access the result along with the TransportOperation object
827
+ # @yieldparam result [::Google::Protobuf::Empty]
828
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
829
+ #
830
+ # @return [::Google::Protobuf::Empty]
831
+ #
832
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
833
+ def delete_entry request, options = nil
834
+ raise ::ArgumentError, "request must be provided" if request.nil?
835
+
836
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::DeleteEntryRequest
837
+
838
+ # Converts hash and nil to an options object
839
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
840
+
841
+ # Customize the options with defaults
842
+ call_metadata = @config.rpcs.delete_entry.metadata.to_h
843
+
844
+ # Set x-goog-api-client and x-goog-user-project headers
845
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
846
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
847
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
848
+ transports_version_send: [:rest]
849
+
850
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
851
+
852
+ options.apply_defaults timeout: @config.rpcs.delete_entry.timeout,
853
+ metadata: call_metadata,
854
+ retry_policy: @config.rpcs.delete_entry.retry_policy
855
+
856
+ options.apply_defaults timeout: @config.timeout,
857
+ metadata: @config.metadata,
858
+ retry_policy: @config.retry_policy
859
+
860
+ @data_catalog_stub.delete_entry request, options do |result, operation|
861
+ yield result, operation if block_given?
862
+ return result
863
+ end
864
+ rescue ::Gapic::Rest::Error => e
865
+ raise ::Google::Cloud::Error.from_error(e)
866
+ end
867
+
868
+ ##
869
+ # Gets an entry.
870
+ #
871
+ # @overload get_entry(request, options = nil)
872
+ # Pass arguments to `get_entry` via a request object, either of type
873
+ # {::Google::Cloud::DataCatalog::V1beta1::GetEntryRequest} or an equivalent Hash.
874
+ #
875
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::GetEntryRequest, ::Hash]
876
+ # A request object representing the call parameters. Required. To specify no
877
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
878
+ # @param options [::Gapic::CallOptions, ::Hash]
879
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
880
+ #
881
+ # @overload get_entry(name: nil)
882
+ # Pass arguments to `get_entry` via keyword arguments. Note that at
883
+ # least one keyword argument is required. To specify no parameters, or to keep all
884
+ # the default parameter values, pass an empty Hash as a request object (see above).
885
+ #
886
+ # @param name [::String]
887
+ # Required. The name of the entry. Example:
888
+ #
889
+ # * projects/\\{project_id}/locations/\\{location}/entryGroups/\\{entry_group_id}/entries/\\{entry_id}
890
+ # @yield [result, operation] Access the result along with the TransportOperation object
891
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::Entry]
892
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
893
+ #
894
+ # @return [::Google::Cloud::DataCatalog::V1beta1::Entry]
895
+ #
896
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
897
+ def get_entry request, options = nil
898
+ raise ::ArgumentError, "request must be provided" if request.nil?
899
+
900
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::GetEntryRequest
901
+
902
+ # Converts hash and nil to an options object
903
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
904
+
905
+ # Customize the options with defaults
906
+ call_metadata = @config.rpcs.get_entry.metadata.to_h
907
+
908
+ # Set x-goog-api-client and x-goog-user-project headers
909
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
910
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
911
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
912
+ transports_version_send: [:rest]
913
+
914
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
915
+
916
+ options.apply_defaults timeout: @config.rpcs.get_entry.timeout,
917
+ metadata: call_metadata,
918
+ retry_policy: @config.rpcs.get_entry.retry_policy
919
+
920
+ options.apply_defaults timeout: @config.timeout,
921
+ metadata: @config.metadata,
922
+ retry_policy: @config.retry_policy
923
+
924
+ @data_catalog_stub.get_entry request, options do |result, operation|
925
+ yield result, operation if block_given?
926
+ return result
927
+ end
928
+ rescue ::Gapic::Rest::Error => e
929
+ raise ::Google::Cloud::Error.from_error(e)
930
+ end
931
+
932
+ ##
933
+ # Get an entry by target resource name. This method allows clients to use
934
+ # the resource name from the source Google Cloud Platform service to get the
935
+ # Data Catalog Entry.
936
+ #
937
+ # @overload lookup_entry(request, options = nil)
938
+ # Pass arguments to `lookup_entry` via a request object, either of type
939
+ # {::Google::Cloud::DataCatalog::V1beta1::LookupEntryRequest} or an equivalent Hash.
940
+ #
941
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::LookupEntryRequest, ::Hash]
942
+ # A request object representing the call parameters. Required. To specify no
943
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
944
+ # @param options [::Gapic::CallOptions, ::Hash]
945
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
946
+ #
947
+ # @overload lookup_entry(linked_resource: nil, sql_resource: nil)
948
+ # Pass arguments to `lookup_entry` via keyword arguments. Note that at
949
+ # least one keyword argument is required. To specify no parameters, or to keep all
950
+ # the default parameter values, pass an empty Hash as a request object (see above).
951
+ #
952
+ # @param linked_resource [::String]
953
+ # The full name of the Google Cloud Platform resource the Data Catalog
954
+ # entry represents. See:
955
+ # https://cloud.google.com/apis/design/resource_names#full_resource_name.
956
+ # Full names are case-sensitive.
957
+ #
958
+ # Examples:
959
+ #
960
+ # * //bigquery.googleapis.com/projects/projectId/datasets/datasetId/tables/tableId
961
+ # * //pubsub.googleapis.com/projects/projectId/topics/topicId
962
+ # @param sql_resource [::String]
963
+ # The SQL name of the entry. SQL names are case-sensitive.
964
+ #
965
+ # Examples:
966
+ #
967
+ # * `pubsub.project_id.topic_id`
968
+ # * ``pubsub.project_id.`topic.id.with.dots` ``
969
+ # * `bigquery.table.project_id.dataset_id.table_id`
970
+ # * `bigquery.dataset.project_id.dataset_id`
971
+ # * `datacatalog.entry.project_id.location_id.entry_group_id.entry_id`
972
+ #
973
+ # `*_id`s should satisfy the standard SQL rules for identifiers.
974
+ # https://cloud.google.com/bigquery/docs/reference/standard-sql/lexical.
975
+ # @yield [result, operation] Access the result along with the TransportOperation object
976
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::Entry]
977
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
978
+ #
979
+ # @return [::Google::Cloud::DataCatalog::V1beta1::Entry]
980
+ #
981
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
982
+ def lookup_entry request, options = nil
983
+ raise ::ArgumentError, "request must be provided" if request.nil?
984
+
985
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::LookupEntryRequest
986
+
987
+ # Converts hash and nil to an options object
988
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
989
+
990
+ # Customize the options with defaults
991
+ call_metadata = @config.rpcs.lookup_entry.metadata.to_h
992
+
993
+ # Set x-goog-api-client and x-goog-user-project headers
994
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
995
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
996
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
997
+ transports_version_send: [:rest]
998
+
999
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1000
+
1001
+ options.apply_defaults timeout: @config.rpcs.lookup_entry.timeout,
1002
+ metadata: call_metadata,
1003
+ retry_policy: @config.rpcs.lookup_entry.retry_policy
1004
+
1005
+ options.apply_defaults timeout: @config.timeout,
1006
+ metadata: @config.metadata,
1007
+ retry_policy: @config.retry_policy
1008
+
1009
+ @data_catalog_stub.lookup_entry request, options do |result, operation|
1010
+ yield result, operation if block_given?
1011
+ return result
1012
+ end
1013
+ rescue ::Gapic::Rest::Error => e
1014
+ raise ::Google::Cloud::Error.from_error(e)
1015
+ end
1016
+
1017
+ ##
1018
+ # Lists entries.
1019
+ #
1020
+ # @overload list_entries(request, options = nil)
1021
+ # Pass arguments to `list_entries` via a request object, either of type
1022
+ # {::Google::Cloud::DataCatalog::V1beta1::ListEntriesRequest} or an equivalent Hash.
1023
+ #
1024
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::ListEntriesRequest, ::Hash]
1025
+ # A request object representing the call parameters. Required. To specify no
1026
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1027
+ # @param options [::Gapic::CallOptions, ::Hash]
1028
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1029
+ #
1030
+ # @overload list_entries(parent: nil, page_size: nil, page_token: nil, read_mask: nil)
1031
+ # Pass arguments to `list_entries` via keyword arguments. Note that at
1032
+ # least one keyword argument is required. To specify no parameters, or to keep all
1033
+ # the default parameter values, pass an empty Hash as a request object (see above).
1034
+ #
1035
+ # @param parent [::String]
1036
+ # Required. The name of the entry group that contains the entries, which can
1037
+ # be provided in URL format. Example:
1038
+ #
1039
+ # * projects/\\{project_id}/locations/\\{location}/entryGroups/\\{entry_group_id}
1040
+ # @param page_size [::Integer]
1041
+ # The maximum number of items to return. Default is 10. Max limit is 1000.
1042
+ # Throws an invalid argument for `page_size > 1000`.
1043
+ # @param page_token [::String]
1044
+ # Token that specifies which page is requested. If empty, the first page is
1045
+ # returned.
1046
+ # @param read_mask [::Google::Protobuf::FieldMask, ::Hash]
1047
+ # The fields to return for each Entry. If not set or empty, all
1048
+ # fields are returned.
1049
+ # For example, setting read_mask to contain only one path "name" will cause
1050
+ # ListEntries to return a list of Entries with only "name" field.
1051
+ # @yield [result, operation] Access the result along with the TransportOperation object
1052
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::DataCatalog::V1beta1::Entry>]
1053
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1054
+ #
1055
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::DataCatalog::V1beta1::Entry>]
1056
+ #
1057
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1058
+ def list_entries request, options = nil
1059
+ raise ::ArgumentError, "request must be provided" if request.nil?
1060
+
1061
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::ListEntriesRequest
1062
+
1063
+ # Converts hash and nil to an options object
1064
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1065
+
1066
+ # Customize the options with defaults
1067
+ call_metadata = @config.rpcs.list_entries.metadata.to_h
1068
+
1069
+ # Set x-goog-api-client and x-goog-user-project headers
1070
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1071
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1072
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1073
+ transports_version_send: [:rest]
1074
+
1075
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1076
+
1077
+ options.apply_defaults timeout: @config.rpcs.list_entries.timeout,
1078
+ metadata: call_metadata,
1079
+ retry_policy: @config.rpcs.list_entries.retry_policy
1080
+
1081
+ options.apply_defaults timeout: @config.timeout,
1082
+ metadata: @config.metadata,
1083
+ retry_policy: @config.retry_policy
1084
+
1085
+ @data_catalog_stub.list_entries request, options do |result, operation|
1086
+ result = ::Gapic::Rest::PagedEnumerable.new @data_catalog_stub, :list_entries, "entries", request, result, options
1087
+ yield result, operation if block_given?
1088
+ return result
1089
+ end
1090
+ rescue ::Gapic::Rest::Error => e
1091
+ raise ::Google::Cloud::Error.from_error(e)
1092
+ end
1093
+
1094
+ ##
1095
+ # Creates a tag template. The user should enable the Data Catalog API in
1096
+ # the project identified by the `parent` parameter (see [Data Catalog
1097
+ # Resource
1098
+ # Project](https://cloud.google.com/data-catalog/docs/concepts/resource-project)
1099
+ # for more information).
1100
+ #
1101
+ # @overload create_tag_template(request, options = nil)
1102
+ # Pass arguments to `create_tag_template` via a request object, either of type
1103
+ # {::Google::Cloud::DataCatalog::V1beta1::CreateTagTemplateRequest} or an equivalent Hash.
1104
+ #
1105
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::CreateTagTemplateRequest, ::Hash]
1106
+ # A request object representing the call parameters. Required. To specify no
1107
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1108
+ # @param options [::Gapic::CallOptions, ::Hash]
1109
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1110
+ #
1111
+ # @overload create_tag_template(parent: nil, tag_template_id: nil, tag_template: nil)
1112
+ # Pass arguments to `create_tag_template` via keyword arguments. Note that at
1113
+ # least one keyword argument is required. To specify no parameters, or to keep all
1114
+ # the default parameter values, pass an empty Hash as a request object (see above).
1115
+ #
1116
+ # @param parent [::String]
1117
+ # Required. The name of the project and the template location
1118
+ # [region](https://cloud.google.com/data-catalog/docs/concepts/regions.
1119
+ #
1120
+ # Example:
1121
+ #
1122
+ # * projects/\\{project_id}/locations/us-central1
1123
+ # @param tag_template_id [::String]
1124
+ # Required. The id of the tag template to create.
1125
+ # @param tag_template [::Google::Cloud::DataCatalog::V1beta1::TagTemplate, ::Hash]
1126
+ # Required. The tag template to create.
1127
+ # @yield [result, operation] Access the result along with the TransportOperation object
1128
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::TagTemplate]
1129
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1130
+ #
1131
+ # @return [::Google::Cloud::DataCatalog::V1beta1::TagTemplate]
1132
+ #
1133
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1134
+ def create_tag_template request, options = nil
1135
+ raise ::ArgumentError, "request must be provided" if request.nil?
1136
+
1137
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::CreateTagTemplateRequest
1138
+
1139
+ # Converts hash and nil to an options object
1140
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1141
+
1142
+ # Customize the options with defaults
1143
+ call_metadata = @config.rpcs.create_tag_template.metadata.to_h
1144
+
1145
+ # Set x-goog-api-client and x-goog-user-project headers
1146
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1147
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1148
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1149
+ transports_version_send: [:rest]
1150
+
1151
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1152
+
1153
+ options.apply_defaults timeout: @config.rpcs.create_tag_template.timeout,
1154
+ metadata: call_metadata,
1155
+ retry_policy: @config.rpcs.create_tag_template.retry_policy
1156
+
1157
+ options.apply_defaults timeout: @config.timeout,
1158
+ metadata: @config.metadata,
1159
+ retry_policy: @config.retry_policy
1160
+
1161
+ @data_catalog_stub.create_tag_template request, options do |result, operation|
1162
+ yield result, operation if block_given?
1163
+ return result
1164
+ end
1165
+ rescue ::Gapic::Rest::Error => e
1166
+ raise ::Google::Cloud::Error.from_error(e)
1167
+ end
1168
+
1169
+ ##
1170
+ # Gets a tag template.
1171
+ #
1172
+ # @overload get_tag_template(request, options = nil)
1173
+ # Pass arguments to `get_tag_template` via a request object, either of type
1174
+ # {::Google::Cloud::DataCatalog::V1beta1::GetTagTemplateRequest} or an equivalent Hash.
1175
+ #
1176
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::GetTagTemplateRequest, ::Hash]
1177
+ # A request object representing the call parameters. Required. To specify no
1178
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1179
+ # @param options [::Gapic::CallOptions, ::Hash]
1180
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1181
+ #
1182
+ # @overload get_tag_template(name: nil)
1183
+ # Pass arguments to `get_tag_template` via keyword arguments. Note that at
1184
+ # least one keyword argument is required. To specify no parameters, or to keep all
1185
+ # the default parameter values, pass an empty Hash as a request object (see above).
1186
+ #
1187
+ # @param name [::String]
1188
+ # Required. The name of the tag template. Example:
1189
+ #
1190
+ # * projects/\\{project_id}/locations/\\{location}/tagTemplates/\\{tag_template_id}
1191
+ # @yield [result, operation] Access the result along with the TransportOperation object
1192
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::TagTemplate]
1193
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1194
+ #
1195
+ # @return [::Google::Cloud::DataCatalog::V1beta1::TagTemplate]
1196
+ #
1197
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1198
+ def get_tag_template request, options = nil
1199
+ raise ::ArgumentError, "request must be provided" if request.nil?
1200
+
1201
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::GetTagTemplateRequest
1202
+
1203
+ # Converts hash and nil to an options object
1204
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1205
+
1206
+ # Customize the options with defaults
1207
+ call_metadata = @config.rpcs.get_tag_template.metadata.to_h
1208
+
1209
+ # Set x-goog-api-client and x-goog-user-project headers
1210
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1211
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1212
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1213
+ transports_version_send: [:rest]
1214
+
1215
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1216
+
1217
+ options.apply_defaults timeout: @config.rpcs.get_tag_template.timeout,
1218
+ metadata: call_metadata,
1219
+ retry_policy: @config.rpcs.get_tag_template.retry_policy
1220
+
1221
+ options.apply_defaults timeout: @config.timeout,
1222
+ metadata: @config.metadata,
1223
+ retry_policy: @config.retry_policy
1224
+
1225
+ @data_catalog_stub.get_tag_template request, options do |result, operation|
1226
+ yield result, operation if block_given?
1227
+ return result
1228
+ end
1229
+ rescue ::Gapic::Rest::Error => e
1230
+ raise ::Google::Cloud::Error.from_error(e)
1231
+ end
1232
+
1233
+ ##
1234
+ # Updates a tag template. This method cannot be used to update the fields of
1235
+ # a template. The tag template fields are represented as separate resources
1236
+ # and should be updated using their own create/update/delete methods.
1237
+ # Users should enable the Data Catalog API in the project identified by
1238
+ # the `tag_template.name` parameter (see [Data Catalog Resource Project]
1239
+ # (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for
1240
+ # more information).
1241
+ #
1242
+ # @overload update_tag_template(request, options = nil)
1243
+ # Pass arguments to `update_tag_template` via a request object, either of type
1244
+ # {::Google::Cloud::DataCatalog::V1beta1::UpdateTagTemplateRequest} or an equivalent Hash.
1245
+ #
1246
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::UpdateTagTemplateRequest, ::Hash]
1247
+ # A request object representing the call parameters. Required. To specify no
1248
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1249
+ # @param options [::Gapic::CallOptions, ::Hash]
1250
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1251
+ #
1252
+ # @overload update_tag_template(tag_template: nil, update_mask: nil)
1253
+ # Pass arguments to `update_tag_template` via keyword arguments. Note that at
1254
+ # least one keyword argument is required. To specify no parameters, or to keep all
1255
+ # the default parameter values, pass an empty Hash as a request object (see above).
1256
+ #
1257
+ # @param tag_template [::Google::Cloud::DataCatalog::V1beta1::TagTemplate, ::Hash]
1258
+ # Required. The template to update. The "name" field must be set.
1259
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
1260
+ # Names of fields whose values to overwrite on a tag template. Currently,
1261
+ # only `display_name` can be overwritten.
1262
+ #
1263
+ # In general, if this parameter is absent or empty, all modifiable fields
1264
+ # are overwritten. If such fields are non-required and omitted in the
1265
+ # request body, their values are emptied.
1266
+ # @yield [result, operation] Access the result along with the TransportOperation object
1267
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::TagTemplate]
1268
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1269
+ #
1270
+ # @return [::Google::Cloud::DataCatalog::V1beta1::TagTemplate]
1271
+ #
1272
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1273
+ def update_tag_template request, options = nil
1274
+ raise ::ArgumentError, "request must be provided" if request.nil?
1275
+
1276
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::UpdateTagTemplateRequest
1277
+
1278
+ # Converts hash and nil to an options object
1279
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1280
+
1281
+ # Customize the options with defaults
1282
+ call_metadata = @config.rpcs.update_tag_template.metadata.to_h
1283
+
1284
+ # Set x-goog-api-client and x-goog-user-project headers
1285
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1286
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1287
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1288
+ transports_version_send: [:rest]
1289
+
1290
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1291
+
1292
+ options.apply_defaults timeout: @config.rpcs.update_tag_template.timeout,
1293
+ metadata: call_metadata,
1294
+ retry_policy: @config.rpcs.update_tag_template.retry_policy
1295
+
1296
+ options.apply_defaults timeout: @config.timeout,
1297
+ metadata: @config.metadata,
1298
+ retry_policy: @config.retry_policy
1299
+
1300
+ @data_catalog_stub.update_tag_template request, options do |result, operation|
1301
+ yield result, operation if block_given?
1302
+ return result
1303
+ end
1304
+ rescue ::Gapic::Rest::Error => e
1305
+ raise ::Google::Cloud::Error.from_error(e)
1306
+ end
1307
+
1308
+ ##
1309
+ # Deletes a tag template and all tags using the template.
1310
+ # Users should enable the Data Catalog API in the project identified by
1311
+ # the `name` parameter (see [Data Catalog Resource Project]
1312
+ # (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for
1313
+ # more information).
1314
+ #
1315
+ # @overload delete_tag_template(request, options = nil)
1316
+ # Pass arguments to `delete_tag_template` via a request object, either of type
1317
+ # {::Google::Cloud::DataCatalog::V1beta1::DeleteTagTemplateRequest} or an equivalent Hash.
1318
+ #
1319
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::DeleteTagTemplateRequest, ::Hash]
1320
+ # A request object representing the call parameters. Required. To specify no
1321
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1322
+ # @param options [::Gapic::CallOptions, ::Hash]
1323
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1324
+ #
1325
+ # @overload delete_tag_template(name: nil, force: nil)
1326
+ # Pass arguments to `delete_tag_template` via keyword arguments. Note that at
1327
+ # least one keyword argument is required. To specify no parameters, or to keep all
1328
+ # the default parameter values, pass an empty Hash as a request object (see above).
1329
+ #
1330
+ # @param name [::String]
1331
+ # Required. The name of the tag template to delete. Example:
1332
+ #
1333
+ # * projects/\\{project_id}/locations/\\{location}/tagTemplates/\\{tag_template_id}
1334
+ # @param force [::Boolean]
1335
+ # Required. Currently, this field must always be set to `true`.
1336
+ # This confirms the deletion of any possible tags using this template.
1337
+ # `force = false` will be supported in the future.
1338
+ # @yield [result, operation] Access the result along with the TransportOperation object
1339
+ # @yieldparam result [::Google::Protobuf::Empty]
1340
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1341
+ #
1342
+ # @return [::Google::Protobuf::Empty]
1343
+ #
1344
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1345
+ def delete_tag_template request, options = nil
1346
+ raise ::ArgumentError, "request must be provided" if request.nil?
1347
+
1348
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::DeleteTagTemplateRequest
1349
+
1350
+ # Converts hash and nil to an options object
1351
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1352
+
1353
+ # Customize the options with defaults
1354
+ call_metadata = @config.rpcs.delete_tag_template.metadata.to_h
1355
+
1356
+ # Set x-goog-api-client and x-goog-user-project headers
1357
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1358
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1359
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1360
+ transports_version_send: [:rest]
1361
+
1362
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1363
+
1364
+ options.apply_defaults timeout: @config.rpcs.delete_tag_template.timeout,
1365
+ metadata: call_metadata,
1366
+ retry_policy: @config.rpcs.delete_tag_template.retry_policy
1367
+
1368
+ options.apply_defaults timeout: @config.timeout,
1369
+ metadata: @config.metadata,
1370
+ retry_policy: @config.retry_policy
1371
+
1372
+ @data_catalog_stub.delete_tag_template request, options do |result, operation|
1373
+ yield result, operation if block_given?
1374
+ return result
1375
+ end
1376
+ rescue ::Gapic::Rest::Error => e
1377
+ raise ::Google::Cloud::Error.from_error(e)
1378
+ end
1379
+
1380
+ ##
1381
+ # Creates a field in a tag template. The user should enable the Data Catalog
1382
+ # API in the project identified by the `parent` parameter (see
1383
+ # [Data Catalog Resource
1384
+ # Project](https://cloud.google.com/data-catalog/docs/concepts/resource-project)
1385
+ # for more information).
1386
+ #
1387
+ # @overload create_tag_template_field(request, options = nil)
1388
+ # Pass arguments to `create_tag_template_field` via a request object, either of type
1389
+ # {::Google::Cloud::DataCatalog::V1beta1::CreateTagTemplateFieldRequest} or an equivalent Hash.
1390
+ #
1391
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::CreateTagTemplateFieldRequest, ::Hash]
1392
+ # A request object representing the call parameters. Required. To specify no
1393
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1394
+ # @param options [::Gapic::CallOptions, ::Hash]
1395
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1396
+ #
1397
+ # @overload create_tag_template_field(parent: nil, tag_template_field_id: nil, tag_template_field: nil)
1398
+ # Pass arguments to `create_tag_template_field` via keyword arguments. Note that at
1399
+ # least one keyword argument is required. To specify no parameters, or to keep all
1400
+ # the default parameter values, pass an empty Hash as a request object (see above).
1401
+ #
1402
+ # @param parent [::String]
1403
+ # Required. The name of the project and the template location
1404
+ # [region](https://cloud.google.com/data-catalog/docs/concepts/regions).
1405
+ #
1406
+ # Example:
1407
+ #
1408
+ # * projects/\\{project_id}/locations/us-central1/tagTemplates/\\{tag_template_id}
1409
+ # @param tag_template_field_id [::String]
1410
+ # Required. The ID of the tag template field to create.
1411
+ # Field ids can contain letters (both uppercase and lowercase), numbers
1412
+ # (0-9), underscores (_) and dashes (-). Field IDs must be at least 1
1413
+ # character long and at most 128 characters long. Field IDs must also be
1414
+ # unique within their template.
1415
+ # @param tag_template_field [::Google::Cloud::DataCatalog::V1beta1::TagTemplateField, ::Hash]
1416
+ # Required. The tag template field to create.
1417
+ # @yield [result, operation] Access the result along with the TransportOperation object
1418
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::TagTemplateField]
1419
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1420
+ #
1421
+ # @return [::Google::Cloud::DataCatalog::V1beta1::TagTemplateField]
1422
+ #
1423
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1424
+ def create_tag_template_field request, options = nil
1425
+ raise ::ArgumentError, "request must be provided" if request.nil?
1426
+
1427
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::CreateTagTemplateFieldRequest
1428
+
1429
+ # Converts hash and nil to an options object
1430
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1431
+
1432
+ # Customize the options with defaults
1433
+ call_metadata = @config.rpcs.create_tag_template_field.metadata.to_h
1434
+
1435
+ # Set x-goog-api-client and x-goog-user-project headers
1436
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1437
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1438
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1439
+ transports_version_send: [:rest]
1440
+
1441
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1442
+
1443
+ options.apply_defaults timeout: @config.rpcs.create_tag_template_field.timeout,
1444
+ metadata: call_metadata,
1445
+ retry_policy: @config.rpcs.create_tag_template_field.retry_policy
1446
+
1447
+ options.apply_defaults timeout: @config.timeout,
1448
+ metadata: @config.metadata,
1449
+ retry_policy: @config.retry_policy
1450
+
1451
+ @data_catalog_stub.create_tag_template_field request, options do |result, operation|
1452
+ yield result, operation if block_given?
1453
+ return result
1454
+ end
1455
+ rescue ::Gapic::Rest::Error => e
1456
+ raise ::Google::Cloud::Error.from_error(e)
1457
+ end
1458
+
1459
+ ##
1460
+ # Updates a field in a tag template. This method cannot be used to update the
1461
+ # field type. Users should enable the Data Catalog API in the project
1462
+ # identified by the `name` parameter (see [Data Catalog Resource Project]
1463
+ # (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for
1464
+ # more information).
1465
+ #
1466
+ # @overload update_tag_template_field(request, options = nil)
1467
+ # Pass arguments to `update_tag_template_field` via a request object, either of type
1468
+ # {::Google::Cloud::DataCatalog::V1beta1::UpdateTagTemplateFieldRequest} or an equivalent Hash.
1469
+ #
1470
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::UpdateTagTemplateFieldRequest, ::Hash]
1471
+ # A request object representing the call parameters. Required. To specify no
1472
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1473
+ # @param options [::Gapic::CallOptions, ::Hash]
1474
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1475
+ #
1476
+ # @overload update_tag_template_field(name: nil, tag_template_field: nil, update_mask: nil)
1477
+ # Pass arguments to `update_tag_template_field` via keyword arguments. Note that at
1478
+ # least one keyword argument is required. To specify no parameters, or to keep all
1479
+ # the default parameter values, pass an empty Hash as a request object (see above).
1480
+ #
1481
+ # @param name [::String]
1482
+ # Required. The name of the tag template field. Example:
1483
+ #
1484
+ # * projects/\\{project_id}/locations/\\{location}/tagTemplates/\\{tag_template_id}/fields/\\{tag_template_field_id}
1485
+ # @param tag_template_field [::Google::Cloud::DataCatalog::V1beta1::TagTemplateField, ::Hash]
1486
+ # Required. The template to update.
1487
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
1488
+ # Optional. Names of fields whose values to overwrite on an individual field
1489
+ # of a tag template. The following fields are modifiable:
1490
+ #
1491
+ # * `display_name`
1492
+ # * `type.enum_type`
1493
+ # * `is_required`
1494
+ #
1495
+ # If this parameter is absent or empty, all modifiable fields
1496
+ # are overwritten. If such fields are non-required and omitted in the request
1497
+ # body, their values are emptied with one exception: when updating an enum
1498
+ # type, the provided values are merged with the existing values. Therefore,
1499
+ # enum values can only be added, existing enum values cannot be deleted or
1500
+ # renamed.
1501
+ #
1502
+ # Additionally, updating a template field from optional to required is
1503
+ # *not* allowed.
1504
+ # @yield [result, operation] Access the result along with the TransportOperation object
1505
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::TagTemplateField]
1506
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1507
+ #
1508
+ # @return [::Google::Cloud::DataCatalog::V1beta1::TagTemplateField]
1509
+ #
1510
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1511
+ def update_tag_template_field request, options = nil
1512
+ raise ::ArgumentError, "request must be provided" if request.nil?
1513
+
1514
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::UpdateTagTemplateFieldRequest
1515
+
1516
+ # Converts hash and nil to an options object
1517
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1518
+
1519
+ # Customize the options with defaults
1520
+ call_metadata = @config.rpcs.update_tag_template_field.metadata.to_h
1521
+
1522
+ # Set x-goog-api-client and x-goog-user-project headers
1523
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1524
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1525
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1526
+ transports_version_send: [:rest]
1527
+
1528
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1529
+
1530
+ options.apply_defaults timeout: @config.rpcs.update_tag_template_field.timeout,
1531
+ metadata: call_metadata,
1532
+ retry_policy: @config.rpcs.update_tag_template_field.retry_policy
1533
+
1534
+ options.apply_defaults timeout: @config.timeout,
1535
+ metadata: @config.metadata,
1536
+ retry_policy: @config.retry_policy
1537
+
1538
+ @data_catalog_stub.update_tag_template_field request, options do |result, operation|
1539
+ yield result, operation if block_given?
1540
+ return result
1541
+ end
1542
+ rescue ::Gapic::Rest::Error => e
1543
+ raise ::Google::Cloud::Error.from_error(e)
1544
+ end
1545
+
1546
+ ##
1547
+ # Renames a field in a tag template. The user should enable the Data Catalog
1548
+ # API in the project identified by the `name` parameter (see [Data Catalog
1549
+ # Resource
1550
+ # Project](https://cloud.google.com/data-catalog/docs/concepts/resource-project)
1551
+ # for more information).
1552
+ #
1553
+ # @overload rename_tag_template_field(request, options = nil)
1554
+ # Pass arguments to `rename_tag_template_field` via a request object, either of type
1555
+ # {::Google::Cloud::DataCatalog::V1beta1::RenameTagTemplateFieldRequest} or an equivalent Hash.
1556
+ #
1557
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::RenameTagTemplateFieldRequest, ::Hash]
1558
+ # A request object representing the call parameters. Required. To specify no
1559
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1560
+ # @param options [::Gapic::CallOptions, ::Hash]
1561
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1562
+ #
1563
+ # @overload rename_tag_template_field(name: nil, new_tag_template_field_id: nil)
1564
+ # Pass arguments to `rename_tag_template_field` via keyword arguments. Note that at
1565
+ # least one keyword argument is required. To specify no parameters, or to keep all
1566
+ # the default parameter values, pass an empty Hash as a request object (see above).
1567
+ #
1568
+ # @param name [::String]
1569
+ # Required. The name of the tag template. Example:
1570
+ #
1571
+ # * projects/\\{project_id}/locations/\\{location}/tagTemplates/\\{tag_template_id}/fields/\\{tag_template_field_id}
1572
+ # @param new_tag_template_field_id [::String]
1573
+ # Required. The new ID of this tag template field. For example,
1574
+ # `my_new_field`.
1575
+ # @yield [result, operation] Access the result along with the TransportOperation object
1576
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::TagTemplateField]
1577
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1578
+ #
1579
+ # @return [::Google::Cloud::DataCatalog::V1beta1::TagTemplateField]
1580
+ #
1581
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1582
+ def rename_tag_template_field request, options = nil
1583
+ raise ::ArgumentError, "request must be provided" if request.nil?
1584
+
1585
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::RenameTagTemplateFieldRequest
1586
+
1587
+ # Converts hash and nil to an options object
1588
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1589
+
1590
+ # Customize the options with defaults
1591
+ call_metadata = @config.rpcs.rename_tag_template_field.metadata.to_h
1592
+
1593
+ # Set x-goog-api-client and x-goog-user-project headers
1594
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1595
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1596
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1597
+ transports_version_send: [:rest]
1598
+
1599
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1600
+
1601
+ options.apply_defaults timeout: @config.rpcs.rename_tag_template_field.timeout,
1602
+ metadata: call_metadata,
1603
+ retry_policy: @config.rpcs.rename_tag_template_field.retry_policy
1604
+
1605
+ options.apply_defaults timeout: @config.timeout,
1606
+ metadata: @config.metadata,
1607
+ retry_policy: @config.retry_policy
1608
+
1609
+ @data_catalog_stub.rename_tag_template_field request, options do |result, operation|
1610
+ yield result, operation if block_given?
1611
+ return result
1612
+ end
1613
+ rescue ::Gapic::Rest::Error => e
1614
+ raise ::Google::Cloud::Error.from_error(e)
1615
+ end
1616
+
1617
+ ##
1618
+ # Renames an enum value in a tag template. The enum values have to be unique
1619
+ # within one enum field. Thus, an enum value cannot be renamed with a name
1620
+ # used in any other enum value within the same enum field.
1621
+ #
1622
+ # @overload rename_tag_template_field_enum_value(request, options = nil)
1623
+ # Pass arguments to `rename_tag_template_field_enum_value` via a request object, either of type
1624
+ # {::Google::Cloud::DataCatalog::V1beta1::RenameTagTemplateFieldEnumValueRequest} or an equivalent Hash.
1625
+ #
1626
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::RenameTagTemplateFieldEnumValueRequest, ::Hash]
1627
+ # A request object representing the call parameters. Required. To specify no
1628
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1629
+ # @param options [::Gapic::CallOptions, ::Hash]
1630
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1631
+ #
1632
+ # @overload rename_tag_template_field_enum_value(name: nil, new_enum_value_display_name: nil)
1633
+ # Pass arguments to `rename_tag_template_field_enum_value` via keyword arguments. Note that at
1634
+ # least one keyword argument is required. To specify no parameters, or to keep all
1635
+ # the default parameter values, pass an empty Hash as a request object (see above).
1636
+ #
1637
+ # @param name [::String]
1638
+ # Required. The name of the enum field value. Example:
1639
+ #
1640
+ # * projects/\\{project_id}/locations/\\{location}/tagTemplates/\\{tag_template_id}/fields/\\{tag_template_field_id}/enumValues/\\{enum_value_display_name}
1641
+ # @param new_enum_value_display_name [::String]
1642
+ # Required. The new display name of the enum value. For example,
1643
+ # `my_new_enum_value`.
1644
+ # @yield [result, operation] Access the result along with the TransportOperation object
1645
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::TagTemplateField]
1646
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1647
+ #
1648
+ # @return [::Google::Cloud::DataCatalog::V1beta1::TagTemplateField]
1649
+ #
1650
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1651
+ def rename_tag_template_field_enum_value request, options = nil
1652
+ raise ::ArgumentError, "request must be provided" if request.nil?
1653
+
1654
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::RenameTagTemplateFieldEnumValueRequest
1655
+
1656
+ # Converts hash and nil to an options object
1657
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1658
+
1659
+ # Customize the options with defaults
1660
+ call_metadata = @config.rpcs.rename_tag_template_field_enum_value.metadata.to_h
1661
+
1662
+ # Set x-goog-api-client and x-goog-user-project headers
1663
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1664
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1665
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1666
+ transports_version_send: [:rest]
1667
+
1668
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1669
+
1670
+ options.apply_defaults timeout: @config.rpcs.rename_tag_template_field_enum_value.timeout,
1671
+ metadata: call_metadata,
1672
+ retry_policy: @config.rpcs.rename_tag_template_field_enum_value.retry_policy
1673
+
1674
+ options.apply_defaults timeout: @config.timeout,
1675
+ metadata: @config.metadata,
1676
+ retry_policy: @config.retry_policy
1677
+
1678
+ @data_catalog_stub.rename_tag_template_field_enum_value request, options do |result, operation|
1679
+ yield result, operation if block_given?
1680
+ return result
1681
+ end
1682
+ rescue ::Gapic::Rest::Error => e
1683
+ raise ::Google::Cloud::Error.from_error(e)
1684
+ end
1685
+
1686
+ ##
1687
+ # Deletes a field in a tag template and all uses of that field.
1688
+ # Users should enable the Data Catalog API in the project identified by
1689
+ # the `name` parameter (see [Data Catalog Resource Project]
1690
+ # (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for
1691
+ # more information).
1692
+ #
1693
+ # @overload delete_tag_template_field(request, options = nil)
1694
+ # Pass arguments to `delete_tag_template_field` via a request object, either of type
1695
+ # {::Google::Cloud::DataCatalog::V1beta1::DeleteTagTemplateFieldRequest} or an equivalent Hash.
1696
+ #
1697
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::DeleteTagTemplateFieldRequest, ::Hash]
1698
+ # A request object representing the call parameters. Required. To specify no
1699
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1700
+ # @param options [::Gapic::CallOptions, ::Hash]
1701
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1702
+ #
1703
+ # @overload delete_tag_template_field(name: nil, force: nil)
1704
+ # Pass arguments to `delete_tag_template_field` via keyword arguments. Note that at
1705
+ # least one keyword argument is required. To specify no parameters, or to keep all
1706
+ # the default parameter values, pass an empty Hash as a request object (see above).
1707
+ #
1708
+ # @param name [::String]
1709
+ # Required. The name of the tag template field to delete. Example:
1710
+ #
1711
+ # * projects/\\{project_id}/locations/\\{location}/tagTemplates/\\{tag_template_id}/fields/\\{tag_template_field_id}
1712
+ # @param force [::Boolean]
1713
+ # Required. Currently, this field must always be set to `true`.
1714
+ # This confirms the deletion of this field from any tags using this field.
1715
+ # `force = false` will be supported in the future.
1716
+ # @yield [result, operation] Access the result along with the TransportOperation object
1717
+ # @yieldparam result [::Google::Protobuf::Empty]
1718
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1719
+ #
1720
+ # @return [::Google::Protobuf::Empty]
1721
+ #
1722
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1723
+ def delete_tag_template_field request, options = nil
1724
+ raise ::ArgumentError, "request must be provided" if request.nil?
1725
+
1726
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::DeleteTagTemplateFieldRequest
1727
+
1728
+ # Converts hash and nil to an options object
1729
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1730
+
1731
+ # Customize the options with defaults
1732
+ call_metadata = @config.rpcs.delete_tag_template_field.metadata.to_h
1733
+
1734
+ # Set x-goog-api-client and x-goog-user-project headers
1735
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1736
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1737
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1738
+ transports_version_send: [:rest]
1739
+
1740
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1741
+
1742
+ options.apply_defaults timeout: @config.rpcs.delete_tag_template_field.timeout,
1743
+ metadata: call_metadata,
1744
+ retry_policy: @config.rpcs.delete_tag_template_field.retry_policy
1745
+
1746
+ options.apply_defaults timeout: @config.timeout,
1747
+ metadata: @config.metadata,
1748
+ retry_policy: @config.retry_policy
1749
+
1750
+ @data_catalog_stub.delete_tag_template_field request, options do |result, operation|
1751
+ yield result, operation if block_given?
1752
+ return result
1753
+ end
1754
+ rescue ::Gapic::Rest::Error => e
1755
+ raise ::Google::Cloud::Error.from_error(e)
1756
+ end
1757
+
1758
+ ##
1759
+ # Creates a tag on an {::Google::Cloud::DataCatalog::V1beta1::Entry Entry}.
1760
+ # Note: The project identified by the `parent` parameter for the
1761
+ # [tag](https://cloud.google.com/data-catalog/docs/reference/rest/v1beta1/projects.locations.entryGroups.entries.tags/create#path-parameters)
1762
+ # and the
1763
+ # [tag
1764
+ # template](https://cloud.google.com/data-catalog/docs/reference/rest/v1beta1/projects.locations.tagTemplates/create#path-parameters)
1765
+ # used to create the tag must be from the same organization.
1766
+ #
1767
+ # @overload create_tag(request, options = nil)
1768
+ # Pass arguments to `create_tag` via a request object, either of type
1769
+ # {::Google::Cloud::DataCatalog::V1beta1::CreateTagRequest} or an equivalent Hash.
1770
+ #
1771
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::CreateTagRequest, ::Hash]
1772
+ # A request object representing the call parameters. Required. To specify no
1773
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1774
+ # @param options [::Gapic::CallOptions, ::Hash]
1775
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1776
+ #
1777
+ # @overload create_tag(parent: nil, tag: nil)
1778
+ # Pass arguments to `create_tag` via keyword arguments. Note that at
1779
+ # least one keyword argument is required. To specify no parameters, or to keep all
1780
+ # the default parameter values, pass an empty Hash as a request object (see above).
1781
+ #
1782
+ # @param parent [::String]
1783
+ # Required. The name of the resource to attach this tag to. Tags can be
1784
+ # attached to Entries. Example:
1785
+ #
1786
+ # * projects/\\{project_id}/locations/\\{location}/entryGroups/\\{entry_group_id}/entries/\\{entry_id}
1787
+ #
1788
+ # Note that this Tag and its child resources may not actually be stored in
1789
+ # the location in this name.
1790
+ # @param tag [::Google::Cloud::DataCatalog::V1beta1::Tag, ::Hash]
1791
+ # Required. The tag to create.
1792
+ # @yield [result, operation] Access the result along with the TransportOperation object
1793
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::Tag]
1794
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1795
+ #
1796
+ # @return [::Google::Cloud::DataCatalog::V1beta1::Tag]
1797
+ #
1798
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1799
+ def create_tag request, options = nil
1800
+ raise ::ArgumentError, "request must be provided" if request.nil?
1801
+
1802
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::CreateTagRequest
1803
+
1804
+ # Converts hash and nil to an options object
1805
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1806
+
1807
+ # Customize the options with defaults
1808
+ call_metadata = @config.rpcs.create_tag.metadata.to_h
1809
+
1810
+ # Set x-goog-api-client and x-goog-user-project headers
1811
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1812
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1813
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1814
+ transports_version_send: [:rest]
1815
+
1816
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1817
+
1818
+ options.apply_defaults timeout: @config.rpcs.create_tag.timeout,
1819
+ metadata: call_metadata,
1820
+ retry_policy: @config.rpcs.create_tag.retry_policy
1821
+
1822
+ options.apply_defaults timeout: @config.timeout,
1823
+ metadata: @config.metadata,
1824
+ retry_policy: @config.retry_policy
1825
+
1826
+ @data_catalog_stub.create_tag request, options do |result, operation|
1827
+ yield result, operation if block_given?
1828
+ return result
1829
+ end
1830
+ rescue ::Gapic::Rest::Error => e
1831
+ raise ::Google::Cloud::Error.from_error(e)
1832
+ end
1833
+
1834
+ ##
1835
+ # Updates an existing tag.
1836
+ #
1837
+ # @overload update_tag(request, options = nil)
1838
+ # Pass arguments to `update_tag` via a request object, either of type
1839
+ # {::Google::Cloud::DataCatalog::V1beta1::UpdateTagRequest} or an equivalent Hash.
1840
+ #
1841
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::UpdateTagRequest, ::Hash]
1842
+ # A request object representing the call parameters. Required. To specify no
1843
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1844
+ # @param options [::Gapic::CallOptions, ::Hash]
1845
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1846
+ #
1847
+ # @overload update_tag(tag: nil, update_mask: nil)
1848
+ # Pass arguments to `update_tag` via keyword arguments. Note that at
1849
+ # least one keyword argument is required. To specify no parameters, or to keep all
1850
+ # the default parameter values, pass an empty Hash as a request object (see above).
1851
+ #
1852
+ # @param tag [::Google::Cloud::DataCatalog::V1beta1::Tag, ::Hash]
1853
+ # Required. The updated tag. The "name" field must be set.
1854
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
1855
+ # Note: Currently, this parameter can only take `"fields"` as value.
1856
+ #
1857
+ # Names of fields whose values to overwrite on a tag. Currently, a tag has
1858
+ # the only modifiable field with the name `fields`.
1859
+ #
1860
+ # In general, if this parameter is absent or empty, all modifiable fields
1861
+ # are overwritten. If such fields are non-required and omitted in the
1862
+ # request body, their values are emptied.
1863
+ # @yield [result, operation] Access the result along with the TransportOperation object
1864
+ # @yieldparam result [::Google::Cloud::DataCatalog::V1beta1::Tag]
1865
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1866
+ #
1867
+ # @return [::Google::Cloud::DataCatalog::V1beta1::Tag]
1868
+ #
1869
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1870
+ def update_tag request, options = nil
1871
+ raise ::ArgumentError, "request must be provided" if request.nil?
1872
+
1873
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::UpdateTagRequest
1874
+
1875
+ # Converts hash and nil to an options object
1876
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1877
+
1878
+ # Customize the options with defaults
1879
+ call_metadata = @config.rpcs.update_tag.metadata.to_h
1880
+
1881
+ # Set x-goog-api-client and x-goog-user-project headers
1882
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1883
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1884
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1885
+ transports_version_send: [:rest]
1886
+
1887
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1888
+
1889
+ options.apply_defaults timeout: @config.rpcs.update_tag.timeout,
1890
+ metadata: call_metadata,
1891
+ retry_policy: @config.rpcs.update_tag.retry_policy
1892
+
1893
+ options.apply_defaults timeout: @config.timeout,
1894
+ metadata: @config.metadata,
1895
+ retry_policy: @config.retry_policy
1896
+
1897
+ @data_catalog_stub.update_tag request, options do |result, operation|
1898
+ yield result, operation if block_given?
1899
+ return result
1900
+ end
1901
+ rescue ::Gapic::Rest::Error => e
1902
+ raise ::Google::Cloud::Error.from_error(e)
1903
+ end
1904
+
1905
+ ##
1906
+ # Deletes a tag.
1907
+ #
1908
+ # @overload delete_tag(request, options = nil)
1909
+ # Pass arguments to `delete_tag` via a request object, either of type
1910
+ # {::Google::Cloud::DataCatalog::V1beta1::DeleteTagRequest} or an equivalent Hash.
1911
+ #
1912
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::DeleteTagRequest, ::Hash]
1913
+ # A request object representing the call parameters. Required. To specify no
1914
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1915
+ # @param options [::Gapic::CallOptions, ::Hash]
1916
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1917
+ #
1918
+ # @overload delete_tag(name: nil)
1919
+ # Pass arguments to `delete_tag` via keyword arguments. Note that at
1920
+ # least one keyword argument is required. To specify no parameters, or to keep all
1921
+ # the default parameter values, pass an empty Hash as a request object (see above).
1922
+ #
1923
+ # @param name [::String]
1924
+ # Required. The name of the tag to delete. Example:
1925
+ #
1926
+ # * projects/\\{project_id}/locations/\\{location}/entryGroups/\\{entry_group_id}/entries/\\{entry_id}/tags/\\{tag_id}
1927
+ # @yield [result, operation] Access the result along with the TransportOperation object
1928
+ # @yieldparam result [::Google::Protobuf::Empty]
1929
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1930
+ #
1931
+ # @return [::Google::Protobuf::Empty]
1932
+ #
1933
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1934
+ def delete_tag request, options = nil
1935
+ raise ::ArgumentError, "request must be provided" if request.nil?
1936
+
1937
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::DeleteTagRequest
1938
+
1939
+ # Converts hash and nil to an options object
1940
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1941
+
1942
+ # Customize the options with defaults
1943
+ call_metadata = @config.rpcs.delete_tag.metadata.to_h
1944
+
1945
+ # Set x-goog-api-client and x-goog-user-project headers
1946
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1947
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1948
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
1949
+ transports_version_send: [:rest]
1950
+
1951
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1952
+
1953
+ options.apply_defaults timeout: @config.rpcs.delete_tag.timeout,
1954
+ metadata: call_metadata,
1955
+ retry_policy: @config.rpcs.delete_tag.retry_policy
1956
+
1957
+ options.apply_defaults timeout: @config.timeout,
1958
+ metadata: @config.metadata,
1959
+ retry_policy: @config.retry_policy
1960
+
1961
+ @data_catalog_stub.delete_tag request, options do |result, operation|
1962
+ yield result, operation if block_given?
1963
+ return result
1964
+ end
1965
+ rescue ::Gapic::Rest::Error => e
1966
+ raise ::Google::Cloud::Error.from_error(e)
1967
+ end
1968
+
1969
+ ##
1970
+ # Lists tags assigned to an {::Google::Cloud::DataCatalog::V1beta1::Entry Entry}.
1971
+ # The {::Google::Cloud::DataCatalog::V1beta1::Tag#column columns} in the response
1972
+ # are lowercased.
1973
+ #
1974
+ # @overload list_tags(request, options = nil)
1975
+ # Pass arguments to `list_tags` via a request object, either of type
1976
+ # {::Google::Cloud::DataCatalog::V1beta1::ListTagsRequest} or an equivalent Hash.
1977
+ #
1978
+ # @param request [::Google::Cloud::DataCatalog::V1beta1::ListTagsRequest, ::Hash]
1979
+ # A request object representing the call parameters. Required. To specify no
1980
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1981
+ # @param options [::Gapic::CallOptions, ::Hash]
1982
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1983
+ #
1984
+ # @overload list_tags(parent: nil, page_size: nil, page_token: nil)
1985
+ # Pass arguments to `list_tags` via keyword arguments. Note that at
1986
+ # least one keyword argument is required. To specify no parameters, or to keep all
1987
+ # the default parameter values, pass an empty Hash as a request object (see above).
1988
+ #
1989
+ # @param parent [::String]
1990
+ # Required. The name of the Data Catalog resource to list the tags of. The
1991
+ # resource could be an {::Google::Cloud::DataCatalog::V1beta1::Entry Entry} or an
1992
+ # {::Google::Cloud::DataCatalog::V1beta1::EntryGroup EntryGroup}.
1993
+ #
1994
+ # Examples:
1995
+ #
1996
+ # * projects/\\{project_id}/locations/\\{location}/entryGroups/\\{entry_group_id}
1997
+ # * projects/\\{project_id}/locations/\\{location}/entryGroups/\\{entry_group_id}/entries/\\{entry_id}
1998
+ # @param page_size [::Integer]
1999
+ # The maximum number of tags to return. Default is 10. Max limit is 1000.
2000
+ # @param page_token [::String]
2001
+ # Token that specifies which page is requested. If empty, the first page is
2002
+ # returned.
2003
+ # @yield [result, operation] Access the result along with the TransportOperation object
2004
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::DataCatalog::V1beta1::Tag>]
2005
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2006
+ #
2007
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::DataCatalog::V1beta1::Tag>]
2008
+ #
2009
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2010
+ def list_tags request, options = nil
2011
+ raise ::ArgumentError, "request must be provided" if request.nil?
2012
+
2013
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DataCatalog::V1beta1::ListTagsRequest
2014
+
2015
+ # Converts hash and nil to an options object
2016
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2017
+
2018
+ # Customize the options with defaults
2019
+ call_metadata = @config.rpcs.list_tags.metadata.to_h
2020
+
2021
+ # Set x-goog-api-client and x-goog-user-project headers
2022
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2023
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2024
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
2025
+ transports_version_send: [:rest]
2026
+
2027
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2028
+
2029
+ options.apply_defaults timeout: @config.rpcs.list_tags.timeout,
2030
+ metadata: call_metadata,
2031
+ retry_policy: @config.rpcs.list_tags.retry_policy
2032
+
2033
+ options.apply_defaults timeout: @config.timeout,
2034
+ metadata: @config.metadata,
2035
+ retry_policy: @config.retry_policy
2036
+
2037
+ @data_catalog_stub.list_tags request, options do |result, operation|
2038
+ result = ::Gapic::Rest::PagedEnumerable.new @data_catalog_stub, :list_tags, "tags", request, result, options
2039
+ yield result, operation if block_given?
2040
+ return result
2041
+ end
2042
+ rescue ::Gapic::Rest::Error => e
2043
+ raise ::Google::Cloud::Error.from_error(e)
2044
+ end
2045
+
2046
+ ##
2047
+ # Sets the access control policy for a resource. Replaces any existing
2048
+ # policy.
2049
+ # Supported resources are:
2050
+ # - Tag templates.
2051
+ # - Entries.
2052
+ # - Entry groups.
2053
+ # Note, this method cannot be used to manage policies for BigQuery, Pub/Sub
2054
+ # and any external Google Cloud Platform resources synced to Data Catalog.
2055
+ #
2056
+ # Callers must have following Google IAM permission
2057
+ # - `datacatalog.tagTemplates.setIamPolicy` to set policies on tag
2058
+ # templates.
2059
+ # - `datacatalog.entries.setIamPolicy` to set policies on entries.
2060
+ # - `datacatalog.entryGroups.setIamPolicy` to set policies on entry groups.
2061
+ #
2062
+ # @overload set_iam_policy(request, options = nil)
2063
+ # Pass arguments to `set_iam_policy` via a request object, either of type
2064
+ # {::Google::Iam::V1::SetIamPolicyRequest} or an equivalent Hash.
2065
+ #
2066
+ # @param request [::Google::Iam::V1::SetIamPolicyRequest, ::Hash]
2067
+ # A request object representing the call parameters. Required. To specify no
2068
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
2069
+ # @param options [::Gapic::CallOptions, ::Hash]
2070
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
2071
+ #
2072
+ # @overload set_iam_policy(resource: nil, policy: nil, update_mask: nil)
2073
+ # Pass arguments to `set_iam_policy` via keyword arguments. Note that at
2074
+ # least one keyword argument is required. To specify no parameters, or to keep all
2075
+ # the default parameter values, pass an empty Hash as a request object (see above).
2076
+ #
2077
+ # @param resource [::String]
2078
+ # REQUIRED: The resource for which the policy is being specified.
2079
+ # See the operation documentation for the appropriate value for this field.
2080
+ # @param policy [::Google::Iam::V1::Policy, ::Hash]
2081
+ # REQUIRED: The complete policy to be applied to the `resource`. The size of
2082
+ # the policy is limited to a few 10s of KB. An empty policy is a
2083
+ # valid policy but certain Cloud Platform services (such as Projects)
2084
+ # might reject them.
2085
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
2086
+ # OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only
2087
+ # the fields in the mask will be modified. If no mask is provided, the
2088
+ # following default mask is used:
2089
+ #
2090
+ # `paths: "bindings, etag"`
2091
+ # @yield [result, operation] Access the result along with the TransportOperation object
2092
+ # @yieldparam result [::Google::Iam::V1::Policy]
2093
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2094
+ #
2095
+ # @return [::Google::Iam::V1::Policy]
2096
+ #
2097
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2098
+ def set_iam_policy request, options = nil
2099
+ raise ::ArgumentError, "request must be provided" if request.nil?
2100
+
2101
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Iam::V1::SetIamPolicyRequest
2102
+
2103
+ # Converts hash and nil to an options object
2104
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2105
+
2106
+ # Customize the options with defaults
2107
+ call_metadata = @config.rpcs.set_iam_policy.metadata.to_h
2108
+
2109
+ # Set x-goog-api-client and x-goog-user-project headers
2110
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2111
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2112
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
2113
+ transports_version_send: [:rest]
2114
+
2115
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2116
+
2117
+ options.apply_defaults timeout: @config.rpcs.set_iam_policy.timeout,
2118
+ metadata: call_metadata,
2119
+ retry_policy: @config.rpcs.set_iam_policy.retry_policy
2120
+
2121
+ options.apply_defaults timeout: @config.timeout,
2122
+ metadata: @config.metadata,
2123
+ retry_policy: @config.retry_policy
2124
+
2125
+ @data_catalog_stub.set_iam_policy request, options do |result, operation|
2126
+ yield result, operation if block_given?
2127
+ return result
2128
+ end
2129
+ rescue ::Gapic::Rest::Error => e
2130
+ raise ::Google::Cloud::Error.from_error(e)
2131
+ end
2132
+
2133
+ ##
2134
+ # Gets the access control policy for a resource. A `NOT_FOUND` error
2135
+ # is returned if the resource does not exist. An empty policy is returned
2136
+ # if the resource exists but does not have a policy set on it.
2137
+ #
2138
+ # Supported resources are:
2139
+ # - Tag templates.
2140
+ # - Entries.
2141
+ # - Entry groups.
2142
+ # Note, this method cannot be used to manage policies for BigQuery, Pub/Sub
2143
+ # and any external Google Cloud Platform resources synced to Data Catalog.
2144
+ #
2145
+ # Callers must have following Google IAM permission
2146
+ # - `datacatalog.tagTemplates.getIamPolicy` to get policies on tag
2147
+ # templates.
2148
+ # - `datacatalog.entries.getIamPolicy` to get policies on entries.
2149
+ # - `datacatalog.entryGroups.getIamPolicy` to get policies on entry groups.
2150
+ #
2151
+ # @overload get_iam_policy(request, options = nil)
2152
+ # Pass arguments to `get_iam_policy` via a request object, either of type
2153
+ # {::Google::Iam::V1::GetIamPolicyRequest} or an equivalent Hash.
2154
+ #
2155
+ # @param request [::Google::Iam::V1::GetIamPolicyRequest, ::Hash]
2156
+ # A request object representing the call parameters. Required. To specify no
2157
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
2158
+ # @param options [::Gapic::CallOptions, ::Hash]
2159
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
2160
+ #
2161
+ # @overload get_iam_policy(resource: nil, options: nil)
2162
+ # Pass arguments to `get_iam_policy` via keyword arguments. Note that at
2163
+ # least one keyword argument is required. To specify no parameters, or to keep all
2164
+ # the default parameter values, pass an empty Hash as a request object (see above).
2165
+ #
2166
+ # @param resource [::String]
2167
+ # REQUIRED: The resource for which the policy is being requested.
2168
+ # See the operation documentation for the appropriate value for this field.
2169
+ # @param options [::Google::Iam::V1::GetPolicyOptions, ::Hash]
2170
+ # OPTIONAL: A `GetPolicyOptions` object for specifying options to
2171
+ # `GetIamPolicy`.
2172
+ # @yield [result, operation] Access the result along with the TransportOperation object
2173
+ # @yieldparam result [::Google::Iam::V1::Policy]
2174
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2175
+ #
2176
+ # @return [::Google::Iam::V1::Policy]
2177
+ #
2178
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2179
+ def get_iam_policy request, options = nil
2180
+ raise ::ArgumentError, "request must be provided" if request.nil?
2181
+
2182
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Iam::V1::GetIamPolicyRequest
2183
+
2184
+ # Converts hash and nil to an options object
2185
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2186
+
2187
+ # Customize the options with defaults
2188
+ call_metadata = @config.rpcs.get_iam_policy.metadata.to_h
2189
+
2190
+ # Set x-goog-api-client and x-goog-user-project headers
2191
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2192
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2193
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
2194
+ transports_version_send: [:rest]
2195
+
2196
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2197
+
2198
+ options.apply_defaults timeout: @config.rpcs.get_iam_policy.timeout,
2199
+ metadata: call_metadata,
2200
+ retry_policy: @config.rpcs.get_iam_policy.retry_policy
2201
+
2202
+ options.apply_defaults timeout: @config.timeout,
2203
+ metadata: @config.metadata,
2204
+ retry_policy: @config.retry_policy
2205
+
2206
+ @data_catalog_stub.get_iam_policy request, options do |result, operation|
2207
+ yield result, operation if block_given?
2208
+ return result
2209
+ end
2210
+ rescue ::Gapic::Rest::Error => e
2211
+ raise ::Google::Cloud::Error.from_error(e)
2212
+ end
2213
+
2214
+ ##
2215
+ # Returns the caller's permissions on a resource.
2216
+ # If the resource does not exist, an empty set of permissions is returned
2217
+ # (We don't return a `NOT_FOUND` error).
2218
+ #
2219
+ # Supported resources are:
2220
+ # - Tag templates.
2221
+ # - Entries.
2222
+ # - Entry groups.
2223
+ # Note, this method cannot be used to manage policies for BigQuery, Pub/Sub
2224
+ # and any external Google Cloud Platform resources synced to Data Catalog.
2225
+ #
2226
+ # A caller is not required to have Google IAM permission to make this
2227
+ # request.
2228
+ #
2229
+ # @overload test_iam_permissions(request, options = nil)
2230
+ # Pass arguments to `test_iam_permissions` via a request object, either of type
2231
+ # {::Google::Iam::V1::TestIamPermissionsRequest} or an equivalent Hash.
2232
+ #
2233
+ # @param request [::Google::Iam::V1::TestIamPermissionsRequest, ::Hash]
2234
+ # A request object representing the call parameters. Required. To specify no
2235
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
2236
+ # @param options [::Gapic::CallOptions, ::Hash]
2237
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
2238
+ #
2239
+ # @overload test_iam_permissions(resource: nil, permissions: nil)
2240
+ # Pass arguments to `test_iam_permissions` via keyword arguments. Note that at
2241
+ # least one keyword argument is required. To specify no parameters, or to keep all
2242
+ # the default parameter values, pass an empty Hash as a request object (see above).
2243
+ #
2244
+ # @param resource [::String]
2245
+ # REQUIRED: The resource for which the policy detail is being requested.
2246
+ # See the operation documentation for the appropriate value for this field.
2247
+ # @param permissions [::Array<::String>]
2248
+ # The set of permissions to check for the `resource`. Permissions with
2249
+ # wildcards (such as '*' or 'storage.*') are not allowed. For more
2250
+ # information see
2251
+ # [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
2252
+ # @yield [result, operation] Access the result along with the TransportOperation object
2253
+ # @yieldparam result [::Google::Iam::V1::TestIamPermissionsResponse]
2254
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2255
+ #
2256
+ # @return [::Google::Iam::V1::TestIamPermissionsResponse]
2257
+ #
2258
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2259
+ def test_iam_permissions request, options = nil
2260
+ raise ::ArgumentError, "request must be provided" if request.nil?
2261
+
2262
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Iam::V1::TestIamPermissionsRequest
2263
+
2264
+ # Converts hash and nil to an options object
2265
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2266
+
2267
+ # Customize the options with defaults
2268
+ call_metadata = @config.rpcs.test_iam_permissions.metadata.to_h
2269
+
2270
+ # Set x-goog-api-client and x-goog-user-project headers
2271
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2272
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2273
+ gapic_version: ::Google::Cloud::DataCatalog::V1beta1::VERSION,
2274
+ transports_version_send: [:rest]
2275
+
2276
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2277
+
2278
+ options.apply_defaults timeout: @config.rpcs.test_iam_permissions.timeout,
2279
+ metadata: call_metadata,
2280
+ retry_policy: @config.rpcs.test_iam_permissions.retry_policy
2281
+
2282
+ options.apply_defaults timeout: @config.timeout,
2283
+ metadata: @config.metadata,
2284
+ retry_policy: @config.retry_policy
2285
+
2286
+ @data_catalog_stub.test_iam_permissions request, options do |result, operation|
2287
+ yield result, operation if block_given?
2288
+ return result
2289
+ end
2290
+ rescue ::Gapic::Rest::Error => e
2291
+ raise ::Google::Cloud::Error.from_error(e)
2292
+ end
2293
+
2294
+ ##
2295
+ # Configuration class for the DataCatalog REST API.
2296
+ #
2297
+ # This class represents the configuration for DataCatalog REST,
2298
+ # providing control over timeouts, retry behavior, logging, transport
2299
+ # parameters, and other low-level controls. Certain parameters can also be
2300
+ # applied individually to specific RPCs. See
2301
+ # {::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::Client::Configuration::Rpcs}
2302
+ # for a list of RPCs that can be configured independently.
2303
+ #
2304
+ # Configuration can be applied globally to all clients, or to a single client
2305
+ # on construction.
2306
+ #
2307
+ # @example
2308
+ #
2309
+ # # Modify the global config, setting the timeout for
2310
+ # # search_catalog to 20 seconds,
2311
+ # # and all remaining timeouts to 10 seconds.
2312
+ # ::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::Client.configure do |config|
2313
+ # config.timeout = 10.0
2314
+ # config.rpcs.search_catalog.timeout = 20.0
2315
+ # end
2316
+ #
2317
+ # # Apply the above configuration only to a new client.
2318
+ # client = ::Google::Cloud::DataCatalog::V1beta1::DataCatalog::Rest::Client.new do |config|
2319
+ # config.timeout = 10.0
2320
+ # config.rpcs.search_catalog.timeout = 20.0
2321
+ # end
2322
+ #
2323
+ # @!attribute [rw] endpoint
2324
+ # The hostname or hostname:port of the service endpoint.
2325
+ # Defaults to `"datacatalog.googleapis.com"`.
2326
+ # @return [::String]
2327
+ # @!attribute [rw] credentials
2328
+ # Credentials to send with calls. You may provide any of the following types:
2329
+ # * (`String`) The path to a service account key file in JSON format
2330
+ # * (`Hash`) A service account key as a Hash
2331
+ # * (`Google::Auth::Credentials`) A googleauth credentials object
2332
+ # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
2333
+ # * (`Signet::OAuth2::Client`) A signet oauth2 client object
2334
+ # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
2335
+ # * (`nil`) indicating no credentials
2336
+ # @return [::Object]
2337
+ # @!attribute [rw] scope
2338
+ # The OAuth scopes
2339
+ # @return [::Array<::String>]
2340
+ # @!attribute [rw] lib_name
2341
+ # The library name as recorded in instrumentation and logging
2342
+ # @return [::String]
2343
+ # @!attribute [rw] lib_version
2344
+ # The library version as recorded in instrumentation and logging
2345
+ # @return [::String]
2346
+ # @!attribute [rw] timeout
2347
+ # The call timeout in seconds.
2348
+ # @return [::Numeric]
2349
+ # @!attribute [rw] metadata
2350
+ # Additional headers to be sent with the call.
2351
+ # @return [::Hash{::Symbol=>::String}]
2352
+ # @!attribute [rw] retry_policy
2353
+ # The retry policy. The value is a hash with the following keys:
2354
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
2355
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
2356
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
2357
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
2358
+ # trigger a retry.
2359
+ # @return [::Hash]
2360
+ # @!attribute [rw] quota_project
2361
+ # A separate project against which to charge quota.
2362
+ # @return [::String]
2363
+ #
2364
+ class Configuration
2365
+ extend ::Gapic::Config
2366
+
2367
+ DEFAULT_ENDPOINT = "datacatalog.googleapis.com"
2368
+
2369
+ config_attr :endpoint, DEFAULT_ENDPOINT, ::String
2370
+ config_attr :credentials, nil do |value|
2371
+ allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
2372
+ allowed.any? { |klass| klass === value }
2373
+ end
2374
+ config_attr :scope, nil, ::String, ::Array, nil
2375
+ config_attr :lib_name, nil, ::String, nil
2376
+ config_attr :lib_version, nil, ::String, nil
2377
+ config_attr :timeout, nil, ::Numeric, nil
2378
+ config_attr :metadata, nil, ::Hash, nil
2379
+ config_attr :retry_policy, nil, ::Hash, ::Proc, nil
2380
+ config_attr :quota_project, nil, ::String, nil
2381
+
2382
+ # @private
2383
+ def initialize parent_config = nil
2384
+ @parent_config = parent_config unless parent_config.nil?
2385
+
2386
+ yield self if block_given?
2387
+ end
2388
+
2389
+ ##
2390
+ # Configurations for individual RPCs
2391
+ # @return [Rpcs]
2392
+ #
2393
+ def rpcs
2394
+ @rpcs ||= begin
2395
+ parent_rpcs = nil
2396
+ parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
2397
+ Rpcs.new parent_rpcs
2398
+ end
2399
+ end
2400
+
2401
+ ##
2402
+ # Configuration RPC class for the DataCatalog API.
2403
+ #
2404
+ # Includes fields providing the configuration for each RPC in this service.
2405
+ # Each configuration object is of type `Gapic::Config::Method` and includes
2406
+ # the following configuration fields:
2407
+ #
2408
+ # * `timeout` (*type:* `Numeric`) - The call timeout in seconds
2409
+ # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers
2410
+ # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
2411
+ # include the following keys:
2412
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
2413
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
2414
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
2415
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
2416
+ # trigger a retry.
2417
+ #
2418
+ class Rpcs
2419
+ ##
2420
+ # RPC-specific configuration for `search_catalog`
2421
+ # @return [::Gapic::Config::Method]
2422
+ #
2423
+ attr_reader :search_catalog
2424
+ ##
2425
+ # RPC-specific configuration for `create_entry_group`
2426
+ # @return [::Gapic::Config::Method]
2427
+ #
2428
+ attr_reader :create_entry_group
2429
+ ##
2430
+ # RPC-specific configuration for `update_entry_group`
2431
+ # @return [::Gapic::Config::Method]
2432
+ #
2433
+ attr_reader :update_entry_group
2434
+ ##
2435
+ # RPC-specific configuration for `get_entry_group`
2436
+ # @return [::Gapic::Config::Method]
2437
+ #
2438
+ attr_reader :get_entry_group
2439
+ ##
2440
+ # RPC-specific configuration for `delete_entry_group`
2441
+ # @return [::Gapic::Config::Method]
2442
+ #
2443
+ attr_reader :delete_entry_group
2444
+ ##
2445
+ # RPC-specific configuration for `list_entry_groups`
2446
+ # @return [::Gapic::Config::Method]
2447
+ #
2448
+ attr_reader :list_entry_groups
2449
+ ##
2450
+ # RPC-specific configuration for `create_entry`
2451
+ # @return [::Gapic::Config::Method]
2452
+ #
2453
+ attr_reader :create_entry
2454
+ ##
2455
+ # RPC-specific configuration for `update_entry`
2456
+ # @return [::Gapic::Config::Method]
2457
+ #
2458
+ attr_reader :update_entry
2459
+ ##
2460
+ # RPC-specific configuration for `delete_entry`
2461
+ # @return [::Gapic::Config::Method]
2462
+ #
2463
+ attr_reader :delete_entry
2464
+ ##
2465
+ # RPC-specific configuration for `get_entry`
2466
+ # @return [::Gapic::Config::Method]
2467
+ #
2468
+ attr_reader :get_entry
2469
+ ##
2470
+ # RPC-specific configuration for `lookup_entry`
2471
+ # @return [::Gapic::Config::Method]
2472
+ #
2473
+ attr_reader :lookup_entry
2474
+ ##
2475
+ # RPC-specific configuration for `list_entries`
2476
+ # @return [::Gapic::Config::Method]
2477
+ #
2478
+ attr_reader :list_entries
2479
+ ##
2480
+ # RPC-specific configuration for `create_tag_template`
2481
+ # @return [::Gapic::Config::Method]
2482
+ #
2483
+ attr_reader :create_tag_template
2484
+ ##
2485
+ # RPC-specific configuration for `get_tag_template`
2486
+ # @return [::Gapic::Config::Method]
2487
+ #
2488
+ attr_reader :get_tag_template
2489
+ ##
2490
+ # RPC-specific configuration for `update_tag_template`
2491
+ # @return [::Gapic::Config::Method]
2492
+ #
2493
+ attr_reader :update_tag_template
2494
+ ##
2495
+ # RPC-specific configuration for `delete_tag_template`
2496
+ # @return [::Gapic::Config::Method]
2497
+ #
2498
+ attr_reader :delete_tag_template
2499
+ ##
2500
+ # RPC-specific configuration for `create_tag_template_field`
2501
+ # @return [::Gapic::Config::Method]
2502
+ #
2503
+ attr_reader :create_tag_template_field
2504
+ ##
2505
+ # RPC-specific configuration for `update_tag_template_field`
2506
+ # @return [::Gapic::Config::Method]
2507
+ #
2508
+ attr_reader :update_tag_template_field
2509
+ ##
2510
+ # RPC-specific configuration for `rename_tag_template_field`
2511
+ # @return [::Gapic::Config::Method]
2512
+ #
2513
+ attr_reader :rename_tag_template_field
2514
+ ##
2515
+ # RPC-specific configuration for `rename_tag_template_field_enum_value`
2516
+ # @return [::Gapic::Config::Method]
2517
+ #
2518
+ attr_reader :rename_tag_template_field_enum_value
2519
+ ##
2520
+ # RPC-specific configuration for `delete_tag_template_field`
2521
+ # @return [::Gapic::Config::Method]
2522
+ #
2523
+ attr_reader :delete_tag_template_field
2524
+ ##
2525
+ # RPC-specific configuration for `create_tag`
2526
+ # @return [::Gapic::Config::Method]
2527
+ #
2528
+ attr_reader :create_tag
2529
+ ##
2530
+ # RPC-specific configuration for `update_tag`
2531
+ # @return [::Gapic::Config::Method]
2532
+ #
2533
+ attr_reader :update_tag
2534
+ ##
2535
+ # RPC-specific configuration for `delete_tag`
2536
+ # @return [::Gapic::Config::Method]
2537
+ #
2538
+ attr_reader :delete_tag
2539
+ ##
2540
+ # RPC-specific configuration for `list_tags`
2541
+ # @return [::Gapic::Config::Method]
2542
+ #
2543
+ attr_reader :list_tags
2544
+ ##
2545
+ # RPC-specific configuration for `set_iam_policy`
2546
+ # @return [::Gapic::Config::Method]
2547
+ #
2548
+ attr_reader :set_iam_policy
2549
+ ##
2550
+ # RPC-specific configuration for `get_iam_policy`
2551
+ # @return [::Gapic::Config::Method]
2552
+ #
2553
+ attr_reader :get_iam_policy
2554
+ ##
2555
+ # RPC-specific configuration for `test_iam_permissions`
2556
+ # @return [::Gapic::Config::Method]
2557
+ #
2558
+ attr_reader :test_iam_permissions
2559
+
2560
+ # @private
2561
+ def initialize parent_rpcs = nil
2562
+ search_catalog_config = parent_rpcs.search_catalog if parent_rpcs.respond_to? :search_catalog
2563
+ @search_catalog = ::Gapic::Config::Method.new search_catalog_config
2564
+ create_entry_group_config = parent_rpcs.create_entry_group if parent_rpcs.respond_to? :create_entry_group
2565
+ @create_entry_group = ::Gapic::Config::Method.new create_entry_group_config
2566
+ update_entry_group_config = parent_rpcs.update_entry_group if parent_rpcs.respond_to? :update_entry_group
2567
+ @update_entry_group = ::Gapic::Config::Method.new update_entry_group_config
2568
+ get_entry_group_config = parent_rpcs.get_entry_group if parent_rpcs.respond_to? :get_entry_group
2569
+ @get_entry_group = ::Gapic::Config::Method.new get_entry_group_config
2570
+ delete_entry_group_config = parent_rpcs.delete_entry_group if parent_rpcs.respond_to? :delete_entry_group
2571
+ @delete_entry_group = ::Gapic::Config::Method.new delete_entry_group_config
2572
+ list_entry_groups_config = parent_rpcs.list_entry_groups if parent_rpcs.respond_to? :list_entry_groups
2573
+ @list_entry_groups = ::Gapic::Config::Method.new list_entry_groups_config
2574
+ create_entry_config = parent_rpcs.create_entry if parent_rpcs.respond_to? :create_entry
2575
+ @create_entry = ::Gapic::Config::Method.new create_entry_config
2576
+ update_entry_config = parent_rpcs.update_entry if parent_rpcs.respond_to? :update_entry
2577
+ @update_entry = ::Gapic::Config::Method.new update_entry_config
2578
+ delete_entry_config = parent_rpcs.delete_entry if parent_rpcs.respond_to? :delete_entry
2579
+ @delete_entry = ::Gapic::Config::Method.new delete_entry_config
2580
+ get_entry_config = parent_rpcs.get_entry if parent_rpcs.respond_to? :get_entry
2581
+ @get_entry = ::Gapic::Config::Method.new get_entry_config
2582
+ lookup_entry_config = parent_rpcs.lookup_entry if parent_rpcs.respond_to? :lookup_entry
2583
+ @lookup_entry = ::Gapic::Config::Method.new lookup_entry_config
2584
+ list_entries_config = parent_rpcs.list_entries if parent_rpcs.respond_to? :list_entries
2585
+ @list_entries = ::Gapic::Config::Method.new list_entries_config
2586
+ create_tag_template_config = parent_rpcs.create_tag_template if parent_rpcs.respond_to? :create_tag_template
2587
+ @create_tag_template = ::Gapic::Config::Method.new create_tag_template_config
2588
+ get_tag_template_config = parent_rpcs.get_tag_template if parent_rpcs.respond_to? :get_tag_template
2589
+ @get_tag_template = ::Gapic::Config::Method.new get_tag_template_config
2590
+ update_tag_template_config = parent_rpcs.update_tag_template if parent_rpcs.respond_to? :update_tag_template
2591
+ @update_tag_template = ::Gapic::Config::Method.new update_tag_template_config
2592
+ delete_tag_template_config = parent_rpcs.delete_tag_template if parent_rpcs.respond_to? :delete_tag_template
2593
+ @delete_tag_template = ::Gapic::Config::Method.new delete_tag_template_config
2594
+ create_tag_template_field_config = parent_rpcs.create_tag_template_field if parent_rpcs.respond_to? :create_tag_template_field
2595
+ @create_tag_template_field = ::Gapic::Config::Method.new create_tag_template_field_config
2596
+ update_tag_template_field_config = parent_rpcs.update_tag_template_field if parent_rpcs.respond_to? :update_tag_template_field
2597
+ @update_tag_template_field = ::Gapic::Config::Method.new update_tag_template_field_config
2598
+ rename_tag_template_field_config = parent_rpcs.rename_tag_template_field if parent_rpcs.respond_to? :rename_tag_template_field
2599
+ @rename_tag_template_field = ::Gapic::Config::Method.new rename_tag_template_field_config
2600
+ rename_tag_template_field_enum_value_config = parent_rpcs.rename_tag_template_field_enum_value if parent_rpcs.respond_to? :rename_tag_template_field_enum_value
2601
+ @rename_tag_template_field_enum_value = ::Gapic::Config::Method.new rename_tag_template_field_enum_value_config
2602
+ delete_tag_template_field_config = parent_rpcs.delete_tag_template_field if parent_rpcs.respond_to? :delete_tag_template_field
2603
+ @delete_tag_template_field = ::Gapic::Config::Method.new delete_tag_template_field_config
2604
+ create_tag_config = parent_rpcs.create_tag if parent_rpcs.respond_to? :create_tag
2605
+ @create_tag = ::Gapic::Config::Method.new create_tag_config
2606
+ update_tag_config = parent_rpcs.update_tag if parent_rpcs.respond_to? :update_tag
2607
+ @update_tag = ::Gapic::Config::Method.new update_tag_config
2608
+ delete_tag_config = parent_rpcs.delete_tag if parent_rpcs.respond_to? :delete_tag
2609
+ @delete_tag = ::Gapic::Config::Method.new delete_tag_config
2610
+ list_tags_config = parent_rpcs.list_tags if parent_rpcs.respond_to? :list_tags
2611
+ @list_tags = ::Gapic::Config::Method.new list_tags_config
2612
+ set_iam_policy_config = parent_rpcs.set_iam_policy if parent_rpcs.respond_to? :set_iam_policy
2613
+ @set_iam_policy = ::Gapic::Config::Method.new set_iam_policy_config
2614
+ get_iam_policy_config = parent_rpcs.get_iam_policy if parent_rpcs.respond_to? :get_iam_policy
2615
+ @get_iam_policy = ::Gapic::Config::Method.new get_iam_policy_config
2616
+ test_iam_permissions_config = parent_rpcs.test_iam_permissions if parent_rpcs.respond_to? :test_iam_permissions
2617
+ @test_iam_permissions = ::Gapic::Config::Method.new test_iam_permissions_config
2618
+
2619
+ yield self if block_given?
2620
+ end
2621
+ end
2622
+ end
2623
+ end
2624
+ end
2625
+ end
2626
+ end
2627
+ end
2628
+ end
2629
+ end