google-cloud-service_directory-v1beta1 0.2.1 → 0.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (28) hide show
  1. checksums.yaml +4 -4
  2. data/AUTHENTICATION.md +6 -6
  3. data/README.md +48 -1
  4. data/lib/google-cloud-service_directory-v1beta1.rb +21 -1
  5. data/lib/google/cloud/service_directory/v1beta1.rb +16 -0
  6. data/lib/google/cloud/service_directory/v1beta1/lookup_service.rb +30 -1
  7. data/lib/google/cloud/service_directory/v1beta1/lookup_service/client.rb +72 -79
  8. data/lib/google/cloud/service_directory/v1beta1/lookup_service/credentials.rb +1 -1
  9. data/lib/google/cloud/service_directory/v1beta1/lookup_service/paths.rb +4 -4
  10. data/lib/google/cloud/service_directory/v1beta1/registration_service.rb +44 -1
  11. data/lib/google/cloud/service_directory/v1beta1/registration_service/client.rb +513 -401
  12. data/lib/google/cloud/service_directory/v1beta1/registration_service/credentials.rb +1 -1
  13. data/lib/google/cloud/service_directory/v1beta1/registration_service/paths.rb +14 -14
  14. data/lib/google/cloud/service_directory/v1beta1/version.rb +1 -1
  15. data/proto_docs/google/api/resource.rb +12 -12
  16. data/proto_docs/google/cloud/servicedirectory/v1beta1/endpoint.rb +11 -11
  17. data/proto_docs/google/cloud/servicedirectory/v1beta1/lookup_service.rb +10 -10
  18. data/proto_docs/google/cloud/servicedirectory/v1beta1/namespace.rb +9 -9
  19. data/proto_docs/google/cloud/servicedirectory/v1beta1/registration_service.rb +96 -96
  20. data/proto_docs/google/cloud/servicedirectory/v1beta1/service.rb +10 -10
  21. data/proto_docs/google/iam/v1/iam_policy.rb +21 -20
  22. data/proto_docs/google/iam/v1/options.rb +40 -0
  23. data/proto_docs/google/iam/v1/policy.rb +126 -34
  24. data/proto_docs/google/protobuf/empty.rb +2 -2
  25. data/proto_docs/google/protobuf/field_mask.rb +3 -3
  26. data/proto_docs/google/type/expr.rb +52 -0
  27. metadata +45 -10
  28. data/lib/google/cloud/common_resources_pb.rb +0 -15
@@ -24,7 +24,7 @@ module Google
24
24
  module V1beta1
25
25
  module LookupService
26
26
  # Credentials for the LookupService API.
27
- class Credentials < Google::Auth::Credentials
27
+ class Credentials < ::Google::Auth::Credentials
28
28
  self.scope = [
29
29
  "https://www.googleapis.com/auth/cloud-platform"
30
30
  ]
@@ -36,11 +36,11 @@ module Google
36
36
  # @param namespace [String]
37
37
  # @param service [String]
38
38
  #
39
- # @return [String]
39
+ # @return [::String]
40
40
  def service_path project:, location:, namespace:, service:
41
- raise ArgumentError, "project cannot contain /" if project.to_s.include? "/"
42
- raise ArgumentError, "location cannot contain /" if location.to_s.include? "/"
43
- raise ArgumentError, "namespace cannot contain /" if namespace.to_s.include? "/"
41
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
42
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
43
+ raise ::ArgumentError, "namespace cannot contain /" if namespace.to_s.include? "/"
44
44
 
45
45
  "projects/#{project}/locations/#{location}/namespaces/#{namespace}/services/#{service}"
46
46
  end
@@ -16,5 +16,48 @@
16
16
 
17
17
  # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
18
 
19
- require "google/cloud/service_directory/v1beta1/registration_service/client"
19
+ require "gapic/common"
20
+ require "gapic/config"
21
+ require "gapic/config/method"
22
+
23
+ require "google/cloud/service_directory/v1beta1/version"
24
+
20
25
  require "google/cloud/service_directory/v1beta1/registration_service/credentials"
26
+ require "google/cloud/service_directory/v1beta1/registration_service/paths"
27
+ require "google/cloud/service_directory/v1beta1/registration_service/client"
28
+
29
+ module Google
30
+ module Cloud
31
+ module ServiceDirectory
32
+ module V1beta1
33
+ ##
34
+ # Service Directory API for registering services. It defines the following
35
+ # resource model:
36
+ #
37
+ # - The API has a collection of
38
+ # {::Google::Cloud::ServiceDirectory::V1beta1::Namespace Namespace}
39
+ # resources, named `projects/*/locations/*/namespaces/*`.
40
+ #
41
+ # - Each Namespace has a collection of
42
+ # {::Google::Cloud::ServiceDirectory::V1beta1::Service Service} resources, named
43
+ # `projects/*/locations/*/namespaces/*/services/*`.
44
+ #
45
+ # - Each Service has a collection of
46
+ # {::Google::Cloud::ServiceDirectory::V1beta1::Endpoint Endpoint}
47
+ # resources, named
48
+ # `projects/*/locations/*/namespaces/*/services/*/endpoints/*`.
49
+ #
50
+ # To load this service and instantiate a client:
51
+ #
52
+ # require "google/cloud/service_directory/v1beta1/registration_service"
53
+ # client = ::Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.new
54
+ #
55
+ module RegistrationService
56
+ end
57
+ end
58
+ end
59
+ end
60
+ end
61
+
62
+ helper_path = ::File.join __dir__, "registration_service", "helpers.rb"
63
+ require "google/cloud/service_directory/v1beta1/registration_service/helpers" if ::File.file? helper_path
@@ -16,15 +16,8 @@
16
16
 
17
17
  # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
18
 
19
- require "gapic/common"
20
- require "gapic/config"
21
- require "gapic/config/method"
22
-
23
19
  require "google/cloud/errors"
24
- require "google/cloud/service_directory/v1beta1/version"
25
20
  require "google/cloud/servicedirectory/v1beta1/registration_service_pb"
26
- require "google/cloud/service_directory/v1beta1/registration_service/credentials"
27
- require "google/cloud/service_directory/v1beta1/registration_service/paths"
28
21
 
29
22
  module Google
30
23
  module Cloud
@@ -38,15 +31,15 @@ module Google
38
31
  # resource model:
39
32
  #
40
33
  # - The API has a collection of
41
- # {Google::Cloud::ServiceDirectory::V1beta1::Namespace Namespace}
34
+ # {::Google::Cloud::ServiceDirectory::V1beta1::Namespace Namespace}
42
35
  # resources, named `projects/*/locations/*/namespaces/*`.
43
36
  #
44
37
  # - Each Namespace has a collection of
45
- # {Google::Cloud::ServiceDirectory::V1beta1::Service Service} resources, named
38
+ # {::Google::Cloud::ServiceDirectory::V1beta1::Service Service} resources, named
46
39
  # `projects/*/locations/*/namespaces/*/services/*`.
47
40
  #
48
41
  # - Each Service has a collection of
49
- # {Google::Cloud::ServiceDirectory::V1beta1::Endpoint Endpoint}
42
+ # {::Google::Cloud::ServiceDirectory::V1beta1::Endpoint Endpoint}
50
43
  # resources, named
51
44
  # `projects/*/locations/*/namespaces/*/services/*/endpoints/*`.
52
45
  #
@@ -59,15 +52,15 @@ module Google
59
52
  ##
60
53
  # Configure the RegistrationService Client class.
61
54
  #
62
- # See {Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client::Configuration}
55
+ # See {::Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client::Configuration}
63
56
  # for a description of the configuration fields.
64
57
  #
65
58
  # ## Example
66
59
  #
67
60
  # To modify the configuration for all RegistrationService clients:
68
61
  #
69
- # Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.configure do |config|
70
- # config.timeout = 10_000
62
+ # ::Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.configure do |config|
63
+ # config.timeout = 10.0
71
64
  # end
72
65
  #
73
66
  # @yield [config] Configure the Client client.
@@ -107,7 +100,7 @@ module Google
107
100
  # but structural changes (adding new fields, etc.) are not allowed. Structural changes
108
101
  # should be made on {Client.configure}.
109
102
  #
110
- # See {Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client::Configuration}
103
+ # See {::Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client::Configuration}
111
104
  # for a description of the configuration fields.
112
105
  #
113
106
  # @yield [config] Configure the Client client.
@@ -128,13 +121,13 @@ module Google
128
121
  # To create a new RegistrationService client with the default
129
122
  # configuration:
130
123
  #
131
- # client = Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.new
124
+ # client = ::Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.new
132
125
  #
133
126
  # To create a new RegistrationService client with a custom
134
127
  # configuration:
135
128
  #
136
- # client = Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.new do |config|
137
- # config.timeout = 10_000
129
+ # client = ::Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.new do |config|
130
+ # config.timeout = 10.0
138
131
  # end
139
132
  #
140
133
  # @yield [config] Configure the RegistrationService client.
@@ -159,10 +152,11 @@ module Google
159
152
  if credentials.is_a?(String) || credentials.is_a?(Hash)
160
153
  credentials = Credentials.new credentials, scope: @config.scope
161
154
  end
162
- @quota_project_id = credentials.respond_to?(:quota_project_id) ? credentials.quota_project_id : nil
155
+ @quota_project_id = @config.quota_project
156
+ @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
163
157
 
164
- @registration_service_stub = Gapic::ServiceStub.new(
165
- Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Stub,
158
+ @registration_service_stub = ::Gapic::ServiceStub.new(
159
+ ::Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Stub,
166
160
  credentials: credentials,
167
161
  endpoint: @config.endpoint,
168
162
  channel_args: @config.channel_args,
@@ -176,16 +170,24 @@ module Google
176
170
  # Creates a namespace, and returns the new Namespace.
177
171
  #
178
172
  # @overload create_namespace(request, options = nil)
179
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::CreateNamespaceRequest | Hash]
180
- # Creates a namespace, and returns the new Namespace.
181
- # @param options [Gapic::CallOptions, Hash]
173
+ # Pass arguments to `create_namespace` via a request object, either of type
174
+ # {::Google::Cloud::ServiceDirectory::V1beta1::CreateNamespaceRequest} or an equivalent Hash.
175
+ #
176
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::CreateNamespaceRequest, ::Hash]
177
+ # A request object representing the call parameters. Required. To specify no
178
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
179
+ # @param options [::Gapic::CallOptions, ::Hash]
182
180
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
183
181
  #
184
182
  # @overload create_namespace(parent: nil, namespace_id: nil, namespace: nil)
185
- # @param parent [String]
183
+ # Pass arguments to `create_namespace` via keyword arguments. Note that at
184
+ # least one keyword argument is required. To specify no parameters, or to keep all
185
+ # the default parameter values, pass an empty Hash as a request object (see above).
186
+ #
187
+ # @param parent [::String]
186
188
  # Required. The resource name of the project and location the namespace
187
189
  # will be created in.
188
- # @param namespace_id [String]
190
+ # @param namespace_id [::String]
189
191
  # Required. The Resource ID must be 1-63 characters long, and comply with
190
192
  # <a href="https://www.ietf.org/rfc/rfc1035.txt" target="_blank">RFC1035</a>.
191
193
  # Specifically, the name must be 1-63 characters long and match the regular
