source: vendor/google/apiclient-services/src/Compute/Resource/PublicDelegatedPrefixes.php

Last change on this file was e3d4e0a, checked in by Vlado 222039 <vlado.popovski@…>, 10 days ago

Upload project files

  • Property mode set to 100644
File size: 19.7 KB
Line 
1<?php
2/*
3 * Copyright 2014 Google Inc.
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
6 * use this file except in compliance with the License. You may obtain a copy of
7 * the License at
8 *
9 * http://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, WITHOUT
13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14 * License for the specific language governing permissions and limitations under
15 * the License.
16 */
17
18namespace Google\Service\Compute\Resource;
19
20use Google\Service\Compute\Operation;
21use Google\Service\Compute\PublicDelegatedPrefix;
22use Google\Service\Compute\PublicDelegatedPrefixAggregatedList;
23use Google\Service\Compute\PublicDelegatedPrefixList;
24
25/**
26 * The "publicDelegatedPrefixes" collection of methods.
27 * Typical usage is:
28 * <code>
29 * $computeService = new Google\Service\Compute(...);
30 * $publicDelegatedPrefixes = $computeService->publicDelegatedPrefixes;
31 * </code>
32 */
33class PublicDelegatedPrefixes extends \Google\Service\Resource
34{
35 /**
36 * Lists all PublicDelegatedPrefix resources owned by the specific project
37 * across all scopes. To prevent failure, Google recommends that you set the
38 * `returnPartialSuccess` parameter to `true`.
39 * (publicDelegatedPrefixes.aggregatedList)
40 *
41 * @param string $project Name of the project scoping this request.
42 * @param array $optParams Optional parameters.
43 *
44 * @opt_param string filter A filter expression that filters resources listed in
45 * the response. Most Compute resources support two types of filter expressions:
46 * expressions that support regular expressions and expressions that follow API
47 * improvement proposal AIP-160. These two types of filter expressions cannot be
48 * mixed in one request. If you want to use AIP-160, your expression must
49 * specify the field name, an operator, and the value that you want to use for
50 * filtering. The value must be a string, a number, or a boolean. The operator
51 * must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you
52 * are filtering Compute Engine instances, you can exclude instances named
53 * `example-instance` by specifying `name != example-instance`. The `:*`
54 * comparison can be used to test whether a key has been defined. For example,
55 * to find all objects with `owner` label use: ``` labels.owner:* ``` You can
56 * also filter nested fields. For example, you could specify
57 * `scheduling.automaticRestart = false` to include instances only if they are
58 * not scheduled for automatic restarts. You can use filtering on nested fields
59 * to filter based on resource labels. To filter on multiple expressions,
60 * provide each separate expression within parentheses. For example: ```
61 * (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By
62 * default, each expression is an `AND` expression. However, you can include
63 * `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel
64 * Skylake") OR (cpuPlatform = "Intel Broadwell") AND
65 * (scheduling.automaticRestart = true) ``` If you want to use a regular
66 * expression, use the `eq` (equal) or `ne` (not equal) operator against a
67 * single un-parenthesized expression with or without quotes or against multiple
68 * parenthesized expressions. Examples: `fieldname eq unquoted literal`
69 * `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"`
70 * `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is
71 * interpreted as a regular expression using Google RE2 library syntax. The
72 * literal value must match the entire field. For example, to filter for
73 * instances that do not end with name "instance", you would use `name ne
74 * .*instance`. You cannot combine constraints on multiple fields using regular
75 * expressions.
76 * @opt_param bool includeAllScopes Indicates whether every visible scope for
77 * each scope type (zone, region, global) should be included in the response.
78 * For new resource types added after this field, the flag has no effect as new
79 * resource types will always include every visible scope for each scope type in
80 * response. For resource types which predate this field, if this flag is
81 * omitted or false, only scopes of the scope types where the resource type is
82 * expected to be found will be included.
83 * @opt_param string maxResults The maximum number of results per page that
84 * should be returned. If the number of available results is larger than
85 * `maxResults`, Compute Engine returns a `nextPageToken` that can be used to
86 * get the next page of results in subsequent list requests. Acceptable values
87 * are `0` to `500`, inclusive. (Default: `500`)
88 * @opt_param string orderBy Sorts list results by a certain order. By default,
89 * results are returned in alphanumerical order based on the resource name. You
90 * can also sort results in descending order based on the creation timestamp
91 * using `orderBy="creationTimestamp desc"`. This sorts results based on the
92 * `creationTimestamp` field in reverse chronological order (newest result
93 * first). Use this to sort resources like operations so that the newest
94 * operation is returned first. Currently, only sorting by `name` or
95 * `creationTimestamp desc` is supported.
96 * @opt_param string pageToken Specifies a page token to use. Set `pageToken` to
97 * the `nextPageToken` returned by a previous list request to get the next page
98 * of results.
99 * @opt_param bool returnPartialSuccess Opt-in for partial success behavior
100 * which provides partial results in case of failure. The default value is
101 * false. For example, when partial success behavior is enabled, aggregatedList
102 * for a single zone scope either returns all resources in the zone or no
103 * resources, with an error code.
104 * @opt_param string serviceProjectNumber The Shared VPC service project id or
105 * service project number for which aggregated list request is invoked for
106 * subnetworks list-usable api.
107 * @return PublicDelegatedPrefixAggregatedList
108 * @throws \Google\Service\Exception
109 */
110 public function aggregatedList($project, $optParams = [])
111 {
112 $params = ['project' => $project];
113 $params = array_merge($params, $optParams);
114 return $this->call('aggregatedList', [$params], PublicDelegatedPrefixAggregatedList::class);
115 }
116 /**
117 * Announces the specified PublicDelegatedPrefix in the given region.
118 * (publicDelegatedPrefixes.announce)
119 *
120 * @param string $project Project ID for this request.
121 * @param string $region The name of the region where the public delegated
122 * prefix is located. It should comply with RFC1035.
123 * @param string $publicDelegatedPrefix The name of the public delegated prefix.
124 * It should comply with RFC1035.
125 * @param array $optParams Optional parameters.
126 *
127 * @opt_param string requestId An optional request ID to identify requests.
128 * Specify a unique request ID so that if you must retry your request, the
129 * server will know to ignore the request if it has already been completed. For
130 * example, consider a situation where you make an initial request and the
131 * request times out. If you make the request again with the same request ID,
132 * the server can check if original operation with the same request ID was
133 * received, and if so, will ignore the second request. This prevents clients
134 * from accidentally creating duplicate commitments. The request ID must be a
135 * valid UUID with the exception that zero UUID is not supported (
136 * 00000000-0000-0000-0000-000000000000).
137 * @return Operation
138 * @throws \Google\Service\Exception
139 */
140 public function announce($project, $region, $publicDelegatedPrefix, $optParams = [])
141 {
142 $params = ['project' => $project, 'region' => $region, 'publicDelegatedPrefix' => $publicDelegatedPrefix];
143 $params = array_merge($params, $optParams);
144 return $this->call('announce', [$params], Operation::class);
145 }
146 /**
147 * Deletes the specified PublicDelegatedPrefix in the given region.
148 * (publicDelegatedPrefixes.delete)
149 *
150 * @param string $project Project ID for this request.
151 * @param string $region Name of the region of this request.
152 * @param string $publicDelegatedPrefix Name of the PublicDelegatedPrefix
153 * resource to delete.
154 * @param array $optParams Optional parameters.
155 *
156 * @opt_param string requestId An optional request ID to identify requests.
157 * Specify a unique request ID so that if you must retry your request, the
158 * server will know to ignore the request if it has already been completed. For
159 * example, consider a situation where you make an initial request and the
160 * request times out. If you make the request again with the same request ID,
161 * the server can check if original operation with the same request ID was
162 * received, and if so, will ignore the second request. This prevents clients
163 * from accidentally creating duplicate commitments. The request ID must be a
164 * valid UUID with the exception that zero UUID is not supported (
165 * 00000000-0000-0000-0000-000000000000).
166 * @return Operation
167 * @throws \Google\Service\Exception
168 */
169 public function delete($project, $region, $publicDelegatedPrefix, $optParams = [])
170 {
171 $params = ['project' => $project, 'region' => $region, 'publicDelegatedPrefix' => $publicDelegatedPrefix];
172 $params = array_merge($params, $optParams);
173 return $this->call('delete', [$params], Operation::class);
174 }
175 /**
176 * Returns the specified PublicDelegatedPrefix resource in the given region.
177 * (publicDelegatedPrefixes.get)
178 *
179 * @param string $project Project ID for this request.
180 * @param string $region Name of the region of this request.
181 * @param string $publicDelegatedPrefix Name of the PublicDelegatedPrefix
182 * resource to return.
183 * @param array $optParams Optional parameters.
184 * @return PublicDelegatedPrefix
185 * @throws \Google\Service\Exception
186 */
187 public function get($project, $region, $publicDelegatedPrefix, $optParams = [])
188 {
189 $params = ['project' => $project, 'region' => $region, 'publicDelegatedPrefix' => $publicDelegatedPrefix];
190 $params = array_merge($params, $optParams);
191 return $this->call('get', [$params], PublicDelegatedPrefix::class);
192 }
193 /**
194 * Creates a PublicDelegatedPrefix in the specified project in the given region
195 * using the parameters that are included in the request.
196 * (publicDelegatedPrefixes.insert)
197 *
198 * @param string $project Project ID for this request.
199 * @param string $region Name of the region of this request.
200 * @param PublicDelegatedPrefix $postBody
201 * @param array $optParams Optional parameters.
202 *
203 * @opt_param string requestId An optional request ID to identify requests.
204 * Specify a unique request ID so that if you must retry your request, the
205 * server will know to ignore the request if it has already been completed. For
206 * example, consider a situation where you make an initial request and the
207 * request times out. If you make the request again with the same request ID,
208 * the server can check if original operation with the same request ID was
209 * received, and if so, will ignore the second request. This prevents clients
210 * from accidentally creating duplicate commitments. The request ID must be a
211 * valid UUID with the exception that zero UUID is not supported (
212 * 00000000-0000-0000-0000-000000000000).
213 * @return Operation
214 * @throws \Google\Service\Exception
215 */
216 public function insert($project, $region, PublicDelegatedPrefix $postBody, $optParams = [])
217 {
218 $params = ['project' => $project, 'region' => $region, 'postBody' => $postBody];
219 $params = array_merge($params, $optParams);
220 return $this->call('insert', [$params], Operation::class);
221 }
222 /**
223 * Lists the PublicDelegatedPrefixes for a project in the given region.
224 * (publicDelegatedPrefixes.listPublicDelegatedPrefixes)
225 *
226 * @param string $project Project ID for this request.
227 * @param string $region Name of the region of this request.
228 * @param array $optParams Optional parameters.
229 *
230 * @opt_param string filter A filter expression that filters resources listed in
231 * the response. Most Compute resources support two types of filter expressions:
232 * expressions that support regular expressions and expressions that follow API
233 * improvement proposal AIP-160. These two types of filter expressions cannot be
234 * mixed in one request. If you want to use AIP-160, your expression must
235 * specify the field name, an operator, and the value that you want to use for
236 * filtering. The value must be a string, a number, or a boolean. The operator
237 * must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you
238 * are filtering Compute Engine instances, you can exclude instances named
239 * `example-instance` by specifying `name != example-instance`. The `:*`
240 * comparison can be used to test whether a key has been defined. For example,
241 * to find all objects with `owner` label use: ``` labels.owner:* ``` You can
242 * also filter nested fields. For example, you could specify
243 * `scheduling.automaticRestart = false` to include instances only if they are
244 * not scheduled for automatic restarts. You can use filtering on nested fields
245 * to filter based on resource labels. To filter on multiple expressions,
246 * provide each separate expression within parentheses. For example: ```
247 * (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By
248 * default, each expression is an `AND` expression. However, you can include
249 * `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel
250 * Skylake") OR (cpuPlatform = "Intel Broadwell") AND
251 * (scheduling.automaticRestart = true) ``` If you want to use a regular
252 * expression, use the `eq` (equal) or `ne` (not equal) operator against a
253 * single un-parenthesized expression with or without quotes or against multiple
254 * parenthesized expressions. Examples: `fieldname eq unquoted literal`
255 * `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"`
256 * `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is
257 * interpreted as a regular expression using Google RE2 library syntax. The
258 * literal value must match the entire field. For example, to filter for
259 * instances that do not end with name "instance", you would use `name ne
260 * .*instance`. You cannot combine constraints on multiple fields using regular
261 * expressions.
262 * @opt_param string maxResults The maximum number of results per page that
263 * should be returned. If the number of available results is larger than
264 * `maxResults`, Compute Engine returns a `nextPageToken` that can be used to
265 * get the next page of results in subsequent list requests. Acceptable values
266 * are `0` to `500`, inclusive. (Default: `500`)
267 * @opt_param string orderBy Sorts list results by a certain order. By default,
268 * results are returned in alphanumerical order based on the resource name. You
269 * can also sort results in descending order based on the creation timestamp
270 * using `orderBy="creationTimestamp desc"`. This sorts results based on the
271 * `creationTimestamp` field in reverse chronological order (newest result
272 * first). Use this to sort resources like operations so that the newest
273 * operation is returned first. Currently, only sorting by `name` or
274 * `creationTimestamp desc` is supported.
275 * @opt_param string pageToken Specifies a page token to use. Set `pageToken` to
276 * the `nextPageToken` returned by a previous list request to get the next page
277 * of results.
278 * @opt_param bool returnPartialSuccess Opt-in for partial success behavior
279 * which provides partial results in case of failure. The default value is
280 * false. For example, when partial success behavior is enabled, aggregatedList
281 * for a single zone scope either returns all resources in the zone or no
282 * resources, with an error code.
283 * @return PublicDelegatedPrefixList
284 * @throws \Google\Service\Exception
285 */
286 public function listPublicDelegatedPrefixes($project, $region, $optParams = [])
287 {
288 $params = ['project' => $project, 'region' => $region];
289 $params = array_merge($params, $optParams);
290 return $this->call('list', [$params], PublicDelegatedPrefixList::class);
291 }
292 /**
293 * Patches the specified PublicDelegatedPrefix resource with the data included
294 * in the request. This method supports PATCH semantics and uses JSON merge
295 * patch format and processing rules. (publicDelegatedPrefixes.patch)
296 *
297 * @param string $project Project ID for this request.
298 * @param string $region Name of the region for this request.
299 * @param string $publicDelegatedPrefix Name of the PublicDelegatedPrefix
300 * resource to patch.
301 * @param PublicDelegatedPrefix $postBody
302 * @param array $optParams Optional parameters.
303 *
304 * @opt_param string requestId An optional request ID to identify requests.
305 * Specify a unique request ID so that if you must retry your request, the
306 * server will know to ignore the request if it has already been completed. For
307 * example, consider a situation where you make an initial request and the
308 * request times out. If you make the request again with the same request ID,
309 * the server can check if original operation with the same request ID was
310 * received, and if so, will ignore the second request. This prevents clients
311 * from accidentally creating duplicate commitments. The request ID must be a
312 * valid UUID with the exception that zero UUID is not supported (
313 * 00000000-0000-0000-0000-000000000000).
314 * @return Operation
315 * @throws \Google\Service\Exception
316 */
317 public function patch($project, $region, $publicDelegatedPrefix, PublicDelegatedPrefix $postBody, $optParams = [])
318 {
319 $params = ['project' => $project, 'region' => $region, 'publicDelegatedPrefix' => $publicDelegatedPrefix, 'postBody' => $postBody];
320 $params = array_merge($params, $optParams);
321 return $this->call('patch', [$params], Operation::class);
322 }
323 /**
324 * Withdraws the specified PublicDelegatedPrefix in the given region.
325 * (publicDelegatedPrefixes.withdraw)
326 *
327 * @param string $project Project ID for this request.
328 * @param string $region The name of the region where the public delegated
329 * prefix is located. It should comply with RFC1035.
330 * @param string $publicDelegatedPrefix The name of the public delegated prefix.
331 * It should comply with RFC1035.
332 * @param array $optParams Optional parameters.
333 *
334 * @opt_param string requestId An optional request ID to identify requests.
335 * Specify a unique request ID so that if you must retry your request, the
336 * server will know to ignore the request if it has already been completed. For
337 * example, consider a situation where you make an initial request and the
338 * request times out. If you make the request again with the same request ID,
339 * the server can check if original operation with the same request ID was
340 * received, and if so, will ignore the second request. This prevents clients
341 * from accidentally creating duplicate commitments. The request ID must be a
342 * valid UUID with the exception that zero UUID is not supported (
343 * 00000000-0000-0000-0000-000000000000).
344 * @return Operation
345 * @throws \Google\Service\Exception
346 */
347 public function withdraw($project, $region, $publicDelegatedPrefix, $optParams = [])
348 {
349 $params = ['project' => $project, 'region' => $region, 'publicDelegatedPrefix' => $publicDelegatedPrefix];
350 $params = array_merge($params, $optParams);
351 return $this->call('withdraw', [$params], Operation::class);
352 }
353}
354
355// Adding a class alias for backwards compatibility with the previous class name.
356class_alias(PublicDelegatedPrefixes::class, 'Google_Service_Compute_Resource_PublicDelegatedPrefixes');
Note: See TracBrowser for help on using the repository browser.