google-cloud-secure_source_manager-v1 2.1.0 → 2.2.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.
@@ -85,6 +85,27 @@ module Google
85
85
  "projects/#{project}/locations/#{location}/keyRings/#{key_ring}/cryptoKeys/#{crypto_key}"
86
86
  end
87
87
 
88
+ ##
89
+ # Create a fully-qualified Hook resource string.
90
+ #
91
+ # The resource will be in the following format:
92
+ #
93
+ # `projects/{project}/locations/{location}/repositories/{repository}/hooks/{hook}`
94
+ #
95
+ # @param project [String]
96
+ # @param location [String]
97
+ # @param repository [String]
98
+ # @param hook [String]
99
+ #
100
+ # @return [::String]
101
+ def hook_path project:, location:, repository:, hook:
102
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
103
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
104
+ raise ::ArgumentError, "repository cannot contain /" if repository.to_s.include? "/"
105
+
106
+ "projects/#{project}/locations/#{location}/repositories/#{repository}/hooks/#{hook}"
107
+ end
108
+
88
109
  ##
89
110
  # Create a fully-qualified Instance resource string.
90
111
  #
@@ -104,6 +125,50 @@ module Google
104
125
  "projects/#{project}/locations/#{location}/instances/#{instance}"
105
126
  end
106
127
 
128
+ ##
129
+ # Create a fully-qualified Issue resource string.
130
+ #
131
+ # The resource will be in the following format:
132
+ #
133
+ # `projects/{project}/locations/{location}/repositories/{repository}/issues/{issue}`
134
+ #
135
+ # @param project [String]
136
+ # @param location [String]
137
+ # @param repository [String]
138
+ # @param issue [String]
139
+ #
140
+ # @return [::String]
141
+ def issue_path project:, location:, repository:, issue:
142
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
143
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
144
+ raise ::ArgumentError, "repository cannot contain /" if repository.to_s.include? "/"
145
+
146
+ "projects/#{project}/locations/#{location}/repositories/#{repository}/issues/#{issue}"
147
+ end
148
+
149
+ ##
150
+ # Create a fully-qualified IssueComment resource string.
151
+ #
152
+ # The resource will be in the following format:
153
+ #
154
+ # `projects/{project}/locations/{location}/repositories/{repository}/issues/{issue}/issueComments/{comment}`
155
+ #
156
+ # @param project [String]
157
+ # @param location [String]
158
+ # @param repository [String]
159
+ # @param issue [String]
160
+ # @param comment [String]
161
+ #
162
+ # @return [::String]
163
+ def issue_comment_path project:, location:, repository:, issue:, comment:
164
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
165
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
166
+ raise ::ArgumentError, "repository cannot contain /" if repository.to_s.include? "/"
167
+ raise ::ArgumentError, "issue cannot contain /" if issue.to_s.include? "/"
168
+
169
+ "projects/#{project}/locations/#{location}/repositories/#{repository}/issues/#{issue}/issueComments/#{comment}"
170
+ end
171
+
107
172
  ##
108
173
  # Create a fully-qualified Location resource string.
109
174
  #
@@ -121,6 +186,50 @@ module Google
121
186
  "projects/#{project}/locations/#{location}"
122
187
  end
123
188
 
189
+ ##
190
+ # Create a fully-qualified PullRequest resource string.
191
+ #
192
+ # The resource will be in the following format:
193
+ #
194
+ # `projects/{project}/locations/{location}/repositories/{repository}/pullRequests/{pull_request}`
195
+ #
196
+ # @param project [String]
197
+ # @param location [String]
198
+ # @param repository [String]
199
+ # @param pull_request [String]
200
+ #
201
+ # @return [::String]
202
+ def pull_request_path project:, location:, repository:, pull_request:
203
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
204
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
205
+ raise ::ArgumentError, "repository cannot contain /" if repository.to_s.include? "/"
206
+
207
+ "projects/#{project}/locations/#{location}/repositories/#{repository}/pullRequests/#{pull_request}"
208
+ end
209
+
210
+ ##
211
+ # Create a fully-qualified PullRequestComment resource string.
212
+ #
213
+ # The resource will be in the following format:
214
+ #
215
+ # `projects/{project}/locations/{location}/repositories/{repository}/pullRequests/{pull_request}/pullRequestComments/{comment}`
216
+ #
217
+ # @param project [String]
218
+ # @param location [String]
219
+ # @param repository [String]
220
+ # @param pull_request [String]
221
+ # @param comment [String]
222
+ #
223
+ # @return [::String]
224
+ def pull_request_comment_path project:, location:, repository:, pull_request:, comment:
225
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
226
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
227
+ raise ::ArgumentError, "repository cannot contain /" if repository.to_s.include? "/"
228
+ raise ::ArgumentError, "pull_request cannot contain /" if pull_request.to_s.include? "/"
229
+
230
+ "projects/#{project}/locations/#{location}/repositories/#{repository}/pullRequests/#{pull_request}/pullRequestComments/#{comment}"
231
+ end
232
+
124
233
  ##
125
234
  # Create a fully-qualified Repository resource string.
126
235
  #