@@ -193,31 +195,30 @@ module Google
193
195
  # character must be a lowercase letter, and all following characters must
194
196
  # be a dash, lowercase letter, or digit, except the last character, which
195
197
  # cannot be a dash.
196
- # @param namespace [Google::Cloud::ServiceDirectory::V1beta1::Namespace | Hash]
198
+ # @param namespace [::Google::Cloud::ServiceDirectory::V1beta1::Namespace, ::Hash]
197
199
  # Required. A namespace with initial fields set.
198
200
  #
199
- #
200
201
  # @yield [response, operation] Access the result along with the RPC operation
201
- # @yieldparam response [Google::Cloud::ServiceDirectory::V1beta1::Namespace]
202
- # @yieldparam operation [GRPC::ActiveCall::Operation]
202
+ # @yieldparam response [::Google::Cloud::ServiceDirectory::V1beta1::Namespace]
203
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
203
204
  #
204
- # @return [Google::Cloud::ServiceDirectory::V1beta1::Namespace]
205
+ # @return [::Google::Cloud::ServiceDirectory::V1beta1::Namespace]
205
206
  #
206
- # @raise [Google::Cloud::Error] if the RPC is aborted.
207
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
207
208
  #
208
209
  def create_namespace request, options = nil
209
- raise ArgumentError, "request must be provided" if request.nil?
210
+ raise ::ArgumentError, "request must be provided" if request.nil?
210
211
 
211
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::CreateNamespaceRequest
212
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::CreateNamespaceRequest
212
213
 
213
214
  # Converts hash and nil to an options object
214
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
215
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
215
216
 
216
217
  # Customize the options with defaults
217
218
  metadata = @config.rpcs.create_namespace.metadata.to_h
218
219
 
219
220
  # Set x-goog-api-client and x-goog-user-project headers
220
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
221
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
221
222
  lib_name: @config.lib_name, lib_version: @config.lib_version,
222
223
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
223
224
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -238,28 +239,36 @@ module Google
238
239
  yield response, operation if block_given?
239
240
  return response
240
241
  end
241
- rescue GRPC::BadStatus => e
242
- raise Google::Cloud::Error.from_error(e)
242
+ rescue ::GRPC::BadStatus => e
243
+ raise ::Google::Cloud::Error.from_error(e)
243
244
  end
244
245
 
245
246
  ##
246
247
  # Lists all namespaces.
247
248
  #
248
249
  # @overload list_namespaces(request, options = nil)
249
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::ListNamespacesRequest | Hash]
250
- # Lists all namespaces.
251
- # @param options [Gapic::CallOptions, Hash]
250
+ # Pass arguments to `list_namespaces` via a request object, either of type
251
+ # {::Google::Cloud::ServiceDirectory::V1beta1::ListNamespacesRequest} or an equivalent Hash.
252
+ #
253
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::ListNamespacesRequest, ::Hash]
254
+ # A request object representing the call parameters. Required. To specify no
255
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
256
+ # @param options [::Gapic::CallOptions, ::Hash]
252
257
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
253
258
  #
254
259
  # @overload list_namespaces(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
255
- # @param parent [String]
260
+ # Pass arguments to `list_namespaces` via keyword arguments. Note that at
261
+ # least one keyword argument is required. To specify no parameters, or to keep all
262
+ # the default parameter values, pass an empty Hash as a request object (see above).
263
+ #
264
+ # @param parent [::String]
256
265
  # Required. The resource name of the project and location whose namespaces we'd like to
257
266
  # list.
258
- # @param page_size [Integer]
267
+ # @param page_size [::Integer]
259
268
  # Optional. The maximum number of items to return.
260
- # @param page_token [String]
269
+ # @param page_token [::String]
261
270
  # Optional. The next_page_token value returned from a previous List request, if any.
262
- # @param filter [String]
271
+ # @param filter [::String]
263
272
  # Optional. The filter to list result by.
264
273
  #
265
274
  # General filter string syntax:
@@ -283,7 +292,7 @@ module Google
283
292
  # * "doesnotexist.foo=bar" returns an empty list. Note that Namespace doesn't
284
293
  # have a field called "doesnotexist". Since the filter does not match any
285
294
  # Namespaces, it returns no results.
286
- # @param order_by [String]
295
+ # @param order_by [::String]
287
296
  # Optional. The order to list result by.
288
297
  #
289
298
  # General order by string syntax:
@@ -294,28 +303,27 @@ module Google
294
303
  # Note that an empty order_by string result in default order, which is order
295
304
  # by name in ascending order.
296
305
  #
297
- #
298
306
  # @yield [response, operation] Access the result along with the RPC operation
299
- # @yieldparam response [Gapic::PagedEnumerable<Google::Cloud::ServiceDirectory::V1beta1::Namespace>]
300
- # @yieldparam operation [GRPC::ActiveCall::Operation]
307
+ # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::ServiceDirectory::V1beta1::Namespace>]
308
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
301
309
  #
302
- # @return [Gapic::PagedEnumerable<Google::Cloud::ServiceDirectory::V1beta1::Namespace>]
310
+ # @return [::Gapic::PagedEnumerable<::Google::Cloud::ServiceDirectory::V1beta1::Namespace>]
303
311
  #
304
- # @raise [Google::Cloud::Error] if the RPC is aborted.
312
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
305
313
  #
306
314
  def list_namespaces request, options = nil
307
- raise ArgumentError, "request must be provided" if request.nil?
315
+ raise ::ArgumentError, "request must be provided" if request.nil?
308
316
 
309
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::ListNamespacesRequest
317
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::ListNamespacesRequest
310
318
 
311
319
  # Converts hash and nil to an options object
312
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
320
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
313
321
 
314
322
  # Customize the options with defaults
315
323
  metadata = @config.rpcs.list_namespaces.metadata.to_h
316
324
 
317
325
  # Set x-goog-api-client and x-goog-user-project headers
318
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
326
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
319
327
  lib_name: @config.lib_name, lib_version: @config.lib_version,
320
328
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
321
329
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -333,49 +341,56 @@ module Google
333
341
  retry_policy: @config.retry_policy
334
342
 
335
343
  @registration_service_stub.call_rpc :list_namespaces, request, options: options do |response, operation|
336
- response = Gapic::PagedEnumerable.new @registration_service_stub, :list_namespaces, request, response, operation, options
344
+ response = ::Gapic::PagedEnumerable.new @registration_service_stub, :list_namespaces, request, response, operation, options
337
345
  yield response, operation if block_given?
338
346
  return response
339
347
  end
340
- rescue GRPC::BadStatus => e
341
- raise Google::Cloud::Error.from_error(e)
348
+ rescue ::GRPC::BadStatus => e
349
+ raise ::Google::Cloud::Error.from_error(e)
342
350
  end
343
351
 
344
352
  ##
345
353
  # Gets a namespace.
346
354
  #
347
355
  # @overload get_namespace(request, options = nil)
348
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::GetNamespaceRequest | Hash]
349
- # Gets a namespace.
350
- # @param options [Gapic::CallOptions, Hash]
356
+ # Pass arguments to `get_namespace` via a request object, either of type
357
+ # {::Google::Cloud::ServiceDirectory::V1beta1::GetNamespaceRequest} or an equivalent Hash.
358
+ #
359
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::GetNamespaceRequest, ::Hash]
360
+ # A request object representing the call parameters. Required. To specify no
361
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
362
+ # @param options [::Gapic::CallOptions, ::Hash]
351
363
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
352
364
  #
353
365
  # @overload get_namespace(name: nil)
354
- # @param name [String]
355
- # Required. The name of the namespace to retrieve.
366
+ # Pass arguments to `get_namespace` via keyword arguments. Note that at
367
+ # least one keyword argument is required. To specify no parameters, or to keep all
368
+ # the default parameter values, pass an empty Hash as a request object (see above).
356
369
  #
370
+ # @param name [::String]
371
+ # Required. The name of the namespace to retrieve.
357
372
  #
358
373
  # @yield [response, operation] Access the result along with the RPC operation
359
- # @yieldparam response [Google::Cloud::ServiceDirectory::V1beta1::Namespace]
360
- # @yieldparam operation [GRPC::ActiveCall::Operation]
374
+ # @yieldparam response [::Google::Cloud::ServiceDirectory::V1beta1::Namespace]
375
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
361
376
  #
362
- # @return [Google::Cloud::ServiceDirectory::V1beta1::Namespace]
377
+ # @return [::Google::Cloud::ServiceDirectory::V1beta1::Namespace]
363
378
  #
364
- # @raise [Google::Cloud::Error] if the RPC is aborted.
379
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
365
380
  #
366
381
  def get_namespace request, options = nil
367
- raise ArgumentError, "request must be provided" if request.nil?
382
+ raise ::ArgumentError, "request must be provided" if request.nil?
368
383
 
369
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::GetNamespaceRequest
384
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::GetNamespaceRequest
370
385
 
371
386
  # Converts hash and nil to an options object
372
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
387
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
373
388
 
374
389
  # Customize the options with defaults
375
390
  metadata = @config.rpcs.get_namespace.metadata.to_h
376
391
 
377
392
  # Set x-goog-api-client and x-goog-user-project headers
378
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
393
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
379
394
  lib_name: @config.lib_name, lib_version: @config.lib_version,
380
395
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
381
396
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -396,47 +411,54 @@ module Google
396
411
  yield response, operation if block_given?
397
412
  return response
398
413
  end
399
- rescue GRPC::BadStatus => e
400
- raise Google::Cloud::Error.from_error(e)
414
+ rescue ::GRPC::BadStatus => e
415
+ raise ::Google::Cloud::Error.from_error(e)
401
416
  end
402
417
 
403
418
  ##
404
419
  # Updates a namespace.
405
420
  #
406
421
  # @overload update_namespace(request, options = nil)
407
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::UpdateNamespaceRequest | Hash]
408
- # Updates a namespace.
409
- # @param options [Gapic::CallOptions, Hash]
422
+ # Pass arguments to `update_namespace` via a request object, either of type
423
+ # {::Google::Cloud::ServiceDirectory::V1beta1::UpdateNamespaceRequest} or an equivalent Hash.
424
+ #
425
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::UpdateNamespaceRequest, ::Hash]
426
+ # A request object representing the call parameters. Required. To specify no
427
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
428
+ # @param options [::Gapic::CallOptions, ::Hash]
410
429
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
411
430
  #
412
431
  # @overload update_namespace(namespace: nil, update_mask: nil)
413
- # @param namespace [Google::Cloud::ServiceDirectory::V1beta1::Namespace | Hash]
432
+ # Pass arguments to `update_namespace` via keyword arguments. Note that at
433
+ # least one keyword argument is required. To specify no parameters, or to keep all
434
+ # the default parameter values, pass an empty Hash as a request object (see above).
435
+ #
436
+ # @param namespace [::Google::Cloud::ServiceDirectory::V1beta1::Namespace, ::Hash]
414
437
  # Required. The updated namespace.
415
- # @param update_mask [Google::Protobuf::FieldMask | Hash]
438
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
416
439
  # Required. List of fields to be updated in this request.
417
440
  #
418
- #
419
441
  # @yield [response, operation] Access the result along with the RPC operation
