google-cloud-access_approval-v1 0.1.2 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.yardopts +1 -1
- data/AUTHENTICATION.md +6 -6
- data/README.md +7 -3
- data/lib/google/cloud/access_approval/v1.rb +1 -1
- data/lib/google/cloud/access_approval/v1/access_approval.rb +2 -2
- data/lib/google/cloud/access_approval/v1/access_approval/client.rb +164 -159
- data/lib/google/cloud/access_approval/v1/access_approval/credentials.rb +1 -1
- data/lib/google/cloud/access_approval/v1/version.rb +1 -1
- data/proto_docs/README.md +1 -1
- data/proto_docs/google/api/resource.rb +12 -12
- data/proto_docs/google/cloud/accessapproval/v1/accessapproval.rb +69 -69
- data/proto_docs/google/protobuf/empty.rb +2 -2
- data/proto_docs/google/protobuf/field_mask.rb +3 -3
- data/proto_docs/google/protobuf/timestamp.rb +4 -4
- metadata +34 -7
- data/lib/google/cloud/common_resources_pb.rb +0 -15
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d1311ef7dfd446861e3adf565c4c5f50d64f43b4c8ea50de7f24b15dccdc0d38
|
4
|
+
data.tar.gz: aba9d5a1f89830e14bd52baafdd6d020186ef04d9cf218087fe965e8c6a19226
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7ae7c38cdb3d16b87db9895b3c5d5b5a758cce7ac463ee4780ee483005d4f0a870f912dc85d6005b4d8de27b66e177b1fef70b1bc39a39ba57dff51fc4d0b5ea
|
7
|
+
data.tar.gz: 9717dfc89ecf08dde6f692e8f5dc17d7bb0634666d5062f692d53026d023805ba4d22ff01258f6c8e9786df4e9be1ddc9b9ce011a9acb829a5eebc9af4dc39d4
|
data/.yardopts
CHANGED
data/AUTHENTICATION.md
CHANGED
@@ -27,7 +27,7 @@ export ACCESS_APPROVAL_CREDENTIALS=path/to/keyfile.json
|
|
27
27
|
```ruby
|
28
28
|
require "google/cloud/access_approval/v1"
|
29
29
|
|
30
|
-
client = Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
30
|
+
client = ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
31
31
|
```
|
32
32
|
|
33
33
|
## Credential Lookup
|
@@ -64,7 +64,7 @@ containers where writing files is difficult or not encouraged.
|
|
64
64
|
|
65
65
|
The environment variables that google-cloud-access_approval-v1
|
66
66
|
checks for credentials are configured on the service Credentials class (such as
|
67
|
-
{Google::Cloud::AccessApproval::V1::AccessApproval::Credentials}):
|
67
|
+
{::Google::Cloud::AccessApproval::V1::AccessApproval::Credentials}):
|
68
68
|
|
69
69
|
1. `ACCESS_APPROVAL_CREDENTIALS` - Path to JSON file, or JSON contents
|
70
70
|
2. `ACCESS_APPROVAL_KEYFILE` - Path to JSON file, or JSON contents
|
@@ -77,7 +77,7 @@ require "google/cloud/access_approval/v1"
|
|
77
77
|
|
78
78
|
ENV["ACCESS_APPROVAL_CREDENTIALS"] = "path/to/keyfile.json"
|
79
79
|
|
80
|
-
client = Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
80
|
+
client = ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
81
81
|
```
|
82
82
|
|
83
83
|
### Configuration
|
@@ -88,7 +88,7 @@ environment variables. Either on an individual client initialization:
|
|
88
88
|
```ruby
|
89
89
|
require "google/cloud/access_approval/v1"
|
90
90
|
|
91
|
-
client = Google::Cloud::AccessApproval::V1::AccessApproval::Client.new do |config|
|
91
|
+
client = ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.new do |config|
|
92
92
|
config.credentials = "path/to/keyfile.json"
|
93
93
|
end
|
94
94
|
```
|
@@ -98,11 +98,11 @@ Or configured globally for all clients:
|
|
98
98
|
```ruby
|
99
99
|
require "google/cloud/access_approval/v1"
|
100
100
|
|
101
|
-
Google::Cloud::AccessApproval::V1::AccessApproval::Client.configure do |config|
|
101
|
+
::Google::Cloud::AccessApproval::V1::AccessApproval::Client.configure do |config|
|
102
102
|
config.credentials = "path/to/keyfile.json"
|
103
103
|
end
|
104
104
|
|
105
|
-
client = Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
105
|
+
client = ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
106
106
|
```
|
107
107
|
|
108
108
|
### Cloud SDK
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
# Ruby Client for the Access Approval
|
1
|
+
# Ruby Client for the Access Approval V1 API
|
2
2
|
|
3
|
-
API Client library for the Access Approval
|
3
|
+
API Client library for the Access Approval V1 API
|
4
4
|
|
5
5
|
An API for controlling access to data by Google personnel.
|
6
6
|
|
@@ -18,6 +18,7 @@ In order to use this library, you first need to go through the following steps:
|
|
18
18
|
|
19
19
|
1. [Select or create a Cloud Platform project.](https://console.cloud.google.com/project)
|
20
20
|
1. [Enable billing for your project.](https://cloud.google.com/billing/docs/how-to/modify-project#enable_billing_for_a_project)
|
21
|
+
1. [Enable the API.](https://console.cloud.google.com/apis/library/accessapproval.googleapis.com)
|
21
22
|
1. {file:AUTHENTICATION.md Set up authentication.}
|
22
23
|
|
23
24
|
## Quick Start
|
@@ -25,7 +26,7 @@ In order to use this library, you first need to go through the following steps:
|
|
25
26
|
```ruby
|
26
27
|
require "google/cloud/access_approval/v1"
|
27
28
|
|
28
|
-
client = Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
29
|
+
client = ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
29
30
|
request = my_create_request
|
30
31
|
response = client.list_approval_requests request
|
31
32
|
```
|
@@ -33,6 +34,9 @@ response = client.list_approval_requests request
|
|
33
34
|
View the [Client Library Documentation](https://googleapis.dev/ruby/google-cloud-access_approval-v1/latest)
|
34
35
|
for class and method documentation.
|
35
36
|
|
37
|
+
See also the [Product Documentation](https://cloud.google.com/access-approval/)
|
38
|
+
for general usage information.
|
39
|
+
|
36
40
|
## Enabling Logging
|
37
41
|
|
38
42
|
To enable logging for this library, set the logger for the underlying [gRPC](https://github.com/grpc/grpc/tree/master/src/ruby) library.
|
@@ -26,7 +26,7 @@ module Google
|
|
26
26
|
# To load this package, including all its services, and instantiate a client:
|
27
27
|
#
|
28
28
|
# require "google/cloud/access_approval/v1"
|
29
|
-
# client = Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
29
|
+
# client = ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
30
30
|
#
|
31
31
|
module V1
|
32
32
|
end
|
@@ -34,7 +34,7 @@ module Google
|
|
34
34
|
# Google personnel. It defines the following resource model:
|
35
35
|
#
|
36
36
|
# - The API has a collection of
|
37
|
-
# {Google::Cloud::AccessApproval::V1::ApprovalRequest ApprovalRequest}
|
37
|
+
# {::Google::Cloud::AccessApproval::V1::ApprovalRequest ApprovalRequest}
|
38
38
|
# resources, named `approvalRequests/{approval_request_id}`
|
39
39
|
# - The API has top-level settings per Project/Folder/Organization, named
|
40
40
|
# `accessApprovalSettings`
|
@@ -67,7 +67,7 @@ module Google
|
|
67
67
|
# To load this service and instantiate a client:
|
68
68
|
#
|
69
69
|
# require "google/cloud/access_approval/v1/access_approval"
|
70
|
-
# client = Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
70
|
+
# client = ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
71
71
|
#
|
72
72
|
module AccessApproval
|
73
73
|
end
|
@@ -31,7 +31,7 @@ module Google
|
|
31
31
|
# Google personnel. It defines the following resource model:
|
32
32
|
#
|
33
33
|
# - The API has a collection of
|
34
|
-
# {Google::Cloud::AccessApproval::V1::ApprovalRequest ApprovalRequest}
|
34
|
+
# {::Google::Cloud::AccessApproval::V1::ApprovalRequest ApprovalRequest}
|
35
35
|
# resources, named `approvalRequests/{approval_request_id}`
|
36
36
|
# - The API has top-level settings per Project/Folder/Organization, named
|
37
37
|
# `accessApprovalSettings`
|
@@ -68,15 +68,15 @@ module Google
|
|
68
68
|
##
|
69
69
|
# Configure the AccessApproval Client class.
|
70
70
|
#
|
71
|
-
# See {Google::Cloud::AccessApproval::V1::AccessApproval::Client::Configuration}
|
71
|
+
# See {::Google::Cloud::AccessApproval::V1::AccessApproval::Client::Configuration}
|
72
72
|
# for a description of the configuration fields.
|
73
73
|
#
|
74
74
|
# ## Example
|
75
75
|
#
|
76
76
|
# To modify the configuration for all AccessApproval clients:
|
77
77
|
#
|
78
|
-
# Google::Cloud::AccessApproval::V1::AccessApproval::Client.configure do |config|
|
79
|
-
# config.timeout =
|
78
|
+
# ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.configure do |config|
|
79
|
+
# config.timeout = 10.0
|
80
80
|
# end
|
81
81
|
#
|
82
82
|
# @yield [config] Configure the Client client.
|
@@ -108,7 +108,7 @@ module Google
|
|
108
108
|
# but structural changes (adding new fields, etc.) are not allowed. Structural changes
|
109
109
|
# should be made on {Client.configure}.
|
110
110
|
#
|
111
|
-
# See {Google::Cloud::AccessApproval::V1::AccessApproval::Client::Configuration}
|
111
|
+
# See {::Google::Cloud::AccessApproval::V1::AccessApproval::Client::Configuration}
|
112
112
|
# for a description of the configuration fields.
|
113
113
|
#
|
114
114
|
# @yield [config] Configure the Client client.
|
@@ -129,13 +129,13 @@ module Google
|
|
129
129
|
# To create a new AccessApproval client with the default
|
130
130
|
# configuration:
|
131
131
|
#
|
132
|
-
# client = Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
132
|
+
# client = ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.new
|
133
133
|
#
|
134
134
|
# To create a new AccessApproval client with a custom
|
135
135
|
# configuration:
|
136
136
|
#
|
137
|
-
# client = Google::Cloud::AccessApproval::V1::AccessApproval::Client.new do |config|
|
138
|
-
# config.timeout =
|
137
|
+
# client = ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.new do |config|
|
138
|
+
# config.timeout = 10.0
|
139
139
|
# end
|
140
140
|
#
|
141
141
|
# @yield [config] Configure the AccessApproval client.
|
@@ -160,10 +160,11 @@ module Google
|
|
160
160
|
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
161
161
|
credentials = Credentials.new credentials, scope: @config.scope
|
162
162
|
end
|
163
|
-
@quota_project_id =
|
163
|
+
@quota_project_id = @config.quota_project
|
164
|
+
@quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
|
164
165
|
|
165
|
-
@access_approval_stub = Gapic::ServiceStub.new(
|
166
|
-
Google::Cloud::AccessApproval::V1::AccessApproval::Stub,
|
166
|
+
@access_approval_stub = ::Gapic::ServiceStub.new(
|
167
|
+
::Google::Cloud::AccessApproval::V1::AccessApproval::Stub,
|
167
168
|
credentials: credentials,
|
168
169
|
endpoint: @config.endpoint,
|
169
170
|
channel_args: @config.channel_args,
|
@@ -180,12 +181,12 @@ module Google
|
|
180
181
|
#
|
181
182
|
# @overload list_approval_requests(request, options = nil)
|
182
183
|
# Pass arguments to `list_approval_requests` via a request object, either of type
|
183
|
-
# {Google::Cloud::AccessApproval::V1::ListApprovalRequestsMessage} or an equivalent Hash.
|
184
|
+
# {::Google::Cloud::AccessApproval::V1::ListApprovalRequestsMessage} or an equivalent Hash.
|
184
185
|
#
|
185
|
-
# @param request [Google::Cloud::AccessApproval::V1::ListApprovalRequestsMessage, Hash]
|
186
|
+
# @param request [::Google::Cloud::AccessApproval::V1::ListApprovalRequestsMessage, ::Hash]
|
186
187
|
# A request object representing the call parameters. Required. To specify no
|
187
188
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
188
|
-
# @param options [Gapic::CallOptions, Hash]
|
189
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
189
190
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
190
191
|
#
|
191
192
|
# @overload list_approval_requests(parent: nil, filter: nil, page_size: nil, page_token: nil)
|
@@ -193,10 +194,10 @@ module Google
|
|
193
194
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
194
195
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
195
196
|
#
|
196
|
-
# @param parent [String]
|
197
|
+
# @param parent [::String]
|
197
198
|
# The parent resource. This may be "projects/\\{project_id}",
|
198
199
|
# "folders/\\{folder_id}", or "organizations/\\{organization_id}".
|
199
|
-
# @param filter [String]
|
200
|
+
# @param filter [::String]
|
200
201
|
# A filter on the type of approval requests to retrieve. Must be one of the
|
201
202
|
# following values:
|
202
203
|
# <ol>
|
@@ -206,32 +207,32 @@ module Google
|
|
206
207
|
# <li>ACTIVE: Only active (i.e. currently approved) requests.</li>
|
207
208
|
# <li>DISMISSED: Only dismissed (including expired) requests.</li>
|
208
209
|
# </ol>
|
209
|
-
# @param page_size [Integer]
|
210
|
+
# @param page_size [::Integer]
|
210
211
|
# Requested page size.
|
211
|
-
# @param page_token [String]
|
212
|
+
# @param page_token [::String]
|
212
213
|
# A token identifying the page of results to return.
|
213
214
|
#
|
214
215
|
# @yield [response, operation] Access the result along with the RPC operation
|
215
|
-
# @yieldparam response [Gapic::PagedEnumerable
|
216
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
216
|
+
# @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::AccessApproval::V1::ApprovalRequest>]
|
217
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
217
218
|
#
|
218
|
-
# @return [Gapic::PagedEnumerable
|
219
|
+
# @return [::Gapic::PagedEnumerable<::Google::Cloud::AccessApproval::V1::ApprovalRequest>]
|
219
220
|
#
|
220
|
-
# @raise [Google::Cloud::Error] if the RPC is aborted.
|
221
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
221
222
|
#
|
222
223
|
def list_approval_requests request, options = nil
|
223
|
-
raise ArgumentError, "request must be provided" if request.nil?
|
224
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
224
225
|
|
225
|
-
request = Gapic::Protobuf.coerce request, to: Google::Cloud::AccessApproval::V1::ListApprovalRequestsMessage
|
226
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AccessApproval::V1::ListApprovalRequestsMessage
|
226
227
|
|
227
228
|
# Converts hash and nil to an options object
|
228
|
-
options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
229
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
229
230
|
|
230
231
|
# Customize the options with defaults
|
231
232
|
metadata = @config.rpcs.list_approval_requests.metadata.to_h
|
232
233
|
|
233
234
|
# Set x-goog-api-client and x-goog-user-project headers
|
234
|
-
metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
|
235
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
235
236
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
236
237
|
gapic_version: ::Google::Cloud::AccessApproval::V1::VERSION
|
237
238
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
@@ -249,12 +250,12 @@ module Google
|
|
249
250
|
retry_policy: @config.retry_policy
|
250
251
|
|
251
252
|
@access_approval_stub.call_rpc :list_approval_requests, request, options: options do |response, operation|
|
252
|
-
response = Gapic::PagedEnumerable.new @access_approval_stub, :list_approval_requests, request, response, operation, options
|
253
|
+
response = ::Gapic::PagedEnumerable.new @access_approval_stub, :list_approval_requests, request, response, operation, options
|
253
254
|
yield response, operation if block_given?
|
254
255
|
return response
|
255
256
|
end
|
256
|
-
rescue GRPC::BadStatus => e
|
257
|
-
raise Google::Cloud::Error.from_error(e)
|
257
|
+
rescue ::GRPC::BadStatus => e
|
258
|
+
raise ::Google::Cloud::Error.from_error(e)
|
258
259
|
end
|
259
260
|
|
260
261
|
##
|
@@ -262,12 +263,12 @@ module Google
|
|
262
263
|
#
|
263
264
|
# @overload get_approval_request(request, options = nil)
|
264
265
|
# Pass arguments to `get_approval_request` via a request object, either of type
|
265
|
-
# {Google::Cloud::AccessApproval::V1::GetApprovalRequestMessage} or an equivalent Hash.
|
266
|
+
# {::Google::Cloud::AccessApproval::V1::GetApprovalRequestMessage} or an equivalent Hash.
|
266
267
|
#
|
267
|
-
# @param request [Google::Cloud::AccessApproval::V1::GetApprovalRequestMessage, Hash]
|
268
|
+
# @param request [::Google::Cloud::AccessApproval::V1::GetApprovalRequestMessage, ::Hash]
|
268
269
|
# A request object representing the call parameters. Required. To specify no
|
269
270
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
270
|
-
# @param options [Gapic::CallOptions, Hash]
|
271
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
271
272
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
272
273
|
#
|
273
274
|
# @overload get_approval_request(name: nil)
|
@@ -275,30 +276,30 @@ module Google
|
|
275
276
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
276
277
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
277
278
|
#
|
278
|
-
# @param name [String]
|
279
|
+
# @param name [::String]
|
279
280
|
# Name of the approval request to retrieve.
|
280
281
|
#
|
281
282
|
# @yield [response, operation] Access the result along with the RPC operation
|
282
|
-
# @yieldparam response [Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
283
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
283
|
+
# @yieldparam response [::Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
284
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
284
285
|
#
|
285
|
-
# @return [Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
286
|
+
# @return [::Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
286
287
|
#
|
287
|
-
# @raise [Google::Cloud::Error] if the RPC is aborted.
|
288
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
288
289
|
#
|
289
290
|
def get_approval_request request, options = nil
|
290
|
-
raise ArgumentError, "request must be provided" if request.nil?
|
291
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
291
292
|
|
292
|
-
request = Gapic::Protobuf.coerce request, to: Google::Cloud::AccessApproval::V1::GetApprovalRequestMessage
|
293
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AccessApproval::V1::GetApprovalRequestMessage
|
293
294
|
|
294
295
|
# Converts hash and nil to an options object
|
295
|
-
options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
296
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
296
297
|
|
297
298
|
# Customize the options with defaults
|
298
299
|
metadata = @config.rpcs.get_approval_request.metadata.to_h
|
299
300
|
|
300
301
|
# Set x-goog-api-client and x-goog-user-project headers
|
301
|
-
metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
|
302
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
302
303
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
303
304
|
gapic_version: ::Google::Cloud::AccessApproval::V1::VERSION
|
304
305
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
@@ -319,8 +320,8 @@ module Google
|
|
319
320
|
yield response, operation if block_given?
|
320
321
|
return response
|
321
322
|
end
|
322
|
-
rescue GRPC::BadStatus => e
|
323
|
-
raise Google::Cloud::Error.from_error(e)
|
323
|
+
rescue ::GRPC::BadStatus => e
|
324
|
+
raise ::Google::Cloud::Error.from_error(e)
|
324
325
|
end
|
325
326
|
|
326
327
|
##
|
@@ -331,12 +332,12 @@ module Google
|
|
331
332
|
#
|
332
333
|
# @overload approve_approval_request(request, options = nil)
|
333
334
|
# Pass arguments to `approve_approval_request` via a request object, either of type
|
334
|
-
# {Google::Cloud::AccessApproval::V1::ApproveApprovalRequestMessage} or an equivalent Hash.
|
335
|
+
# {::Google::Cloud::AccessApproval::V1::ApproveApprovalRequestMessage} or an equivalent Hash.
|
335
336
|
#
|
336
|
-
# @param request [Google::Cloud::AccessApproval::V1::ApproveApprovalRequestMessage, Hash]
|
337
|
+
# @param request [::Google::Cloud::AccessApproval::V1::ApproveApprovalRequestMessage, ::Hash]
|
337
338
|
# A request object representing the call parameters. Required. To specify no
|
338
339
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
339
|
-
# @param options [Gapic::CallOptions, Hash]
|
340
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
340
341
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
341
342
|
#
|
342
343
|
# @overload approve_approval_request(name: nil, expire_time: nil)
|
@@ -344,32 +345,32 @@ module Google
|
|
344
345
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
345
346
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
346
347
|
#
|
347
|
-
# @param name [String]
|
348
|
+
# @param name [::String]
|
348
349
|
# Name of the approval request to approve.
|
349
|
-
# @param expire_time [Google::Protobuf::Timestamp, Hash]
|
350
|
+
# @param expire_time [::Google::Protobuf::Timestamp, ::Hash]
|
350
351
|
# The expiration time of this approval.
|
351
352
|
#
|
352
353
|
# @yield [response, operation] Access the result along with the RPC operation
|
353
|
-
# @yieldparam response [Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
354
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
354
|
+
# @yieldparam response [::Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
355
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
355
356
|
#
|
356
|
-
# @return [Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
357
|
+
# @return [::Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
357
358
|
#
|
358
|
-
# @raise [Google::Cloud::Error] if the RPC is aborted.
|
359
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
359
360
|
#
|
360
361
|
def approve_approval_request request, options = nil
|
361
|
-
raise ArgumentError, "request must be provided" if request.nil?
|
362
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
362
363
|
|
363
|
-
request = Gapic::Protobuf.coerce request, to: Google::Cloud::AccessApproval::V1::ApproveApprovalRequestMessage
|
364
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AccessApproval::V1::ApproveApprovalRequestMessage
|
364
365
|
|
365
366
|
# Converts hash and nil to an options object
|
366
|
-
options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
367
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
367
368
|
|
368
369
|
# Customize the options with defaults
|
369
370
|
metadata = @config.rpcs.approve_approval_request.metadata.to_h
|
370
371
|
|
371
372
|
# Set x-goog-api-client and x-goog-user-project headers
|
372
|
-
metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
|
373
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
373
374
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
374
375
|
gapic_version: ::Google::Cloud::AccessApproval::V1::VERSION
|
375
376
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
@@ -390,8 +391,8 @@ module Google
|
|
390
391
|
yield response, operation if block_given?
|
391
392
|
return response
|
392
393
|
end
|
393
|
-
rescue GRPC::BadStatus => e
|
394
|
-
raise Google::Cloud::Error.from_error(e)
|
394
|
+
rescue ::GRPC::BadStatus => e
|
395
|
+
raise ::Google::Cloud::Error.from_error(e)
|
395
396
|
end
|
396
397
|
|
397
398
|
##
|
@@ -408,12 +409,12 @@ module Google
|
|
408
409
|
#
|
409
410
|
# @overload dismiss_approval_request(request, options = nil)
|
410
411
|
# Pass arguments to `dismiss_approval_request` via a request object, either of type
|
411
|
-
# {Google::Cloud::AccessApproval::V1::DismissApprovalRequestMessage} or an equivalent Hash.
|
412
|
+
# {::Google::Cloud::AccessApproval::V1::DismissApprovalRequestMessage} or an equivalent Hash.
|
412
413
|
#
|
413
|
-
# @param request [Google::Cloud::AccessApproval::V1::DismissApprovalRequestMessage, Hash]
|
414
|
+
# @param request [::Google::Cloud::AccessApproval::V1::DismissApprovalRequestMessage, ::Hash]
|
414
415
|
# A request object representing the call parameters. Required. To specify no
|
415
416
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
416
|
-
# @param options [Gapic::CallOptions, Hash]
|
417
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
417
418
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
418
419
|
#
|
419
420
|
# @overload dismiss_approval_request(name: nil)
|
@@ -421,30 +422,30 @@ module Google
|
|
421
422
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
422
423
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
423
424
|
#
|
424
|
-
# @param name [String]
|
425
|
+
# @param name [::String]
|
425
426
|
# Name of the ApprovalRequest to dismiss.
|
426
427
|
#
|
427
428
|
# @yield [response, operation] Access the result along with the RPC operation
|
428
|
-
# @yieldparam response [Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
429
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
429
|
+
# @yieldparam response [::Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
430
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
430
431
|
#
|
431
|
-
# @return [Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
432
|
+
# @return [::Google::Cloud::AccessApproval::V1::ApprovalRequest]
|
432
433
|
#
|
433
|
-
# @raise [Google::Cloud::Error] if the RPC is aborted.
|
434
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
434
435
|
#
|
435
436
|
def dismiss_approval_request request, options = nil
|
436
|
-
raise ArgumentError, "request must be provided" if request.nil?
|
437
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
437
438
|
|
438
|
-
request = Gapic::Protobuf.coerce request, to: Google::Cloud::AccessApproval::V1::DismissApprovalRequestMessage
|
439
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AccessApproval::V1::DismissApprovalRequestMessage
|
439
440
|
|
440
441
|
# Converts hash and nil to an options object
|
441
|
-
options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
442
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
442
443
|
|
443
444
|
# Customize the options with defaults
|
444
445
|
metadata = @config.rpcs.dismiss_approval_request.metadata.to_h
|
445
446
|
|
446
447
|
# Set x-goog-api-client and x-goog-user-project headers
|
447
|
-
metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
|
448
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
448
449
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
449
450
|
gapic_version: ::Google::Cloud::AccessApproval::V1::VERSION
|
450
451
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
@@ -465,8 +466,8 @@ module Google
|
|
465
466
|
yield response, operation if block_given?
|
466
467
|
return response
|
467
468
|
end
|
468
|
-
rescue GRPC::BadStatus => e
|
469
|
-
raise Google::Cloud::Error.from_error(e)
|
469
|
+
rescue ::GRPC::BadStatus => e
|
470
|
+
raise ::Google::Cloud::Error.from_error(e)
|
470
471
|
end
|
471
472
|
|
472
473
|
##
|
@@ -474,12 +475,12 @@ module Google
|
|
474
475
|
#
|
475
476
|
# @overload get_access_approval_settings(request, options = nil)
|
476
477
|
# Pass arguments to `get_access_approval_settings` via a request object, either of type
|
477
|
-
# {Google::Cloud::AccessApproval::V1::GetAccessApprovalSettingsMessage} or an equivalent Hash.
|
478
|
+
# {::Google::Cloud::AccessApproval::V1::GetAccessApprovalSettingsMessage} or an equivalent Hash.
|
478
479
|
#
|
479
|
-
# @param request [Google::Cloud::AccessApproval::V1::GetAccessApprovalSettingsMessage, Hash]
|
480
|
+
# @param request [::Google::Cloud::AccessApproval::V1::GetAccessApprovalSettingsMessage, ::Hash]
|
480
481
|
# A request object representing the call parameters. Required. To specify no
|
481
482
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
482
|
-
# @param options [Gapic::CallOptions, Hash]
|
483
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
483
484
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
484
485
|
#
|
485
486
|
# @overload get_access_approval_settings(name: nil)
|
@@ -487,30 +488,30 @@ module Google
|
|
487
488
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
488
489
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
489
490
|
#
|
490
|
-
# @param name [String]
|
491
|
+
# @param name [::String]
|
491
492
|
# Name of the AccessApprovalSettings to retrieve.
|
492
493
|
#
|
493
494
|
# @yield [response, operation] Access the result along with the RPC operation
|
494
|
-
# @yieldparam response [Google::Cloud::AccessApproval::V1::AccessApprovalSettings]
|
495
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
495
|
+
# @yieldparam response [::Google::Cloud::AccessApproval::V1::AccessApprovalSettings]
|
496
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
496
497
|
#
|
497
|
-
# @return [Google::Cloud::AccessApproval::V1::AccessApprovalSettings]
|
498
|
+
# @return [::Google::Cloud::AccessApproval::V1::AccessApprovalSettings]
|
498
499
|
#
|
499
|
-
# @raise [Google::Cloud::Error] if the RPC is aborted.
|
500
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
500
501
|
#
|
501
502
|
def get_access_approval_settings request, options = nil
|
502
|
-
raise ArgumentError, "request must be provided" if request.nil?
|
503
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
503
504
|
|
504
|
-
request = Gapic::Protobuf.coerce request, to: Google::Cloud::AccessApproval::V1::GetAccessApprovalSettingsMessage
|
505
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AccessApproval::V1::GetAccessApprovalSettingsMessage
|
505
506
|
|
506
507
|
# Converts hash and nil to an options object
|
507
|
-
options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
508
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
508
509
|
|
509
510
|
# Customize the options with defaults
|
510
511
|
metadata = @config.rpcs.get_access_approval_settings.metadata.to_h
|
511
512
|
|
512
513
|
# Set x-goog-api-client and x-goog-user-project headers
|
513
|
-
metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
|
514
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
514
515
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
515
516
|
gapic_version: ::Google::Cloud::AccessApproval::V1::VERSION
|
516
517
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
@@ -531,8 +532,8 @@ module Google
|
|
531
532
|
yield response, operation if block_given?
|
532
533
|
return response
|
533
534
|
end
|
534
|
-
rescue GRPC::BadStatus => e
|
535
|
-
raise Google::Cloud::Error.from_error(e)
|
535
|
+
rescue ::GRPC::BadStatus => e
|
536
|
+
raise ::Google::Cloud::Error.from_error(e)
|
536
537
|
end
|
537
538
|
|
538
539
|
##
|
@@ -541,12 +542,12 @@ module Google
|
|
541
542
|
#
|
542
543
|
# @overload update_access_approval_settings(request, options = nil)
|
543
544
|
# Pass arguments to `update_access_approval_settings` via a request object, either of type
|
544
|
-
# {Google::Cloud::AccessApproval::V1::UpdateAccessApprovalSettingsMessage} or an equivalent Hash.
|
545
|
+
# {::Google::Cloud::AccessApproval::V1::UpdateAccessApprovalSettingsMessage} or an equivalent Hash.
|
545
546
|
#
|
546
|
-
# @param request [Google::Cloud::AccessApproval::V1::UpdateAccessApprovalSettingsMessage, Hash]
|
547
|
+
# @param request [::Google::Cloud::AccessApproval::V1::UpdateAccessApprovalSettingsMessage, ::Hash]
|
547
548
|
# A request object representing the call parameters. Required. To specify no
|
548
549
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
549
|
-
# @param options [Gapic::CallOptions, Hash]
|
550
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
550
551
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
551
552
|
#
|
552
553
|
# @overload update_access_approval_settings(settings: nil, update_mask: nil)
|
@@ -554,9 +555,9 @@ module Google
|
|
554
555
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
555
556
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
556
557
|
#
|
557
|
-
# @param settings [Google::Cloud::AccessApproval::V1::AccessApprovalSettings, Hash]
|
558
|
+
# @param settings [::Google::Cloud::AccessApproval::V1::AccessApprovalSettings, ::Hash]
|
558
559
|
# The new AccessApprovalSettings.
|
559
|
-
# @param update_mask [Google::Protobuf::FieldMask, Hash]
|
560
|
+
# @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
|
560
561
|
# The update mask applies to the settings. Only the top level fields of
|
561
562
|
# AccessApprovalSettings (notification_emails & enrolled_services) are
|
562
563
|
# supported. For each field, if it is included, the currently stored value
|
@@ -569,26 +570,26 @@ module Google
|
|
569
570
|
# updated.
|
570
571
|
#
|
571
572
|
# @yield [response, operation] Access the result along with the RPC operation
|
572
|
-
# @yieldparam response [Google::Cloud::AccessApproval::V1::AccessApprovalSettings]
|
573
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
573
|
+
# @yieldparam response [::Google::Cloud::AccessApproval::V1::AccessApprovalSettings]
|
574
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
574
575
|
#
|
575
|
-
# @return [Google::Cloud::AccessApproval::V1::AccessApprovalSettings]
|
576
|
+
# @return [::Google::Cloud::AccessApproval::V1::AccessApprovalSettings]
|
576
577
|
#
|
577
|
-
# @raise [Google::Cloud::Error] if the RPC is aborted.
|
578
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
578
579
|
#
|
579
580
|
def update_access_approval_settings request, options = nil
|
580
|
-
raise ArgumentError, "request must be provided" if request.nil?
|
581
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
581
582
|
|
582
|
-
request = Gapic::Protobuf.coerce request, to: Google::Cloud::AccessApproval::V1::UpdateAccessApprovalSettingsMessage
|
583
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AccessApproval::V1::UpdateAccessApprovalSettingsMessage
|
583
584
|
|
584
585
|
# Converts hash and nil to an options object
|
585
|
-
options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
586
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
586
587
|
|
587
588
|
# Customize the options with defaults
|
588
589
|
metadata = @config.rpcs.update_access_approval_settings.metadata.to_h
|
589
590
|
|
590
591
|
# Set x-goog-api-client and x-goog-user-project headers
|
591
|
-
metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
|
592
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
592
593
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
593
594
|
gapic_version: ::Google::Cloud::AccessApproval::V1::VERSION
|
594
595
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
@@ -609,8 +610,8 @@ module Google
|
|
609
610
|
yield response, operation if block_given?
|
610
611
|
return response
|
611
612
|
end
|
612
|
-
rescue GRPC::BadStatus => e
|
613
|
-
raise Google::Cloud::Error.from_error(e)
|
613
|
+
rescue ::GRPC::BadStatus => e
|
614
|
+
raise ::Google::Cloud::Error.from_error(e)
|
614
615
|
end
|
615
616
|
|
616
617
|
##
|
@@ -623,12 +624,12 @@ module Google
|
|
623
624
|
#
|
624
625
|
# @overload delete_access_approval_settings(request, options = nil)
|
625
626
|
# Pass arguments to `delete_access_approval_settings` via a request object, either of type
|
626
|
-
# {Google::Cloud::AccessApproval::V1::DeleteAccessApprovalSettingsMessage} or an equivalent Hash.
|
627
|
+
# {::Google::Cloud::AccessApproval::V1::DeleteAccessApprovalSettingsMessage} or an equivalent Hash.
|
627
628
|
#
|
628
|
-
# @param request [Google::Cloud::AccessApproval::V1::DeleteAccessApprovalSettingsMessage, Hash]
|
629
|
+
# @param request [::Google::Cloud::AccessApproval::V1::DeleteAccessApprovalSettingsMessage, ::Hash]
|
629
630
|
# A request object representing the call parameters. Required. To specify no
|
630
631
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
631
|
-
# @param options [Gapic::CallOptions, Hash]
|
632
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
632
633
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
633
634
|
#
|
634
635
|
# @overload delete_access_approval_settings(name: nil)
|
@@ -636,30 +637,30 @@ module Google
|
|
636
637
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
637
638
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
638
639
|
#
|
639
|
-
# @param name [String]
|
640
|
+
# @param name [::String]
|
640
641
|
# Name of the AccessApprovalSettings to delete.
|
641
642
|
#
|
642
643
|
# @yield [response, operation] Access the result along with the RPC operation
|
643
|
-
# @yieldparam response [Google::Protobuf::Empty]
|
644
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
644
|
+
# @yieldparam response [::Google::Protobuf::Empty]
|
645
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
645
646
|
#
|
646
|
-
# @return [Google::Protobuf::Empty]
|
647
|
+
# @return [::Google::Protobuf::Empty]
|
647
648
|
#
|
648
|
-
# @raise [Google::Cloud::Error] if the RPC is aborted.
|
649
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
649
650
|
#
|
650
651
|
def delete_access_approval_settings request, options = nil
|
651
|
-
raise ArgumentError, "request must be provided" if request.nil?
|
652
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
652
653
|
|
653
|
-
request = Gapic::Protobuf.coerce request, to: Google::Cloud::AccessApproval::V1::DeleteAccessApprovalSettingsMessage
|
654
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AccessApproval::V1::DeleteAccessApprovalSettingsMessage
|
654
655
|
|
655
656
|
# Converts hash and nil to an options object
|
656
|
-
options = Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
657
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
657
658
|
|
658
659
|
# Customize the options with defaults
|
659
660
|
metadata = @config.rpcs.delete_access_approval_settings.metadata.to_h
|
660
661
|
|
661
662
|
# Set x-goog-api-client and x-goog-user-project headers
|
662
|
-
metadata[:"x-goog-api-client"] ||= Gapic::Headers.x_goog_api_client \
|
663
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
663
664
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
664
665
|
gapic_version: ::Google::Cloud::AccessApproval::V1::VERSION
|
665
666
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
@@ -680,8 +681,8 @@ module Google
|
|
680
681
|
yield response, operation if block_given?
|
681
682
|
return response
|
682
683
|
end
|
683
|
-
rescue GRPC::BadStatus => e
|
684
|
-
raise Google::Cloud::Error.from_error(e)
|
684
|
+
rescue ::GRPC::BadStatus => e
|
685
|
+
raise ::Google::Cloud::Error.from_error(e)
|
685
686
|
end
|
686
687
|
|
687
688
|
##
|
@@ -691,7 +692,7 @@ module Google
|
|
691
692
|
# providing control over timeouts, retry behavior, logging, transport
|
692
693
|
# parameters, and other low-level controls. Certain parameters can also be
|
693
694
|
# applied individually to specific RPCs. See
|
694
|
-
# {Google::Cloud::AccessApproval::V1::AccessApproval::Client::Configuration::Rpcs}
|
695
|
+
# {::Google::Cloud::AccessApproval::V1::AccessApproval::Client::Configuration::Rpcs}
|
695
696
|
# for a list of RPCs that can be configured independently.
|
696
697
|
#
|
697
698
|
# Configuration can be applied globally to all clients, or to a single client
|
@@ -702,22 +703,22 @@ module Google
|
|
702
703
|
# To modify the global config, setting the timeout for list_approval_requests
|
703
704
|
# to 20 seconds, and all remaining timeouts to 10 seconds:
|
704
705
|
#
|
705
|
-
# Google::Cloud::AccessApproval::V1::AccessApproval::Client.configure do |config|
|
706
|
-
# config.timeout =
|
707
|
-
# config.rpcs.list_approval_requests.timeout =
|
706
|
+
# ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.configure do |config|
|
707
|
+
# config.timeout = 10.0
|
708
|
+
# config.rpcs.list_approval_requests.timeout = 20.0
|
708
709
|
# end
|
709
710
|
#
|
710
711
|
# To apply the above configuration only to a new client:
|
711
712
|
#
|
712
|
-
# client = Google::Cloud::AccessApproval::V1::AccessApproval::Client.new do |config|
|
713
|
-
# config.timeout =
|
714
|
-
# config.rpcs.list_approval_requests.timeout =
|
713
|
+
# client = ::Google::Cloud::AccessApproval::V1::AccessApproval::Client.new do |config|
|
714
|
+
# config.timeout = 10.0
|
715
|
+
# config.rpcs.list_approval_requests.timeout = 20.0
|
715
716
|
# end
|
716
717
|
#
|
717
718
|
# @!attribute [rw] endpoint
|
718
719
|
# The hostname or hostname:port of the service endpoint.
|
719
720
|
# Defaults to `"accessapproval.googleapis.com"`.
|
720
|
-
# @return [String]
|
721
|
+
# @return [::String]
|
721
722
|
# @!attribute [rw] credentials
|
722
723
|
# Credentials to send with calls. You may provide any of the following types:
|
723
724
|
# * (`String`) The path to a service account key file in JSON format
|
@@ -729,29 +730,29 @@ module Google
|
|
729
730
|
# * (`GRPC::Core::Channel`) a gRPC channel with included credentials
|
730
731
|
# * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
|
731
732
|
# * (`nil`) indicating no credentials
|
732
|
-
# @return [Object]
|
733
|
+
# @return [::Object]
|
733
734
|
# @!attribute [rw] scope
|
734
735
|
# The OAuth scopes
|
735
|
-
# @return [Array
|
736
|
+
# @return [::Array<::String>]
|
736
737
|
# @!attribute [rw] lib_name
|
737
738
|
# The library name as recorded in instrumentation and logging
|
738
|
-
# @return [String]
|
739
|
+
# @return [::String]
|
739
740
|
# @!attribute [rw] lib_version
|
740
741
|
# The library version as recorded in instrumentation and logging
|
741
|
-
# @return [String]
|
742
|
+
# @return [::String]
|
742
743
|
# @!attribute [rw] channel_args
|
743
744
|
# Extra parameters passed to the gRPC channel. Note: this is ignored if a
|
744
745
|
# `GRPC::Core::Channel` object is provided as the credential.
|
745
|
-
# @return [Hash]
|
746
|
+
# @return [::Hash]
|
746
747
|
# @!attribute [rw] interceptors
|
747
748
|
# An array of interceptors that are run before calls are executed.
|
748
|
-
# @return [Array
|
749
|
+
# @return [::Array<::GRPC::ClientInterceptor>]
|
749
750
|
# @!attribute [rw] timeout
|
750
|
-
# The call timeout in
|
751
|
-
# @return [Numeric]
|
751
|
+
# The call timeout in seconds.
|
752
|
+
# @return [::Numeric]
|
752
753
|
# @!attribute [rw] metadata
|
753
754
|
# Additional gRPC headers to be sent with the call.
|
754
|
-
# @return [Hash{Symbol
|
755
|
+
# @return [::Hash{::Symbol=>::String}]
|
755
756
|
# @!attribute [rw] retry_policy
|
756
757
|
# The retry policy. The value is a hash with the following keys:
|
757
758
|
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
@@ -759,25 +760,29 @@ module Google
|
|
759
760
|
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
760
761
|
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
761
762
|
# trigger a retry.
|
762
|
-
# @return [Hash]
|
763
|
+
# @return [::Hash]
|
764
|
+
# @!attribute [rw] quota_project
|
765
|
+
# A separate project against which to charge quota.
|
766
|
+
# @return [::String]
|
763
767
|
#
|
764
768
|
class Configuration
|
765
|
-
extend Gapic::Config
|
769
|
+
extend ::Gapic::Config
|
766
770
|
|
767
|
-
config_attr :endpoint,
|
768
|
-
config_attr :credentials,
|
771
|
+
config_attr :endpoint, "accessapproval.googleapis.com", ::String
|
772
|
+
config_attr :credentials, nil do |value|
|
769
773
|
allowed = [::String, ::Hash, ::Proc, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
770
774
|
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
771
775
|
allowed.any? { |klass| klass === value }
|
772
776
|
end
|
773
|
-
config_attr :scope,
|
774
|
-
config_attr :lib_name,
|
775
|
-
config_attr :lib_version,
|
776
|
-
config_attr(:channel_args,
|
777
|
-
config_attr :interceptors,
|
778
|
-
config_attr :timeout,
|
779
|
-
config_attr :metadata,
|
780
|
-
config_attr :retry_policy,
|
777
|
+
config_attr :scope, nil, ::String, ::Array, nil
|
778
|
+
config_attr :lib_name, nil, ::String, nil
|
779
|
+
config_attr :lib_version, nil, ::String, nil
|
780
|
+
config_attr(:channel_args, { "grpc.service_config_disable_resolution"=>1 }, ::Hash, nil)
|
781
|
+
config_attr :interceptors, nil, ::Array, nil
|
782
|
+
config_attr :timeout, nil, ::Numeric, nil
|
783
|
+
config_attr :metadata, nil, ::Hash, nil
|
784
|
+
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
785
|
+
config_attr :quota_project, nil, ::String, nil
|
781
786
|
|
782
787
|
# @private
|
783
788
|
def initialize parent_config = nil
|
@@ -793,7 +798,7 @@ module Google
|
|
793
798
|
def rpcs
|
794
799
|
@rpcs ||= begin
|
795
800
|
parent_rpcs = nil
|
796
|
-
parent_rpcs = @parent_config.rpcs if @parent_config&.respond_to?
|
801
|
+
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config&.respond_to?(:rpcs)
|
797
802
|
Rpcs.new parent_rpcs
|
798
803
|
end
|
799
804
|
end
|
@@ -818,56 +823,56 @@ module Google
|
|
818
823
|
class Rpcs
|
819
824
|
##
|
820
825
|
# RPC-specific configuration for `list_approval_requests`
|
821
|
-
# @return [Gapic::Config::Method]
|
826
|
+
# @return [::Gapic::Config::Method]
|
822
827
|
#
|
823
828
|
attr_reader :list_approval_requests
|
824
829
|
##
|
825
830
|
# RPC-specific configuration for `get_approval_request`
|
826
|
-
# @return [Gapic::Config::Method]
|
831
|
+
# @return [::Gapic::Config::Method]
|
827
832
|
#
|
828
833
|
attr_reader :get_approval_request
|
829
834
|
##
|
830
835
|
# RPC-specific configuration for `approve_approval_request`
|
831
|
-
# @return [Gapic::Config::Method]
|
836
|
+
# @return [::Gapic::Config::Method]
|
832
837
|
#
|
833
838
|
attr_reader :approve_approval_request
|
834
839
|
##
|
835
840
|
# RPC-specific configuration for `dismiss_approval_request`
|
836
|
-
# @return [Gapic::Config::Method]
|
841
|
+
# @return [::Gapic::Config::Method]
|
837
842
|
#
|
838
843
|
attr_reader :dismiss_approval_request
|
839
844
|
##
|
840
845
|
# RPC-specific configuration for `get_access_approval_settings`
|
841
|
-
# @return [Gapic::Config::Method]
|
846
|
+
# @return [::Gapic::Config::Method]
|
842
847
|
#
|
843
848
|
attr_reader :get_access_approval_settings
|
844
849
|
##
|
845
850
|
# RPC-specific configuration for `update_access_approval_settings`
|
846
|
-
# @return [Gapic::Config::Method]
|
851
|
+
# @return [::Gapic::Config::Method]
|
847
852
|
#
|
848
853
|
attr_reader :update_access_approval_settings
|
849
854
|
##
|
850
855
|
# RPC-specific configuration for `delete_access_approval_settings`
|
851
|
-
# @return [Gapic::Config::Method]
|
856
|
+
# @return [::Gapic::Config::Method]
|
852
857
|
#
|
853
858
|
attr_reader :delete_access_approval_settings
|
854
859
|
|
855
860
|
# @private
|
856
861
|
def initialize parent_rpcs = nil
|
857
862
|
list_approval_requests_config = parent_rpcs&.list_approval_requests if parent_rpcs&.respond_to? :list_approval_requests
|
858
|
-
@list_approval_requests = Gapic::Config::Method.new list_approval_requests_config
|
863
|
+
@list_approval_requests = ::Gapic::Config::Method.new list_approval_requests_config
|
859
864
|
get_approval_request_config = parent_rpcs&.get_approval_request if parent_rpcs&.respond_to? :get_approval_request
|
860
|
-
@get_approval_request = Gapic::Config::Method.new get_approval_request_config
|
865
|
+
@get_approval_request = ::Gapic::Config::Method.new get_approval_request_config
|
861
866
|
approve_approval_request_config = parent_rpcs&.approve_approval_request if parent_rpcs&.respond_to? :approve_approval_request
|
862
|
-
@approve_approval_request = Gapic::Config::Method.new approve_approval_request_config
|
867
|
+
@approve_approval_request = ::Gapic::Config::Method.new approve_approval_request_config
|
863
868
|
dismiss_approval_request_config = parent_rpcs&.dismiss_approval_request if parent_rpcs&.respond_to? :dismiss_approval_request
|
864
|
-
@dismiss_approval_request = Gapic::Config::Method.new dismiss_approval_request_config
|
869
|
+
@dismiss_approval_request = ::Gapic::Config::Method.new dismiss_approval_request_config
|
865
870
|
get_access_approval_settings_config = parent_rpcs&.get_access_approval_settings if parent_rpcs&.respond_to? :get_access_approval_settings
|
866
|
-
@get_access_approval_settings = Gapic::Config::Method.new get_access_approval_settings_config
|
871
|
+
@get_access_approval_settings = ::Gapic::Config::Method.new get_access_approval_settings_config
|
867
872
|
update_access_approval_settings_config = parent_rpcs&.update_access_approval_settings if parent_rpcs&.respond_to? :update_access_approval_settings
|
868
|
-
@update_access_approval_settings = Gapic::Config::Method.new update_access_approval_settings_config
|
873
|
+
@update_access_approval_settings = ::Gapic::Config::Method.new update_access_approval_settings_config
|
869
874
|
delete_access_approval_settings_config = parent_rpcs&.delete_access_approval_settings if parent_rpcs&.respond_to? :delete_access_approval_settings
|
870
|
-
@delete_access_approval_settings = Gapic::Config::Method.new delete_access_approval_settings_config
|
875
|
+
@delete_access_approval_settings = ::Gapic::Config::Method.new delete_access_approval_settings_config
|
871
876
|
|
872
877
|
yield self if block_given?
|
873
878
|
end
|