google-cloud-privileged_access_manager-v1 0.a → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.yardopts +12 -0
- data/AUTHENTICATION.md +122 -0
- data/README.md +144 -8
- data/lib/google/cloud/privileged_access_manager/v1/bindings_override.rb +134 -0
- data/lib/google/cloud/privileged_access_manager/v1/privileged_access_manager/client.rb +1895 -0
- data/lib/google/cloud/privileged_access_manager/v1/privileged_access_manager/credentials.rb +47 -0
- data/lib/google/cloud/privileged_access_manager/v1/privileged_access_manager/operations.rb +809 -0
- data/lib/google/cloud/privileged_access_manager/v1/privileged_access_manager/paths.rb +206 -0
- data/lib/google/cloud/privileged_access_manager/v1/privileged_access_manager/rest/client.rb +1777 -0
- data/lib/google/cloud/privileged_access_manager/v1/privileged_access_manager/rest/operations.rb +944 -0
- data/lib/google/cloud/privileged_access_manager/v1/privileged_access_manager/rest/service_stub.rb +1109 -0
- data/lib/google/cloud/privileged_access_manager/v1/privileged_access_manager/rest.rb +73 -0
- data/lib/google/cloud/privileged_access_manager/v1/privileged_access_manager.rb +75 -0
- data/lib/google/cloud/privileged_access_manager/v1/rest.rb +38 -0
- data/lib/google/cloud/privileged_access_manager/v1/version.rb +7 -2
- data/lib/google/cloud/privileged_access_manager/v1.rb +45 -0
- data/lib/google/cloud/privilegedaccessmanager/v1/privilegedaccessmanager_pb.rb +108 -0
- data/lib/google/cloud/privilegedaccessmanager/v1/privilegedaccessmanager_services_pb.rb +121 -0
- data/lib/google-cloud-privileged_access_manager-v1.rb +21 -0
- data/proto_docs/README.md +4 -0
- data/proto_docs/google/api/client.rb +403 -0
- data/proto_docs/google/api/field_behavior.rb +85 -0
- data/proto_docs/google/api/launch_stage.rb +71 -0
- data/proto_docs/google/api/resource.rb +227 -0
- data/proto_docs/google/cloud/privilegedaccessmanager/v1/privilegedaccessmanager.rb +966 -0
- data/proto_docs/google/longrunning/operations.rb +164 -0
- data/proto_docs/google/protobuf/any.rb +145 -0
- data/proto_docs/google/protobuf/duration.rb +98 -0
- data/proto_docs/google/protobuf/empty.rb +34 -0
- data/proto_docs/google/protobuf/field_mask.rb +229 -0
- data/proto_docs/google/protobuf/timestamp.rb +127 -0
- data/proto_docs/google/rpc/status.rb +48 -0
- metadata +125 -10
@@ -0,0 +1,206 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2024 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
|
20
|
+
module Google
|
21
|
+
module Cloud
|
22
|
+
module PrivilegedAccessManager
|
23
|
+
module V1
|
24
|
+
module PrivilegedAccessManager
|
25
|
+
# Path helper methods for the PrivilegedAccessManager API.
|
26
|
+
module Paths
|
27
|
+
##
|
28
|
+
# Create a fully-qualified Entitlement resource string.
|
29
|
+
#
|
30
|
+
# @overload entitlement_path(project:, location:, entitlement:)
|
31
|
+
# The resource will be in the following format:
|
32
|
+
#
|
33
|
+
# `projects/{project}/locations/{location}/entitlements/{entitlement}`
|
34
|
+
#
|
35
|
+
# @param project [String]
|
36
|
+
# @param location [String]
|
37
|
+
# @param entitlement [String]
|
38
|
+
#
|
39
|
+
# @overload entitlement_path(folder:, location:, entitlement:)
|
40
|
+
# The resource will be in the following format:
|
41
|
+
#
|
42
|
+
# `folders/{folder}/locations/{location}/entitlements/{entitlement}`
|
43
|
+
#
|
44
|
+
# @param folder [String]
|
45
|
+
# @param location [String]
|
46
|
+
# @param entitlement [String]
|
47
|
+
#
|
48
|
+
# @overload entitlement_path(organization:, location:, entitlement:)
|
49
|
+
# The resource will be in the following format:
|
50
|
+
#
|
51
|
+
# `organizations/{organization}/locations/{location}/entitlements/{entitlement}`
|
52
|
+
#
|
53
|
+
# @param organization [String]
|
54
|
+
# @param location [String]
|
55
|
+
# @param entitlement [String]
|
56
|
+
#
|
57
|
+
# @return [::String]
|
58
|
+
def entitlement_path **args
|
59
|
+
resources = {
|
60
|
+
"entitlement:location:project" => (proc do |project:, location:, entitlement:|
|
61
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
62
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
63
|
+
|
64
|
+
"projects/#{project}/locations/#{location}/entitlements/#{entitlement}"
|
65
|
+
end),
|
66
|
+
"entitlement:folder:location" => (proc do |folder:, location:, entitlement:|
|
67
|
+
raise ::ArgumentError, "folder cannot contain /" if folder.to_s.include? "/"
|
68
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
69
|
+
|
70
|
+
"folders/#{folder}/locations/#{location}/entitlements/#{entitlement}"
|
71
|
+
end),
|
72
|
+
"entitlement:location:organization" => (proc do |organization:, location:, entitlement:|
|
73
|
+
raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/"
|
74
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
75
|
+
|
76
|
+
"organizations/#{organization}/locations/#{location}/entitlements/#{entitlement}"
|
77
|
+
end)
|
78
|
+
}
|
79
|
+
|
80
|
+
resource = resources[args.keys.sort.join(":")]
|
81
|
+
raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil?
|
82
|
+
resource.call(**args)
|
83
|
+
end
|
84
|
+
|
85
|
+
##
|
86
|
+
# Create a fully-qualified FolderLocation resource string.
|
87
|
+
#
|
88
|
+
# The resource will be in the following format:
|
89
|
+
#
|
90
|
+
# `folders/{folder}/locations/{location}`
|
91
|
+
#
|
92
|
+
# @param folder [String]
|
93
|
+
# @param location [String]
|
94
|
+
#
|
95
|
+
# @return [::String]
|
96
|
+
def folder_location_path folder:, location:
|
97
|
+
raise ::ArgumentError, "folder cannot contain /" if folder.to_s.include? "/"
|
98
|
+
|
99
|
+
"folders/#{folder}/locations/#{location}"
|
100
|
+
end
|
101
|
+
|
102
|
+
##
|
103
|
+
# Create a fully-qualified Grant resource string.
|
104
|
+
#
|
105
|
+
# @overload grant_path(project:, location:, entitlement:, grant:)
|
106
|
+
# The resource will be in the following format:
|
107
|
+
#
|
108
|
+
# `projects/{project}/locations/{location}/entitlements/{entitlement}/grants/{grant}`
|
109
|
+
#
|
110
|
+
# @param project [String]
|
111
|
+
# @param location [String]
|
112
|
+
# @param entitlement [String]
|
113
|
+
# @param grant [String]
|
114
|
+
#
|
115
|
+
# @overload grant_path(folder:, location:, entitlement:, grant:)
|
116
|
+
# The resource will be in the following format:
|
117
|
+
#
|
118
|
+
# `folders/{folder}/locations/{location}/entitlements/{entitlement}/grants/{grant}`
|
119
|
+
#
|
120
|
+
# @param folder [String]
|
121
|
+
# @param location [String]
|
122
|
+
# @param entitlement [String]
|
123
|
+
# @param grant [String]
|
124
|
+
#
|
125
|
+
# @overload grant_path(organization:, location:, entitlement:, grant:)
|
126
|
+
# The resource will be in the following format:
|
127
|
+
#
|
128
|
+
# `organizations/{organization}/locations/{location}/entitlements/{entitlement}/grants/{grant}`
|
129
|
+
#
|
130
|
+
# @param organization [String]
|
131
|
+
# @param location [String]
|
132
|
+
# @param entitlement [String]
|
133
|
+
# @param grant [String]
|
134
|
+
#
|
135
|
+
# @return [::String]
|
136
|
+
def grant_path **args
|
137
|
+
resources = {
|
138
|
+
"entitlement:grant:location:project" => (proc do |project:, location:, entitlement:, grant:|
|
139
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
140
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
141
|
+
raise ::ArgumentError, "entitlement cannot contain /" if entitlement.to_s.include? "/"
|
142
|
+
|
143
|
+
"projects/#{project}/locations/#{location}/entitlements/#{entitlement}/grants/#{grant}"
|
144
|
+
end),
|
145
|
+
"entitlement:folder:grant:location" => (proc do |folder:, location:, entitlement:, grant:|
|
146
|
+
raise ::ArgumentError, "folder cannot contain /" if folder.to_s.include? "/"
|
147
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
148
|
+
raise ::ArgumentError, "entitlement cannot contain /" if entitlement.to_s.include? "/"
|
149
|
+
|
150
|
+
"folders/#{folder}/locations/#{location}/entitlements/#{entitlement}/grants/#{grant}"
|
151
|
+
end),
|
152
|
+
"entitlement:grant:location:organization" => (proc do |organization:, location:, entitlement:, grant:|
|
153
|
+
raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/"
|
154
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
155
|
+
raise ::ArgumentError, "entitlement cannot contain /" if entitlement.to_s.include? "/"
|
156
|
+
|
157
|
+
"organizations/#{organization}/locations/#{location}/entitlements/#{entitlement}/grants/#{grant}"
|
158
|
+
end)
|
159
|
+
}
|
160
|
+
|
161
|
+
resource = resources[args.keys.sort.join(":")]
|
162
|
+
raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil?
|
163
|
+
resource.call(**args)
|
164
|
+
end
|
165
|
+
|
166
|
+
##
|
167
|
+
# Create a fully-qualified Location resource string.
|
168
|
+
#
|
169
|
+
# The resource will be in the following format:
|
170
|
+
#
|
171
|
+
# `projects/{project}/locations/{location}`
|
172
|
+
#
|
173
|
+
# @param project [String]
|
174
|
+
# @param location [String]
|
175
|
+
#
|
176
|
+
# @return [::String]
|
177
|
+
def location_path project:, location:
|
178
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
179
|
+
|
180
|
+
"projects/#{project}/locations/#{location}"
|
181
|
+
end
|
182
|
+
|
183
|
+
##
|
184
|
+
# Create a fully-qualified OrganizationLocation resource string.
|
185
|
+
#
|
186
|
+
# The resource will be in the following format:
|
187
|
+
#
|
188
|
+
# `organizations/{organization}/locations/{location}`
|
189
|
+
#
|
190
|
+
# @param organization [String]
|
191
|
+
# @param location [String]
|
192
|
+
#
|
193
|
+
# @return [::String]
|
194
|
+
def organization_location_path organization:, location:
|
195
|
+
raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/"
|
196
|
+
|
197
|
+
"organizations/#{organization}/locations/#{location}"
|
198
|
+
end
|
199
|
+
|
200
|
+
extend self
|
201
|
+
end
|
202
|
+
end
|
203
|
+
end
|
204
|
+
end
|
205
|
+
end
|
206
|
+
end
|