420
- # @yieldparam response [Google::Cloud::ServiceDirectory::V1beta1::Namespace]
421
- # @yieldparam operation [GRPC::ActiveCall::Operation]
442
+ # @yieldparam response [::Google::Cloud::ServiceDirectory::V1beta1::Namespace]
443
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
422
444
  #
423
- # @return [Google::Cloud::ServiceDirectory::V1beta1::Namespace]
445
+ # @return [::Google::Cloud::ServiceDirectory::V1beta1::Namespace]
424
446
  #
425
- # @raise [Google::Cloud::Error] if the RPC is aborted.
447
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
426
448
  #
427
449
  def update_namespace request, options = nil
428
- raise ArgumentError, "request must be provided" if request.nil?
450
+ raise ::ArgumentError, "request must be provided" if request.nil?
429
451
 
430
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::UpdateNamespaceRequest
452
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::UpdateNamespaceRequest
431
453
 
432
454
  # Converts hash and nil to an options object
433
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
455
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
434
456
 
435
457
  # Customize the options with defaults
436
458
  metadata = @config.rpcs.update_namespace.metadata.to_h
437
459
 
438
460
  # Set x-goog-api-client and x-goog-user-project headers
439
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
461
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
440
462
  lib_name: @config.lib_name, lib_version: @config.lib_version,
441
463
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
442
464
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -457,8 +479,8 @@ module Google
457
479
  yield response, operation if block_given?
458
480
  return response
459
481
  end
460
- rescue GRPC::BadStatus => e
461
- raise Google::Cloud::Error.from_error(e)
482
+ rescue ::GRPC::BadStatus => e
483
+ raise ::Google::Cloud::Error.from_error(e)
462
484
  end
463
485
 
464
486
  ##
@@ -466,38 +488,44 @@ module Google
466
488
  # the namespace.
467
489
  #
468
490
  # @overload delete_namespace(request, options = nil)
469
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::DeleteNamespaceRequest | Hash]
470
- # Deletes a namespace. This also deletes all services and endpoints in
471
- # the namespace.
472
- # @param options [Gapic::CallOptions, Hash]
491
+ # Pass arguments to `delete_namespace` via a request object, either of type
492
+ # {::Google::Cloud::ServiceDirectory::V1beta1::DeleteNamespaceRequest} or an equivalent Hash.
493
+ #
494
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::DeleteNamespaceRequest, ::Hash]
495
+ # A request object representing the call parameters. Required. To specify no
496
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
497
+ # @param options [::Gapic::CallOptions, ::Hash]
473
498
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
474
499
  #
475
500
  # @overload delete_namespace(name: nil)
476
- # @param name [String]
477
- # Required. The name of the namespace to delete.
501
+ # Pass arguments to `delete_namespace` via keyword arguments. Note that at
502
+ # least one keyword argument is required. To specify no parameters, or to keep all
503
+ # the default parameter values, pass an empty Hash as a request object (see above).
478
504
  #
505
+ # @param name [::String]
506
+ # Required. The name of the namespace to delete.
479
507
  #
480
508
  # @yield [response, operation] Access the result along with the RPC operation
481
- # @yieldparam response [Google::Protobuf::Empty]
482
- # @yieldparam operation [GRPC::ActiveCall::Operation]
509
+ # @yieldparam response [::Google::Protobuf::Empty]
510
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
483
511
  #
484
- # @return [Google::Protobuf::Empty]
512
+ # @return [::Google::Protobuf::Empty]
485
513
  #
486
- # @raise [Google::Cloud::Error] if the RPC is aborted.
514
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
487
515
  #
488
516
  def delete_namespace request, options = nil
489
- raise ArgumentError, "request must be provided" if request.nil?
517
+ raise ::ArgumentError, "request must be provided" if request.nil?
490
518
 
491
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::DeleteNamespaceRequest
519
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::DeleteNamespaceRequest
492
520
 
493
521
  # Converts hash and nil to an options object
494
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
522
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
495
523
 
496
524
  # Customize the options with defaults
497
525
  metadata = @config.rpcs.delete_namespace.metadata.to_h
498
526
 
499
527
  # Set x-goog-api-client and x-goog-user-project headers
500
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
528
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
501
529
  lib_name: @config.lib_name, lib_version: @config.lib_version,
502
530
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
503
531
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -518,23 +546,31 @@ module Google
518
546
  yield response, operation if block_given?
519
547
  return response
520
548
  end
521
- rescue GRPC::BadStatus => e
522
- raise Google::Cloud::Error.from_error(e)
549
+ rescue ::GRPC::BadStatus => e
550
+ raise ::Google::Cloud::Error.from_error(e)
523
551
  end
524
552
 
525
553
  ##
526
554
  # Creates a service, and returns the new Service.
527
555
  #
528
556
  # @overload create_service(request, options = nil)
529
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::CreateServiceRequest | Hash]
530
- # Creates a service, and returns the new Service.
531
- # @param options [Gapic::CallOptions, Hash]
557
+ # Pass arguments to `create_service` via a request object, either of type
558
+ # {::Google::Cloud::ServiceDirectory::V1beta1::CreateServiceRequest} or an equivalent Hash.
559
+ #
560
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::CreateServiceRequest, ::Hash]
561
+ # A request object representing the call parameters. Required. To specify no
562
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
563
+ # @param options [::Gapic::CallOptions, ::Hash]
532
564
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
533
565
  #
534
566
  # @overload create_service(parent: nil, service_id: nil, service: nil)
535
- # @param parent [String]
567
+ # Pass arguments to `create_service` via keyword arguments. Note that at
568
+ # least one keyword argument is required. To specify no parameters, or to keep all
569
+ # the default parameter values, pass an empty Hash as a request object (see above).
570
+ #
571
+ # @param parent [::String]
536
572
  # Required. The resource name of the namespace this service will belong to.
537
- # @param service_id [String]
573
+ # @param service_id [::String]
538
574
  # Required. The Resource ID must be 1-63 characters long, and comply with
539
575
  # <a href="https://www.ietf.org/rfc/rfc1035.txt" target="_blank">RFC1035</a>.
540
576
  # Specifically, the name must be 1-63 characters long and match the regular
@@ -542,31 +578,30 @@ module Google
542
578
  # character must be a lowercase letter, and all following characters must
543
579
  # be a dash, lowercase letter, or digit, except the last character, which
544
580
  # cannot be a dash.
545
- # @param service [Google::Cloud::ServiceDirectory::V1beta1::Service | Hash]
581
+ # @param service [::Google::Cloud::ServiceDirectory::V1beta1::Service, ::Hash]
546
582
  # Required. A service with initial fields set.
547
583
  #
548
- #
549
584
  # @yield [response, operation] Access the result along with the RPC operation
550
- # @yieldparam response [Google::Cloud::ServiceDirectory::V1beta1::Service]
551
- # @yieldparam operation [GRPC::ActiveCall::Operation]
585
+ # @yieldparam response [::Google::Cloud::ServiceDirectory::V1beta1::Service]
586
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
552
587
  #
553
- # @return [Google::Cloud::ServiceDirectory::V1beta1::Service]
588
+ # @return [::Google::Cloud::ServiceDirectory::V1beta1::Service]
554
589
  #
555
- # @raise [Google::Cloud::Error] if the RPC is aborted.
590
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
556
591
  #
557
592
  def create_service request, options = nil
558
- raise ArgumentError, "request must be provided" if request.nil?
593
+ raise ::ArgumentError, "request must be provided" if request.nil?
559
594
 
560
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::CreateServiceRequest
595
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::CreateServiceRequest
561
596
 
562
597
  # Converts hash and nil to an options object
563
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
598
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
564
599
 
565
600
  # Customize the options with defaults
566
601
  metadata = @config.rpcs.create_service.metadata.to_h
567
602
 
568
603
  # Set x-goog-api-client and x-goog-user-project headers
569
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
604
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
570
605
  lib_name: @config.lib_name, lib_version: @config.lib_version,
571
606
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
572
607
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -587,29 +622,37 @@ module Google
587
622
  yield response, operation if block_given?
588
623
  return response
589
624
  end
590
- rescue GRPC::BadStatus => e
591
- raise Google::Cloud::Error.from_error(e)
625
+ rescue ::GRPC::BadStatus => e
626
+ raise ::Google::Cloud::Error.from_error(e)
592
627
  end
593
628
 
594
629
  ##
595
630
  # Lists all services belonging to a namespace.
596
631
  #
597
632
  # @overload list_services(request, options = nil)
598
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::ListServicesRequest | Hash]
599
- # Lists all services belonging to a namespace.
600
- # @param options [Gapic::CallOptions, Hash]
633
+ # Pass arguments to `list_services` via a request object, either of type
634
+ # {::Google::Cloud::ServiceDirectory::V1beta1::ListServicesRequest} or an equivalent Hash.
635
+ #
636
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::ListServicesRequest, ::Hash]
637
+ # A request object representing the call parameters. Required. To specify no
638
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
639
+ # @param options [::Gapic::CallOptions, ::Hash]
601
640
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
602
641
  #
603
642
  # @overload list_services(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
604
- # @param parent [String]
643
+ # Pass arguments to `list_services` via keyword arguments. Note that at
644
+ # least one keyword argument is required. To specify no parameters, or to keep all
645
+ # the default parameter values, pass an empty Hash as a request object (see above).
646
+ #
647
+ # @param parent [::String]
605
648
  # Required. The resource name of the namespace whose services we'd
606
649
  # like to list.
607
- # @param page_size [Integer]
650
+ # @param page_size [::Integer]
608
651
  # Optional. The maximum number of items to return.
609
- # @param page_token [String]
652
+ # @param page_token [::String]
610
653
  # Optional. The next_page_token value returned from a previous List request,
611
654
  # if any.
612
- # @param filter [String]
655
+ # @param filter [::String]
613
656
  # Optional. The filter to list result by.
614
657
  #
615
658
  # General filter string syntax:
@@ -633,31 +676,30 @@ module Google
633
676
  # * "doesnotexist.foo=bar" returns an empty list. Note that Service doesn't
634
677
  # have a field called "doesnotexist". Since the filter does not match any
635
678
  # Services, it returns no results.
636
- # @param order_by [String]
679
+ # @param order_by [::String]
637
680
  # Optional. The order to list result by.
638
681
  #
639
- #
640
682
  # @yield [response, operation] Access the result along with the RPC operation
641
- # @yieldparam response [Gapic::PagedEnumerable<Google::Cloud::ServiceDirectory::V1beta1::Service>]
642
- # @yieldparam operation [GRPC::ActiveCall::Operation]
683
+ # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::ServiceDirectory::V1beta1::Service>]
684
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
643
685
  #
644
- # @return [Gapic::PagedEnumerable<Google::Cloud::ServiceDirectory::V1beta1::Service>]
686
+ # @return [::Gapic::PagedEnumerable<::Google::Cloud::ServiceDirectory::V1beta1::Service>]
645
687
  #
646
- # @raise [Google::Cloud::Error] if the RPC is aborted.
688
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
647
689
  #
648
690
  def list_services request, options = nil
649
- raise ArgumentError, "request must be provided" if request.nil?
691
+ raise ::ArgumentError, "request must be provided" if request.nil?
650
692
 
651
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::ListServicesRequest
693
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::ListServicesRequest
652
694
 
653
695
  # Converts hash and nil to an options object
654
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
696
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
655
697
 
656
698
  # Customize the options with defaults
657
699
  metadata = @config.rpcs.list_services.metadata.to_h
658
700
 
659
701
  # Set x-goog-api-client and x-goog-user-project headers
660
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
702
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
661
703
  lib_name: @config.lib_name, lib_version: @config.lib_version,
662
704
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
663
705
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -675,49 +717,56 @@ module Google
675
717
  retry_policy: @config.retry_policy
676
718
 
677
719
  @registration_service_stub.call_rpc :list_services, request, options: options do |response, operation|
678
- response = Gapic::PagedEnumerable.new @registration_service_stub, :list_services, request, response, operation, options
720
+ response = ::Gapic::PagedEnumerable.new @registration_service_stub, :list_services, request, response, operation, options
679
721
  yield response, operation if block_given?
680
722
  return response
681
723
  end
682
- rescue GRPC::BadStatus => e
683
- raise Google::Cloud::Error.from_error(e)
724
+ rescue ::GRPC::BadStatus => e
725
+ raise ::Google::Cloud::Error.from_error(e)
684
726
  end
685
727
 
686
728
  ##
687
729
  # Gets a service.
688
730
  #
689
731
  # @overload get_service(request, options = nil)
690
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::GetServiceRequest | Hash]
691
- # Gets a service.
692
- # @param options [Gapic::CallOptions, Hash]
732
+ # Pass arguments to `get_service` via a request object, either of type
733
+ # {::Google::Cloud::ServiceDirectory::V1beta1::GetServiceRequest} or an equivalent Hash.
734
+ #
735
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::GetServiceRequest, ::Hash]
736
+ # A request object representing the call parameters. Required. To specify no
737
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
738
+ # @param options [::Gapic::CallOptions, ::Hash]
693
739
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
694
740
  #
695
741
  # @overload get_service(name: nil)
696
- # @param name [String]
697
- # Required. The name of the service to get.
742
+ # Pass arguments to `get_service` via keyword arguments. Note that at
743
+ # least one keyword argument is required. To specify no parameters, or to keep all
744
+ # the default parameter values, pass an empty Hash as a request object (see above).
698
745
  #
746
+ # @param name [::String]
747
+ # Required. The name of the service to get.
699
748
  #
700
749
  # @yield [response, operation] Access the result along with the RPC operation
701
- # @yieldparam response [Google::Cloud::ServiceDirectory::V1beta1::Service]
702
- # @yieldparam operation [GRPC::ActiveCall::Operation]
750
+ # @yieldparam response [::Google::Cloud::ServiceDirectory::V1beta1::Service]
751
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
703
752
  #
704
- # @return [Google::Cloud::ServiceDirectory::V1beta1::Service]
753
+ # @return [::Google::Cloud::ServiceDirectory::V1beta1::Service]
705
754
  #
706
- # @raise [Google::Cloud::Error] if the RPC is aborted.
755
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
707
756
  #
708
757
  def get_service request, options = nil
709
- raise ArgumentError, "request must be provided" if request.nil?
758
+ raise ::ArgumentError, "request must be provided" if request.nil?
710
759
 
711
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::GetServiceRequest
760
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::GetServiceRequest
712
761
 
713
762
  # Converts hash and nil to an options object
714
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
763
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
715
764
 
716
765
  # Customize the options with defaults
717
766
  metadata = @config.rpcs.get_service.metadata.to_h
718
767
 
719
768
  # Set x-goog-api-client and x-goog-user-project headers
720
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
769
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
721
770
  lib_name: @config.lib_name, lib_version: @config.lib_version,
722
771
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
723
772
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -738,47 +787,54 @@ module Google
738
787
  yield response, operation if block_given?
739
788
  return response
740
789
  end
741
- rescue GRPC::BadStatus => e
742
- raise Google::Cloud::Error.from_error(e)
790
+ rescue ::GRPC::BadStatus => e
791
+ raise ::Google::Cloud::Error.from_error(e)
743
792
  end
744
793
 
745
794
  ##
746
795
  # Updates a service.
747
796
  #
748
797
  # @overload update_service(request, options = nil)
749
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::UpdateServiceRequest | Hash]
750
- # Updates a service.
751
- # @param options [Gapic::CallOptions, Hash]
798
+ # Pass arguments to `update_service` via a request object, either of type
799
+ # {::Google::Cloud::ServiceDirectory::V1beta1::UpdateServiceRequest} or an equivalent Hash.
800
+ #
801
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::UpdateServiceRequest, ::Hash]
802
+ # A request object representing the call parameters. Required. To specify no
803
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
804
+ # @param options [::Gapic::CallOptions, ::Hash]
752
805
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
753
806
  #
754
807
  # @overload update_service(service: nil, update_mask: nil)
755
- # @param service [Google::Cloud::ServiceDirectory::V1beta1::Service | Hash]
808
+ # Pass arguments to `update_service` via keyword arguments. Note that at
809
+ # least one keyword argument is required. To specify no parameters, or to keep all
810
+ # the default parameter values, pass an empty Hash as a request object (see above).
811
+ #
812
+ # @param service [::Google::Cloud::ServiceDirectory::V1beta1::Service, ::Hash]
756
813
  # Required. The updated service.
757
- # @param update_mask [Google::Protobuf::FieldMask | Hash]
814
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
758
815
  # Required. List of fields to be updated in this request.
759
816
  #
760
- #
761
817
  # @yield [response, operation] Access the result along with the RPC operation
762
- # @yieldparam response [Google::Cloud::ServiceDirectory::V1beta1::Service]
763
- # @yieldparam operation [GRPC::ActiveCall::Operation]
818
+ # @yieldparam response [::Google::Cloud::ServiceDirectory::V1beta1::Service]
819
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
764
820
  #
765
- # @return [Google::Cloud::ServiceDirectory::V1beta1::Service]
821
+ # @return [::Google::Cloud::ServiceDirectory::V1beta1::Service]
766
822
  #
767
- # @raise [Google::Cloud::Error] if the RPC is aborted.
823
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
768
824
  #
769
825
  def update_service request, options = nil
770
- raise ArgumentError, "request must be provided" if request.nil?
826
+ raise ::ArgumentError, "request must be provided" if request.nil?
771
827
 
772
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::UpdateServiceRequest
828
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::UpdateServiceRequest
773
829
 
774
830
  # Converts hash and nil to an options object
775
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
831
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
776
832
 
777
833
  # Customize the options with defaults
778
834
  metadata = @config.rpcs.update_service.metadata.to_h
779
835
 
780
836
  # Set x-goog-api-client and x-goog-user-project headers
781
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
837
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
782
838
  lib_name: @config.lib_name, lib_version: @config.lib_version,
783
839
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
784
840
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -799,8 +855,8 @@ module Google
799
855
  yield response, operation if block_given?
800
856
  return response
801
857
  end
802
- rescue GRPC::BadStatus => e
803
- raise Google::Cloud::Error.from_error(e)
858
+ rescue ::GRPC::BadStatus => e
859
+ raise ::Google::Cloud::Error.from_error(e)
804
860
  end
805
861
 
806
862
  ##
@@ -808,38 +864,44 @@ module Google
808
864
  # the service.
809
865
  #
810
866
  # @overload delete_service(request, options = nil)
811
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::DeleteServiceRequest | Hash]
812
- # Deletes a service. This also deletes all endpoints associated with
813
- # the service.
814
- # @param options [Gapic::CallOptions, Hash]
867
+ # Pass arguments to `delete_service` via a request object, either of type
868
+ # {::Google::Cloud::ServiceDirectory::V1beta1::DeleteServiceRequest} or an equivalent Hash.
869
+ #
870
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::DeleteServiceRequest, ::Hash]
871
+ # A request object representing the call parameters. Required. To specify no
872
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
873
+ # @param options [::Gapic::CallOptions, ::Hash]
815
874
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
816
875
  #
817
876
  # @overload delete_service(name: nil)
818
- # @param name [String]
819
- # Required. The name of the service to delete.
877
+ # Pass arguments to `delete_service` via keyword arguments. Note that at
878
+ # least one keyword argument is required. To specify no parameters, or to keep all
879
+ # the default parameter values, pass an empty Hash as a request object (see above).
820
880
  #
881
+ # @param name [::String]
882
+ # Required. The name of the service to delete.
821
883
  #
822
884
  # @yield [response, operation] Access the result along with the RPC operation
823
- # @yieldparam response [Google::Protobuf::Empty]
824
- # @yieldparam operation [GRPC::ActiveCall::Operation]
885
+ # @yieldparam response [::Google::Protobuf::Empty]
886
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
825
887
  #
826
- # @return [Google::Protobuf::Empty]
888
+ # @return [::Google::Protobuf::Empty]
827
889
  #
828
- # @raise [Google::Cloud::Error] if the RPC is aborted.
890
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
829
891
  #
830
892
  def delete_service request, options = nil
831
- raise ArgumentError, "request must be provided" if request.nil?
893
+ raise ::ArgumentError, "request must be provided" if request.nil?
832
894
 
833
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::DeleteServiceRequest
895
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::DeleteServiceRequest
834
896
 
835
897
  # Converts hash and nil to an options object
836
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
898
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
837
899
 
838
900
  # Customize the options with defaults
839
901
  metadata = @config.rpcs.delete_service.metadata.to_h
840
902
 
841
903
  # Set x-goog-api-client and x-goog-user-project headers
842
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
904
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
843
905
  lib_name: @config.lib_name, lib_version: @config.lib_version,
844
906
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
845
907
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -860,23 +922,31 @@ module Google
860
922
  yield response, operation if block_given?
861
923
  return response
862
924
  end
863
- rescue GRPC::BadStatus => e
864
- raise Google::Cloud::Error.from_error(e)
925
+ rescue ::GRPC::BadStatus => e
926
+ raise ::Google::Cloud::Error.from_error(e)
865
927
  end
866
928
 
867
929
  ##
868
930
  # Creates a endpoint, and returns the new Endpoint.
869
931
  #
870
932
  # @overload create_endpoint(request, options = nil)
871
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::CreateEndpointRequest | Hash]
872
- # Creates a endpoint, and returns the new Endpoint.
873
- # @param options [Gapic::CallOptions, Hash]
933
+ # Pass arguments to `create_endpoint` via a request object, either of type
934
+ # {::Google::Cloud::ServiceDirectory::V1beta1::CreateEndpointRequest} or an equivalent Hash.
935
+ #
936
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::CreateEndpointRequest, ::Hash]
937
+ # A request object representing the call parameters. Required. To specify no
938
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
939
+ # @param options [::Gapic::CallOptions, ::Hash]
874
940
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
875
941
  #
876
942
  # @overload create_endpoint(parent: nil, endpoint_id: nil, endpoint: nil)
877
- # @param parent [String]
943
+ # Pass arguments to `create_endpoint` via keyword arguments. Note that at
944
+ # least one keyword argument is required. To specify no parameters, or to keep all
945
+ # the default parameter values, pass an empty Hash as a request object (see above).
946
+ #
947
+ # @param parent [::String]
878
948
  # Required. The resource name of the service that this endpoint provides.
879
- # @param endpoint_id [String]
949
+ # @param endpoint_id [::String]
880
950
  # Required. The Resource ID must be 1-63 characters long, and comply with
881
951
  # <a href="https://www.ietf.org/rfc/rfc1035.txt" target="_blank">RFC1035</a>.
882
952
  # Specifically, the name must be 1-63 characters long and match the regular
@@ -884,31 +954,30 @@ module Google
884
954
  # character must be a lowercase letter, and all following characters must
885
955
  # be a dash, lowercase letter, or digit, except the last character, which
886
956
  # cannot be a dash.
887
- # @param endpoint [Google::Cloud::ServiceDirectory::V1beta1::Endpoint | Hash]
957
+ # @param endpoint [::Google::Cloud::ServiceDirectory::V1beta1::Endpoint, ::Hash]
888
958
  # Required. A endpoint with initial fields set.
889
959
  #
890
- #
891
960
  # @yield [response, operation] Access the result along with the RPC operation
892
- # @yieldparam response [Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
893
- # @yieldparam operation [GRPC::ActiveCall::Operation]
961
+ # @yieldparam response [::Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
962
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
894
963
  #
895
- # @return [Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
964
+ # @return [::Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
896
965
  #
897
- # @raise [Google::Cloud::Error] if the RPC is aborted.
966
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
898
967
  #
899
968
  def create_endpoint request, options = nil
900
- raise ArgumentError, "request must be provided" if request.nil?
969
+ raise ::ArgumentError, "request must be provided" if request.nil?
901
970
 
902
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::CreateEndpointRequest
971
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::CreateEndpointRequest
903
972
 
904
973
  # Converts hash and nil to an options object
905
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
974
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
906
975
 
907
976
  # Customize the options with defaults
908
977
  metadata = @config.rpcs.create_endpoint.metadata.to_h
909
978
 
910
979
  # Set x-goog-api-client and x-goog-user-project headers
911
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
980
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
912
981
  lib_name: @config.lib_name, lib_version: @config.lib_version,
913
982
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
914
983
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -929,29 +998,37 @@ module Google
929
998
  yield response, operation if block_given?
930
999
  return response
931
1000
  end
932
- rescue GRPC::BadStatus => e
933
- raise Google::Cloud::Error.from_error(e)
1001
+ rescue ::GRPC::BadStatus => e
1002
+ raise ::Google::Cloud::Error.from_error(e)
934
1003
  end
935
1004
 
936
1005
  ##
937
1006
  # Lists all endpoints.
938
1007
  #
939
1008
  # @overload list_endpoints(request, options = nil)
940
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::ListEndpointsRequest | Hash]
941
- # Lists all endpoints.
942
- # @param options [Gapic::CallOptions, Hash]
1009
+ # Pass arguments to `list_endpoints` via a request object, either of type
1010
+ # {::Google::Cloud::ServiceDirectory::V1beta1::ListEndpointsRequest} or an equivalent Hash.
1011
+ #
1012
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::ListEndpointsRequest, ::Hash]
1013
+ # A request object representing the call parameters. Required. To specify no
1014
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1015
+ # @param options [::Gapic::CallOptions, ::Hash]
943
1016
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
944
1017
  #
945
1018
  # @overload list_endpoints(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
946
- # @param parent [String]
1019
+ # Pass arguments to `list_endpoints` via keyword arguments. Note that at
1020
+ # least one keyword argument is required. To specify no parameters, or to keep all
1021
+ # the default parameter values, pass an empty Hash as a request object (see above).
1022
+ #
1023
+ # @param parent [::String]
947
1024
  # Required. The resource name of the service whose endpoints we'd like to
948
1025
  # list.
949
- # @param page_size [Integer]
1026
+ # @param page_size [::Integer]
950
1027
  # Optional. The maximum number of items to return.
951
- # @param page_token [String]
1028
+ # @param page_token [::String]
952
1029
  # Optional. The next_page_token value returned from a previous List request,
953
1030
  # if any.
954
- # @param filter [String]
1031
+ # @param filter [::String]
955
1032
  # Optional. The filter to list result by.
956
1033
  #
957
1034
  # General filter string syntax:
@@ -977,31 +1054,30 @@ module Google
977
1054
  # * "doesnotexist.foo=bar" returns an empty list. Note that Endpoint doesn't
978
1055
  # have a field called "doesnotexist". Since the filter does not match any
979
1056
  # Endpoints, it returns no results.
980
- # @param order_by [String]
1057
+ # @param order_by [::String]
981
1058
  # Optional. The order to list result by.
982
1059
  #
983
- #
984
1060
  # @yield [response, operation] Access the result along with the RPC operation
985
- # @yieldparam response [Gapic::PagedEnumerable<Google::Cloud::ServiceDirectory::V1beta1::Endpoint>]
986
- # @yieldparam operation [GRPC::ActiveCall::Operation]
1061
+ # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::ServiceDirectory::V1beta1::Endpoint>]
1062
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
987
1063
  #
988
- # @return [Gapic::PagedEnumerable<Google::Cloud::ServiceDirectory::V1beta1::Endpoint>]
1064
+ # @return [::Gapic::PagedEnumerable<::Google::Cloud::ServiceDirectory::V1beta1::Endpoint>]
989
1065
  #
990
- # @raise [Google::Cloud::Error] if the RPC is aborted.
1066
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
991
1067
  #
992
1068
  def list_endpoints request, options = nil
993
- raise ArgumentError, "request must be provided" if request.nil?
1069
+ raise ::ArgumentError, "request must be provided" if request.nil?
994
1070
 
995
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::ListEndpointsRequest
1071
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::ListEndpointsRequest
996
1072
 
997
1073
  # Converts hash and nil to an options object
998
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1074
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
999
1075
 
1000
1076
  # Customize the options with defaults
1001
1077
  metadata = @config.rpcs.list_endpoints.metadata.to_h
1002
1078
 
1003
1079
  # Set x-goog-api-client and x-goog-user-project headers
1004
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
1080
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1005
1081
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1006
1082
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
1007
1083
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -1019,49 +1095,56 @@ module Google
1019
1095
  retry_policy: @config.retry_policy
1020
1096
 
1021
1097
  @registration_service_stub.call_rpc :list_endpoints, request, options: options do |response, operation|
1022
- response = Gapic::PagedEnumerable.new @registration_service_stub, :list_endpoints, request, response, operation, options
1098
+ response = ::Gapic::PagedEnumerable.new @registration_service_stub, :list_endpoints, request, response, operation, options
1023
1099
  yield response, operation if block_given?
1024
1100
  return response
1025
1101
  end
1026
- rescue GRPC::BadStatus => e
1027
- raise Google::Cloud::Error.from_error(e)
1102
+ rescue ::GRPC::BadStatus => e
1103
+ raise ::Google::Cloud::Error.from_error(e)
1028
1104
  end
1029
1105
 
1030
1106
  ##
1031
1107
  # Gets a endpoint.
1032
1108
  #
1033
1109
  # @overload get_endpoint(request, options = nil)
1034
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::GetEndpointRequest | Hash]
1035
- # Gets a endpoint.
1036
- # @param options [Gapic::CallOptions, Hash]
1110
+ # Pass arguments to `get_endpoint` via a request object, either of type
1111
+ # {::Google::Cloud::ServiceDirectory::V1beta1::GetEndpointRequest} or an equivalent Hash.
1112
+ #
1113
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::GetEndpointRequest, ::Hash]
1114
+ # A request object representing the call parameters. Required. To specify no
1115
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1116
+ # @param options [::Gapic::CallOptions, ::Hash]
1037
1117
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
1038
1118
  #
1039
1119
  # @overload get_endpoint(name: nil)
1040
- # @param name [String]
1041
- # Required. The name of the endpoint to get.
1120
+ # Pass arguments to `get_endpoint` via keyword arguments. Note that at
1121
+ # least one keyword argument is required. To specify no parameters, or to keep all
1122
+ # the default parameter values, pass an empty Hash as a request object (see above).
1042
1123
  #
1124
+ # @param name [::String]
1125
+ # Required. The name of the endpoint to get.
1043
1126
  #
1044
1127
  # @yield [response, operation] Access the result along with the RPC operation
1045
- # @yieldparam response [Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
1046
- # @yieldparam operation [GRPC::ActiveCall::Operation]
1128
+ # @yieldparam response [::Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
1129
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
1047
1130
  #
1048
- # @return [Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
1131
+ # @return [::Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
1049
1132
  #
1050
- # @raise [Google::Cloud::Error] if the RPC is aborted.
1133
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
1051
1134
  #
1052
1135
  def get_endpoint request, options = nil
1053
- raise ArgumentError, "request must be provided" if request.nil?
1136
+ raise ::ArgumentError, "request must be provided" if request.nil?
1054
1137
 
1055
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::GetEndpointRequest
1138
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::GetEndpointRequest
1056
1139
 
1057
1140
  # Converts hash and nil to an options object
1058
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1141
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1059
1142
 
1060
1143
  # Customize the options with defaults
1061
1144
  metadata = @config.rpcs.get_endpoint.metadata.to_h
1062
1145
 
1063
1146
  # Set x-goog-api-client and x-goog-user-project headers
1064
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
1147
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1065
1148
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1066
1149
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
1067
1150
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -1082,47 +1165,54 @@ module Google
1082
1165
  yield response, operation if block_given?
1083
1166
  return response
1084
1167
  end
1085
- rescue GRPC::BadStatus => e
1086
- raise Google::Cloud::Error.from_error(e)
1168
+ rescue ::GRPC::BadStatus => e
1169
+ raise ::Google::Cloud::Error.from_error(e)
1087
1170
  end
1088
1171
 
1089
1172
  ##
1090
1173
  # Updates a endpoint.
1091
1174
  #
1092
1175
  # @overload update_endpoint(request, options = nil)
1093
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::UpdateEndpointRequest | Hash]
1094
- # Updates a endpoint.
1095
- # @param options [Gapic::CallOptions, Hash]
1176
+ # Pass arguments to `update_endpoint` via a request object, either of type
1177
+ # {::Google::Cloud::ServiceDirectory::V1beta1::UpdateEndpointRequest} or an equivalent Hash.
1178
+ #
1179
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::UpdateEndpointRequest, ::Hash]
1180
+ # A request object representing the call parameters. Required. To specify no
1181
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1182
+ # @param options [::Gapic::CallOptions, ::Hash]
1096
1183
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
1097
1184
  #
1098
1185
  # @overload update_endpoint(endpoint: nil, update_mask: nil)
1099
- # @param endpoint [Google::Cloud::ServiceDirectory::V1beta1::Endpoint | Hash]
1186
+ # Pass arguments to `update_endpoint` via keyword arguments. Note that at
1187
+ # least one keyword argument is required. To specify no parameters, or to keep all
1188
+ # the default parameter values, pass an empty Hash as a request object (see above).
1189
+ #
1190
+ # @param endpoint [::Google::Cloud::ServiceDirectory::V1beta1::Endpoint, ::Hash]
1100
1191
  # Required. The updated endpoint.
1101
- # @param update_mask [Google::Protobuf::FieldMask | Hash]
1192
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
1102
1193
  # Required. List of fields to be updated in this request.
1103
1194
  #
1104
- #
1105
1195
  # @yield [response, operation] Access the result along with the RPC operation
1106
- # @yieldparam response [Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
1107
- # @yieldparam operation [GRPC::ActiveCall::Operation]
1196
+ # @yieldparam response [::Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
1197
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
1108
1198
  #
1109
- # @return [Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
1199
+ # @return [::Google::Cloud::ServiceDirectory::V1beta1::Endpoint]
1110
1200
  #
1111
- # @raise [Google::Cloud::Error] if the RPC is aborted.
1201
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
1112
1202
  #
1113
1203
  def update_endpoint request, options = nil
1114
- raise ArgumentError, "request must be provided" if request.nil?
1204
+ raise ::ArgumentError, "request must be provided" if request.nil?
1115
1205
 
1116
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::UpdateEndpointRequest
1206
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::UpdateEndpointRequest
1117
1207
 
1118
1208
  # Converts hash and nil to an options object
1119
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1209
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1120
1210
 
1121
1211
  # Customize the options with defaults
1122
1212
  metadata = @config.rpcs.update_endpoint.metadata.to_h
1123
1213
 
1124
1214
  # Set x-goog-api-client and x-goog-user-project headers
1125
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
1215
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1126
1216
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1127
1217
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
1128
1218
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -1143,45 +1233,52 @@ module Google
1143
1233
  yield response, operation if block_given?
1144
1234
  return response
1145
1235
  end
1146
- rescue GRPC::BadStatus => e
1147
- raise Google::Cloud::Error.from_error(e)
1236
+ rescue ::GRPC::BadStatus => e
1237
+ raise ::Google::Cloud::Error.from_error(e)
1148
1238
  end
1149
1239
 
1150
1240
  ##
1151
1241
  # Deletes a endpoint.
1152
1242
  #
1153
1243
  # @overload delete_endpoint(request, options = nil)
1154
- # @param request [Google::Cloud::ServiceDirectory::V1beta1::DeleteEndpointRequest | Hash]
1155
- # Deletes a endpoint.
1156
- # @param options [Gapic::CallOptions, Hash]
1244
+ # Pass arguments to `delete_endpoint` via a request object, either of type
1245
+ # {::Google::Cloud::ServiceDirectory::V1beta1::DeleteEndpointRequest} or an equivalent Hash.
1246
+ #
1247
+ # @param request [::Google::Cloud::ServiceDirectory::V1beta1::DeleteEndpointRequest, ::Hash]
1248
+ # A request object representing the call parameters. Required. To specify no
1249
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1250
+ # @param options [::Gapic::CallOptions, ::Hash]
1157
1251
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
1158
1252
  #
1159
1253
  # @overload delete_endpoint(name: nil)
1160
- # @param name [String]
1161
- # Required. The name of the endpoint to delete.
1254
+ # Pass arguments to `delete_endpoint` via keyword arguments. Note that at
1255
+ # least one keyword argument is required. To specify no parameters, or to keep all
1256
+ # the default parameter values, pass an empty Hash as a request object (see above).
1162
1257
  #
1258
+ # @param name [::String]
1259
+ # Required. The name of the endpoint to delete.
1163
1260
  #
1164
1261
  # @yield [response, operation] Access the result along with the RPC operation
1165
- # @yieldparam response [Google::Protobuf::Empty]
1166
- # @yieldparam operation [GRPC::ActiveCall::Operation]
1262
+ # @yieldparam response [::Google::Protobuf::Empty]
1263
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
1167
1264
  #
1168
- # @return [Google::Protobuf::Empty]
1265
+ # @return [::Google::Protobuf::Empty]
1169
1266
  #
1170
- # @raise [Google::Cloud::Error] if the RPC is aborted.
1267
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
1171
1268
  #
1172
1269
  def delete_endpoint request, options = nil
1173
- raise ArgumentError, "request must be provided" if request.nil?
1270
+ raise ::ArgumentError, "request must be provided" if request.nil?
1174
1271
 
1175
- request = Gapic::Protobuf.coerce request, to: Google::Cloud::ServiceDirectory::V1beta1::DeleteEndpointRequest
1272
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ServiceDirectory::V1beta1::DeleteEndpointRequest
1176
1273
 
1177
1274
  # Converts hash and nil to an options object
1178
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1275
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1179
1276
 
1180
1277
  # Customize the options with defaults
1181
1278
  metadata = @config.rpcs.delete_endpoint.metadata.to_h
1182
1279
 
1183
1280
  # Set x-goog-api-client and x-goog-user-project headers
1184
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
1281
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1185
1282
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1186
1283
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
1187
1284
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -1202,47 +1299,56 @@ module Google
1202
1299
  yield response, operation if block_given?
1203
1300
  return response
1204
1301
  end
1205
- rescue GRPC::BadStatus => e
1206
- raise Google::Cloud::Error.from_error(e)
1302
+ rescue ::GRPC::BadStatus => e
1303
+ raise ::Google::Cloud::Error.from_error(e)
1207
1304
  end
1208
1305
 
1209
1306
  ##
1210
1307
  # Gets the IAM Policy for a resource (namespace or service only).
1211
1308
  #
1212
1309
  # @overload get_iam_policy(request, options = nil)
1213
- # @param request [Google::Iam::V1::GetIamPolicyRequest | Hash]
1214
- # Gets the IAM Policy for a resource (namespace or service only).
1215
- # @param options [Gapic::CallOptions, Hash]
1310
+ # Pass arguments to `get_iam_policy` via a request object, either of type
1311
+ # {::Google::Iam::V1::GetIamPolicyRequest} or an equivalent Hash.
1312
+ #
1313
+ # @param request [::Google::Iam::V1::GetIamPolicyRequest, ::Hash]
1314
+ # A request object representing the call parameters. Required. To specify no
1315
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1316
+ # @param options [::Gapic::CallOptions, ::Hash]
1216
1317
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
1217
1318
  #
1218
- # @overload get_iam_policy(resource: nil)
1219
- # @param resource [String]
1220
- # REQUIRED: The resource for which the policy is being requested.
1221
- # `resource` is usually specified as a path. For example, a Project
1222
- # resource is specified as `projects/{project}`.
1319
+ # @overload get_iam_policy(resource: nil, options: nil)
1320
+ # Pass arguments to `get_iam_policy` via keyword arguments. Note that at
1321
+ # least one keyword argument is required. To specify no parameters, or to keep all
1322
+ # the default parameter values, pass an empty Hash as a request object (see above).
1223
1323
  #
1324
+ # @param resource [::String]
1325
+ # REQUIRED: The resource for which the policy is being requested.
1326
+ # See the operation documentation for the appropriate value for this field.
1327
+ # @param options [::Google::Iam::V1::GetPolicyOptions, ::Hash]
1328
+ # OPTIONAL: A `GetPolicyOptions` object for specifying options to
1329
+ # `GetIamPolicy`. This field is only used by Cloud IAM.
1224
1330
  #
1225
1331
  # @yield [response, operation] Access the result along with the RPC operation
1226
- # @yieldparam response [Google::Iam::V1::Policy]
1227
- # @yieldparam operation [GRPC::ActiveCall::Operation]
1332
+ # @yieldparam response [::Google::Iam::V1::Policy]
1333
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
1228
1334
  #
1229
- # @return [Google::Iam::V1::Policy]
1335
+ # @return [::Google::Iam::V1::Policy]
1230
1336
  #
1231
- # @raise [Google::Cloud::Error] if the RPC is aborted.
1337
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
1232
1338
  #
1233
1339
  def get_iam_policy request, options = nil
1234
- raise ArgumentError, "request must be provided" if request.nil?
1340
+ raise ::ArgumentError, "request must be provided" if request.nil?
1235
1341
 
1236
- request = Gapic::Protobuf.coerce request, to: Google::Iam::V1::GetIamPolicyRequest
1342
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Iam::V1::GetIamPolicyRequest
1237
1343
 
1238
1344
  # Converts hash and nil to an options object
1239
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1345
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1240
1346
 
1241
1347
  # Customize the options with defaults
1242
1348
  metadata = @config.rpcs.get_iam_policy.metadata.to_h
1243
1349
 
1244
1350
  # Set x-goog-api-client and x-goog-user-project headers
1245
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
1351
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1246
1352
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1247
1353
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
1248
1354
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -1263,52 +1369,58 @@ module Google
1263
1369
  yield response, operation if block_given?
1264
1370
  return response
1265
1371
  end
1266
- rescue GRPC::BadStatus => e
1267
- raise Google::Cloud::Error.from_error(e)
1372
+ rescue ::GRPC::BadStatus => e
1373
+ raise ::Google::Cloud::Error.from_error(e)
1268
1374
  end
1269
1375
 
1270
1376
  ##
1271
1377
  # Sets the IAM Policy for a resource (namespace or service only).
1272
1378
  #
1273
1379
  # @overload set_iam_policy(request, options = nil)
1274
- # @param request [Google::Iam::V1::SetIamPolicyRequest | Hash]
1275
- # Sets the IAM Policy for a resource (namespace or service only).
1276
- # @param options [Gapic::CallOptions, Hash]
1380
+ # Pass arguments to `set_iam_policy` via a request object, either of type
1381
+ # {::Google::Iam::V1::SetIamPolicyRequest} or an equivalent Hash.
1382
+ #
1383
+ # @param request [::Google::Iam::V1::SetIamPolicyRequest, ::Hash]
1384
+ # A request object representing the call parameters. Required. To specify no
1385
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1386
+ # @param options [::Gapic::CallOptions, ::Hash]
1277
1387
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
1278
1388
  #
1279
1389
  # @overload set_iam_policy(resource: nil, policy: nil)
1280
- # @param resource [String]
1390
+ # Pass arguments to `set_iam_policy` via keyword arguments. Note that at
1391
+ # least one keyword argument is required. To specify no parameters, or to keep all
1392
+ # the default parameter values, pass an empty Hash as a request object (see above).
1393
+ #
1394
+ # @param resource [::String]
1281
1395
  # REQUIRED: The resource for which the policy is being specified.
1282
- # `resource` is usually specified as a path. For example, a Project
1283
- # resource is specified as `projects/{project}`.
1284
- # @param policy [Google::Iam::V1::Policy | Hash]
1396
+ # See the operation documentation for the appropriate value for this field.
1397
+ # @param policy [::Google::Iam::V1::Policy, ::Hash]
1285
1398
  # REQUIRED: The complete policy to be applied to the `resource`. The size of
1286
1399
  # the policy is limited to a few 10s of KB. An empty policy is a
1287
1400
  # valid policy but certain Cloud Platform services (such as Projects)
1288
1401
  # might reject them.
1289
1402
  #
1290
- #
1291
1403
  # @yield [response, operation] Access the result along with the RPC operation
1292
- # @yieldparam response [Google::Iam::V1::Policy]
1293
- # @yieldparam operation [GRPC::ActiveCall::Operation]
1404
+ # @yieldparam response [::Google::Iam::V1::Policy]
1405
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
1294
1406
  #
1295
- # @return [Google::Iam::V1::Policy]
1407
+ # @return [::Google::Iam::V1::Policy]
1296
1408
  #
1297
- # @raise [Google::Cloud::Error] if the RPC is aborted.
1409
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
1298
1410
  #
1299
1411
  def set_iam_policy request, options = nil
1300
- raise ArgumentError, "request must be provided" if request.nil?
1412
+ raise ::ArgumentError, "request must be provided" if request.nil?
1301
1413
 
1302
- request = Gapic::Protobuf.coerce request, to: Google::Iam::V1::SetIamPolicyRequest
1414
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Iam::V1::SetIamPolicyRequest
1303
1415
 
1304
1416
  # Converts hash and nil to an options object
1305
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1417
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1306
1418
 
1307
1419
  # Customize the options with defaults
1308
1420
  metadata = @config.rpcs.set_iam_policy.metadata.to_h
1309
1421
 
1310
1422
  # Set x-goog-api-client and x-goog-user-project headers
1311
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
1423
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1312
1424
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1313
1425
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
1314
1426
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -1329,52 +1441,58 @@ module Google
1329
1441
  yield response, operation if block_given?
1330
1442
  return response
1331
1443
  end
1332
- rescue GRPC::BadStatus => e
1333
- raise Google::Cloud::Error.from_error(e)
1444
+ rescue ::GRPC::BadStatus => e
1445
+ raise ::Google::Cloud::Error.from_error(e)
1334
1446
  end
1335
1447
 
1336
1448
  ##
1337
1449
  # Tests IAM permissions for a resource (namespace or service only).
1338
1450
  #
1339
1451
  # @overload test_iam_permissions(request, options = nil)
1340
- # @param request [Google::Iam::V1::TestIamPermissionsRequest | Hash]
1341
- # Tests IAM permissions for a resource (namespace or service only).
1342
- # @param options [Gapic::CallOptions, Hash]
1452
+ # Pass arguments to `test_iam_permissions` via a request object, either of type
1453
+ # {::Google::Iam::V1::TestIamPermissionsRequest} or an equivalent Hash.
1454
+ #
1455
+ # @param request [::Google::Iam::V1::TestIamPermissionsRequest, ::Hash]
1456
+ # A request object representing the call parameters. Required. To specify no
1457
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1458
+ # @param options [::Gapic::CallOptions, ::Hash]
1343
1459
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
1344
1460
  #
1345
1461
  # @overload test_iam_permissions(resource: nil, permissions: nil)
1346
- # @param resource [String]
1462
+ # Pass arguments to `test_iam_permissions` via keyword arguments. Note that at
1463
+ # least one keyword argument is required. To specify no parameters, or to keep all
1464
+ # the default parameter values, pass an empty Hash as a request object (see above).
1465
+ #
1466
+ # @param resource [::String]
1347
1467
  # REQUIRED: The resource for which the policy detail is being requested.
1348
- # `resource` is usually specified as a path. For example, a Project
1349
- # resource is specified as `projects/{project}`.
1350
- # @param permissions [Array<String>]
1468
+ # See the operation documentation for the appropriate value for this field.
1469
+ # @param permissions [::Array<::String>]
1351
1470
  # The set of permissions to check for the `resource`. Permissions with
1352
1471
  # wildcards (such as '*' or 'storage.*') are not allowed. For more
1353
1472
  # information see
1354
1473
  # [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
1355
1474
  #
1356
- #
1357
1475
  # @yield [response, operation] Access the result along with the RPC operation
1358
- # @yieldparam response [Google::Iam::V1::TestIamPermissionsResponse]
1359
- # @yieldparam operation [GRPC::ActiveCall::Operation]
1476
+ # @yieldparam response [::Google::Iam::V1::TestIamPermissionsResponse]
1477
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
1360
1478
  #
1361
- # @return [Google::Iam::V1::TestIamPermissionsResponse]
1479
+ # @return [::Google::Iam::V1::TestIamPermissionsResponse]
1362
1480
  #
1363
- # @raise [Google::Cloud::Error] if the RPC is aborted.
1481
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
1364
1482
  #
1365
1483
  def test_iam_permissions request, options = nil
1366
- raise ArgumentError, "request must be provided" if request.nil?
1484
+ raise ::ArgumentError, "request must be provided" if request.nil?
1367
1485
 
1368
- request = Gapic::Protobuf.coerce request, to: Google::Iam::V1::TestIamPermissionsRequest
1486
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Iam::V1::TestIamPermissionsRequest
1369
1487
 
1370
1488
  # Converts hash and nil to an options object
1371
- options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1489
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1372
1490
 
1373
1491
  # Customize the options with defaults
1374
1492
  metadata = @config.rpcs.test_iam_permissions.metadata.to_h
1375
1493
 
1376
1494
  # Set x-goog-api-client and x-goog-user-project headers
1377
- metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
1495
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1378
1496
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1379
1497
  gapic_version: ::Google::Cloud::ServiceDirectory::V1beta1::VERSION
1380
1498
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
@@ -1395,8 +1513,8 @@ module Google
1395
1513
  yield response, operation if block_given?
1396
1514
  return response
1397
1515
  end
1398
- rescue GRPC::BadStatus => e
1399
- raise Google::Cloud::Error.from_error(e)
1516
+ rescue ::GRPC::BadStatus => e
1517
+ raise ::Google::Cloud::Error.from_error(e)
1400
1518
  end
1401
1519
 
1402
1520
  ##
@@ -1406,7 +1524,7 @@ module Google
1406
1524
  # providing control over timeouts, retry behavior, logging, transport
1407
1525
  # parameters, and other low-level controls. Certain parameters can also be
1408
1526
  # applied individually to specific RPCs. See
1409
- # {Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client::Configuration::Rpcs}
1527
+ # {::Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client::Configuration::Rpcs}
1410
1528
  # for a list of RPCs that can be configured independently.
1411
1529
  #
1412
1530
  # Configuration can be applied globally to all clients, or to a single client
@@ -1417,22 +1535,22 @@ module Google
1417
1535
  # To modify the global config, setting the timeout for create_namespace
1418
1536
  # to 20 seconds, and all remaining timeouts to 10 seconds:
1419
1537
  #
1420
- # Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.configure do |config|
1421
- # config.timeout = 10_000
1422
- # config.rpcs.create_namespace.timeout = 20_000
1538
+ # ::Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.configure do |config|
1539
+ # config.timeout = 10.0
1540
+ # config.rpcs.create_namespace.timeout = 20.0
1423
1541
  # end
1424
1542
  #
1425
1543
  # To apply the above configuration only to a new client:
1426
1544
  #
1427
- # client = Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.new do |config|
1428
- # config.timeout = 10_000
1429
- # config.rpcs.create_namespace.timeout = 20_000
1545
+ # client = ::Google::Cloud::ServiceDirectory::V1beta1::RegistrationService::Client.new do |config|
1546
+ # config.timeout = 10.0
1547
+ # config.rpcs.create_namespace.timeout = 20.0
1430
1548
  # end
1431
1549
  #
1432
1550
  # @!attribute [rw] endpoint
1433
1551
  # The hostname or hostname:port of the service endpoint.
1434
1552
  # Defaults to `"servicedirectory.googleapis.com"`.
1435
- # @return [String]
1553
+ # @return [::String]
1436
1554
  # @!attribute [rw] credentials
1437
1555
  # Credentials to send with calls. You may provide any of the following types:
1438
1556
  # * (`String`) The path to a service account key file in JSON format
@@ -1444,29 +1562,29 @@ module Google
1444
1562
  # * (`GRPC::Core::Channel`) a gRPC channel with included credentials
1445
1563
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
1446
1564
  # * (`nil`) indicating no credentials
1447
- # @return [Object]
1565
+ # @return [::Object]
1448
1566
  # @!attribute [rw] scope
1449
1567
  # The OAuth scopes
1450
- # @return [Array<String>]
1568
+ # @return [::Array<::String>]
1451
1569
  # @!attribute [rw] lib_name
1452
1570
  # The library name as recorded in instrumentation and logging
1453
- # @return [String]
1571
+ # @return [::String]
1454
1572
  # @!attribute [rw] lib_version
1455
1573
  # The library version as recorded in instrumentation and logging
1456
- # @return [String]
1574
+ # @return [::String]
1457
1575
  # @!attribute [rw] channel_args
1458
1576
  # Extra parameters passed to the gRPC channel. Note: this is ignored if a
1459
1577
  # `GRPC::Core::Channel` object is provided as the credential.
1460
- # @return [Hash]
1578
+ # @return [::Hash]
1461
1579
  # @!attribute [rw] interceptors
1462
1580
  # An array of interceptors that are run before calls are executed.
1463
- # @return [Array<GRPC::ClientInterceptor>]
1581
+ # @return [::Array<::GRPC::ClientInterceptor>]
1464
1582
  # @!attribute [rw] timeout
1465
- # The call timeout in milliseconds.
1466
- # @return [Numeric]
1583
+ # The call timeout in seconds.
1584
+ # @return [::Numeric]
1467
1585
  # @!attribute [rw] metadata
1468
1586
  # Additional gRPC headers to be sent with the call.
1469
- # @return [Hash{Symbol=>String}]
1587
+ # @return [::Hash{::Symbol=>::String}]
1470
1588
  # @!attribute [rw] retry_policy
1471
1589
  # The retry policy. The value is a hash with the following keys:
1472
1590
  # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
@@ -1474,25 +1592,29 @@ module Google
1474
1592
  # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
1475
1593
  # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
1476
1594
  # trigger a retry.
1477
- # @return [Hash]
1595
+ # @return [::Hash]
1596
+ # @!attribute [rw] quota_project
1597
+ # A separate project against which to charge quota.
1598
+ # @return [::String]
1478
1599
  #
1479
1600
  class Configuration
1480
- extend Gapic::Config
1601
+ extend ::Gapic::Config
1481
1602
 
1482
- config_attr :endpoint, "servicedirectory.googleapis.com", String
1483
- config_attr :credentials, nil do |value|
1603
+ config_attr :endpoint, "servicedirectory.googleapis.com", ::String
1604
+ config_attr :credentials, nil do |value|
1484
1605
  allowed = [::String, ::Hash, ::Proc, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
1485
1606
  allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
1486
1607
  allowed.any? { |klass| klass === value }
1487
1608
  end
1488
- config_attr :scope, nil, String, Array, nil
1489
- config_attr :lib_name, nil, String, nil
1490
- config_attr :lib_version, nil, String, nil
1491
- config_attr(:channel_args, { "grpc.service_config_disable_resolution"=>1 }, Hash, nil)
1492
- config_attr :interceptors, nil, Array, nil
1493
- config_attr :timeout, nil, Numeric, nil
1494
- config_attr :metadata, nil, Hash, nil
1495
- config_attr :retry_policy, nil, Hash, Proc, nil
1609
+ config_attr :scope, nil, ::String, ::Array, nil
1610
+ config_attr :lib_name, nil, ::String, nil
1611
+ config_attr :lib_version, nil, ::String, nil
1612
+ config_attr(:channel_args, { "grpc.service_config_disable_resolution"=>1 }, ::Hash, nil)
1613
+ config_attr :interceptors, nil, ::Array, nil
1614
+ config_attr :timeout, nil, ::Numeric, nil
1615
+ config_attr :metadata, nil, ::Hash, nil
1616
+ config_attr :retry_policy, nil, ::Hash, ::Proc, nil
1617
+ config_attr :quota_project, nil, ::String, nil
1496
1618
 
1497
1619
  # @private
1498
1620
  def initialize parent_config = nil
@@ -1508,7 +1630,7 @@ module Google
1508
1630
  def rpcs
1509
1631
  @rpcs ||= begin
1510
1632
  parent_rpcs = nil
1511
- parent_rpcs = @parent_config.rpcs if @parent_config&.respond_to? :rpcs
1633
+ parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config&.respond_to?(:rpcs)
1512
1634
  Rpcs.new parent_rpcs
1513
1635
  end
1514
1636
  end
@@ -1533,133 +1655,133 @@ module Google
1533
1655
  class Rpcs
1534
1656
  ##
1535
1657
  # RPC-specific configuration for `create_namespace`
1536
- # @return [Gapic::Config::Method]
1658
+ # @return [::Gapic::Config::Method]
1537
1659
  #
1538
1660
  attr_reader :create_namespace
1539
1661
  ##
1540
1662
  # RPC-specific configuration for `list_namespaces`
1541
- # @return [Gapic::Config::Method]
1663
+ # @return [::Gapic::Config::Method]
1542
1664
  #
1543
1665
  attr_reader :list_namespaces
1544
1666
  ##
1545
1667
  # RPC-specific configuration for `get_namespace`
1546
- # @return [Gapic::Config::Method]
1668
+ # @return [::Gapic::Config::Method]
1547
1669
  #
1548
1670
  attr_reader :get_namespace
1549
1671
  ##
1550
1672
  # RPC-specific configuration for `update_namespace`
1551
- # @return [Gapic::Config::Method]
1673
+ # @return [::Gapic::Config::Method]
1552
1674
  #
1553
1675
  attr_reader :update_namespace
1554
1676
  ##
1555
1677
  # RPC-specific configuration for `delete_namespace`
1556
- # @return [Gapic::Config::Method]
1678
+ # @return [::Gapic::Config::Method]
1557
1679
  #
1558
1680
  attr_reader :delete_namespace
1559
1681
  ##
1560
1682
  # RPC-specific configuration for `create_service`
1561
- # @return [Gapic::Config::Method]
1683
+ # @return [::Gapic::Config::Method]
1562
1684
  #
1563
1685
  attr_reader :create_service
1564
1686
  ##
1565
1687
  # RPC-specific configuration for `list_services`
1566
- # @return [Gapic::Config::Method]
1688
+ # @return [::Gapic::Config::Method]
1567
1689
  #
1568
1690
  attr_reader :list_services
1569
1691
  ##
1570
1692
  # RPC-specific configuration for `get_service`
1571
- # @return [Gapic::Config::Method]
1693
+ # @return [::Gapic::Config::Method]
1572
1694
  #
1573
1695
  attr_reader :get_service
1574
1696
  ##
1575
1697
  # RPC-specific configuration for `update_service`
1576
- # @return [Gapic::Config::Method]
1698
+ # @return [::Gapic::Config::Method]
1577
1699
  #
1578
1700
  attr_reader :update_service
1579
1701
  ##
1580
1702
  # RPC-specific configuration for `delete_service`
1581
- # @return [Gapic::Config::Method]
1703
+ # @return [::Gapic::Config::Method]
1582
1704
  #
1583
1705
  attr_reader :delete_service
1584
1706
  ##
1585
1707
  # RPC-specific configuration for `create_endpoint`
1586
- # @return [Gapic::Config::Method]
1708
+ # @return [::Gapic::Config::Method]
1587
1709
  #
1588
1710
  attr_reader :create_endpoint
1589
1711
  ##
1590
1712
  # RPC-specific configuration for `list_endpoints`
1591
- # @return [Gapic::Config::Method]
1713
+ # @return [::Gapic::Config::Method]
1592
1714
  #
1593
1715
  attr_reader :list_endpoints
1594
1716
  ##
1595
1717
  # RPC-specific configuration for `get_endpoint`
1596
- # @return [Gapic::Config::Method]
1718
+ # @return [::Gapic::Config::Method]
1597
1719
  #
1598
1720
  attr_reader :get_endpoint
1599
1721
  ##
1600
1722
  # RPC-specific configuration for `update_endpoint`
1601
- # @return [Gapic::Config::Method]
1723
+ # @return [::Gapic::Config::Method]
1602
1724
  #
1603
1725
  attr_reader :update_endpoint
1604
1726
  ##
1605
1727
  # RPC-specific configuration for `delete_endpoint`
1606
- # @return [Gapic::Config::Method]
1728
+ # @return [::Gapic::Config::Method]
1607
1729
  #
1608
1730
  attr_reader :delete_endpoint
1609
1731
  ##
1610
1732
  # RPC-specific configuration for `get_iam_policy`
1611
- # @return [Gapic::Config::Method]
1733
+ # @return [::Gapic::Config::Method]
1612
1734
  #
1613
1735
  attr_reader :get_iam_policy
1614
1736
  ##
1615
1737
  # RPC-specific configuration for `set_iam_policy`
1616
- # @return [Gapic::Config::Method]
1738
+ # @return [::Gapic::Config::Method]
1617
1739
  #
1618
1740
  attr_reader :set_iam_policy
1619
1741
  ##
1620
1742
  # RPC-specific configuration for `test_iam_permissions`
1621
- # @return [Gapic::Config::Method]
1743
+ # @return [::Gapic::Config::Method]
1622
1744
  #
1623
1745
  attr_reader :test_iam_permissions
1624
1746
 
1625
1747
  # @private
1626
1748
  def initialize parent_rpcs = nil
1627
1749
  create_namespace_config = parent_rpcs&.create_namespace if parent_rpcs&.respond_to? :create_namespace
1628
- @create_namespace = Gapic::Config::Method.new create_namespace_config
1750
+ @create_namespace = ::Gapic::Config::Method.new create_namespace_config
1629
1751
  list_namespaces_config = parent_rpcs&.list_namespaces if parent_rpcs&.respond_to? :list_namespaces
1630
- @list_namespaces = Gapic::Config::Method.new list_namespaces_config
1752
+ @list_namespaces = ::Gapic::Config::Method.new list_namespaces_config
1631
1753
  get_namespace_config = parent_rpcs&.get_namespace if parent_rpcs&.respond_to? :get_namespace
1632
- @get_namespace = Gapic::Config::Method.new get_namespace_config
1754
+ @get_namespace = ::Gapic::Config::Method.new get_namespace_config
1633
1755
  update_namespace_config = parent_rpcs&.update_namespace if parent_rpcs&.respond_to? :update_namespace
1634
- @update_namespace = Gapic::Config::Method.new update_namespace_config
1756
+ @update_namespace = ::Gapic::Config::Method.new update_namespace_config
1635
1757
  delete_namespace_config = parent_rpcs&.delete_namespace if parent_rpcs&.respond_to? :delete_namespace
1636
- @delete_namespace = Gapic::Config::Method.new delete_namespace_config
1758
+ @delete_namespace = ::Gapic::Config::Method.new delete_namespace_config
1637
1759
  create_service_config = parent_rpcs&.create_service if parent_rpcs&.respond_to? :create_service
1638
- @create_service = Gapic::Config::Method.new create_service_config
1760
+ @create_service = ::Gapic::Config::Method.new create_service_config
1639
1761
  list_services_config = parent_rpcs&.list_services if parent_rpcs&.respond_to? :list_services
1640
- @list_services = Gapic::Config::Method.new list_services_config
1762
+ @list_services = ::Gapic::Config::Method.new list_services_config
1641
1763
  get_service_config = parent_rpcs&.get_service if parent_rpcs&.respond_to? :get_service
1642
- @get_service = Gapic::Config::Method.new get_service_config
1764
+ @get_service = ::Gapic::Config::Method.new get_service_config
1643
1765
  update_service_config = parent_rpcs&.update_service if parent_rpcs&.respond_to? :update_service
1644
- @update_service = Gapic::Config::Method.new update_service_config
1766
+ @update_service = ::Gapic::Config::Method.new update_service_config
1645
1767
  delete_service_config = parent_rpcs&.delete_service if parent_rpcs&.respond_to? :delete_service
1646
- @delete_service = Gapic::Config::Method.new delete_service_config
1768
+ @delete_service = ::Gapic::Config::Method.new delete_service_config
1647
1769
  create_endpoint_config = parent_rpcs&.create_endpoint if parent_rpcs&.respond_to? :create_endpoint
1648
- @create_endpoint = Gapic::Config::Method.new create_endpoint_config
1770
+ @create_endpoint = ::Gapic::Config::Method.new create_endpoint_config
1649
1771
  list_endpoints_config = parent_rpcs&.list_endpoints if parent_rpcs&.respond_to? :list_endpoints
1650
- @list_endpoints = Gapic::Config::Method.new list_endpoints_config
1772
+ @list_endpoints = ::Gapic::Config::Method.new list_endpoints_config
1651
1773
  get_endpoint_config = parent_rpcs&.get_endpoint if parent_rpcs&.respond_to? :get_endpoint
1652
- @get_endpoint = Gapic::Config::Method.new get_endpoint_config
1774
+ @get_endpoint = ::Gapic::Config::Method.new get_endpoint_config
1653
1775
  update_endpoint_config = parent_rpcs&.update_endpoint if parent_rpcs&.respond_to? :update_endpoint
1654
- @update_endpoint = Gapic::Config::Method.new update_endpoint_config
1776
+ @update_endpoint = ::Gapic::Config::Method.new update_endpoint_config
1655
1777
  delete_endpoint_config = parent_rpcs&.delete_endpoint if parent_rpcs&.respond_to? :delete_endpoint
1656
- @delete_endpoint = Gapic::Config::Method.new delete_endpoint_config
1778
+ @delete_endpoint = ::Gapic::Config::Method.new delete_endpoint_config
1657
1779
  get_iam_policy_config = parent_rpcs&.get_iam_policy if parent_rpcs&.respond_to? :get_iam_policy
1658
- @get_iam_policy = Gapic::Config::Method.new get_iam_policy_config
1780
+ @get_iam_policy = ::Gapic::Config::Method.new get_iam_policy_config
1659
1781
  set_iam_policy_config = parent_rpcs&.set_iam_policy if parent_rpcs&.respond_to? :set_iam_policy
1660
- @set_iam_policy = Gapic::Config::Method.new set_iam_policy_config
1782
+ @set_iam_policy = ::Gapic::Config::Method.new set_iam_policy_config
1661
1783
  test_iam_permissions_config = parent_rpcs&.test_iam_permissions if parent_rpcs&.respond_to? :test_iam_permissions
1662
- @test_iam_permissions = Gapic::Config::Method.new test_iam_permissions_config
1784
+ @test_iam_permissions = ::Gapic::Config::Method.new test_iam_permissions_config
1663
1785
 
1664
1786
  yield self if block_given?
1665
1787
  end
@@ -1671,13 +1793,3 @@ module Google
1671
1793
  end
1672
1794
  end
1673
1795
  end
1674
-
1675
- # rubocop:disable Lint/HandleExceptions
1676
-
1677
- # Once client is loaded, load helpers.rb if it exists.
1678
- begin
1679
- require "google/cloud/service_directory/v1beta1/registration_service/helpers"
1680
- rescue LoadError
1681
- end
1682
-
1683
- # rubocop:enable Lint/HandleExceptions