source: vendor/google/apiclient-services/src/ChecksService/Resource/ProjectsPrivacypolicyOperations.php

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

Upload project files

  • Property mode set to 100644
File size: 5.5 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\ChecksService\Resource;
19
20use Google\Service\ChecksService\ChecksEmpty;
21use Google\Service\ChecksService\ListOperationsResponse;
22use Google\Service\ChecksService\Operation;
23
24/**
25 * The "operations" collection of methods.
26 * Typical usage is:
27 * <code>
28 * $checksService = new Google\Service\ChecksService(...);
29 * $operations = $checksService->projects_privacypolicy_operations;
30 * </code>
31 */
32class ProjectsPrivacypolicyOperations extends \Google\Service\Resource
33{
34 /**
35 * Starts asynchronous cancellation on a long-running operation. The server
36 * makes a best effort to cancel the operation, but success is not guaranteed.
37 * If the server doesn't support this method, it returns
38 * `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or
39 * other methods to check whether the cancellation succeeded or whether the
40 * operation completed despite cancellation. On successful cancellation, the
41 * operation is not deleted; instead, it becomes an operation with an
42 * Operation.error value with a google.rpc.Status.code of 1, corresponding to
43 * `Code.CANCELLED`. (operations.cancel)
44 *
45 * @param string $name The name of the operation resource to be cancelled.
46 * @param array $optParams Optional parameters.
47 * @return ChecksEmpty
48 */
49 public function cancel($name, $optParams = [])
50 {
51 $params = ['name' => $name];
52 $params = array_merge($params, $optParams);
53 return $this->call('cancel', [$params], ChecksEmpty::class);
54 }
55 /**
56 * Deletes a long-running operation. This method indicates that the client is no
57 * longer interested in the operation result. It does not cancel the operation.
58 * If the server doesn't support this method, it returns
59 * `google.rpc.Code.UNIMPLEMENTED`. (operations.delete)
60 *
61 * @param string $name The name of the operation resource to be deleted.
62 * @param array $optParams Optional parameters.
63 * @return ChecksEmpty
64 */
65 public function delete($name, $optParams = [])
66 {
67 $params = ['name' => $name];
68 $params = array_merge($params, $optParams);
69 return $this->call('delete', [$params], ChecksEmpty::class);
70 }
71 /**
72 * Gets the latest state of a long-running operation. Clients can use this
73 * method to poll the operation result at intervals as recommended by the API
74 * service. (operations.get)
75 *
76 * @param string $name The name of the operation resource.
77 * @param array $optParams Optional parameters.
78 * @return Operation
79 */
80 public function get($name, $optParams = [])
81 {
82 $params = ['name' => $name];
83 $params = array_merge($params, $optParams);
84 return $this->call('get', [$params], Operation::class);
85 }
86 /**
87 * Lists operations that match the specified filter in the request. If the
88 * server doesn't support this method, it returns `UNIMPLEMENTED`.
89 * (operations.listProjectsPrivacypolicyOperations)
90 *
91 * @param string $name The name of the operation's parent resource.
92 * @param array $optParams Optional parameters.
93 *
94 * @opt_param string filter The standard list filter.
95 * @opt_param int pageSize The standard list page size.
96 * @opt_param string pageToken The standard list page token.
97 * @return ListOperationsResponse
98 */
99 public function listProjectsPrivacypolicyOperations($name, $optParams = [])
100 {
101 $params = ['name' => $name];
102 $params = array_merge($params, $optParams);
103 return $this->call('list', [$params], ListOperationsResponse::class);
104 }
105 /**
106 * Waits until the specified long-running operation is done or reaches at most a
107 * specified timeout, returning the latest state. If the operation is already
108 * done, the latest state is immediately returned. If the timeout specified is
109 * greater than the default HTTP/RPC timeout, the HTTP/RPC timeout is used. If
110 * the server does not support this method, it returns
111 * `google.rpc.Code.UNIMPLEMENTED`. Note that this method is on a best-effort
112 * basis. It may return the latest state before the specified timeout (including
113 * immediately), meaning even an immediate response is no guarantee that the
114 * operation is done. (operations.wait)
115 *
116 * @param string $name The name of the operation resource to wait on.
117 * @param array $optParams Optional parameters.
118 *
119 * @opt_param string timeout The maximum duration to wait before timing out. If
120 * left blank, the wait will be at most the time permitted by the underlying
121 * HTTP/RPC protocol. If RPC context deadline is also specified, the shorter one
122 * will be used.
123 * @return Operation
124 */
125 public function wait($name, $optParams = [])
126 {
127 $params = ['name' => $name];
128 $params = array_merge($params, $optParams);
129 return $this->call('wait', [$params], Operation::class);
130 }
131}
132
133// Adding a class alias for backwards compatibility with the previous class name.
134class_alias(ProjectsPrivacypolicyOperations::class, 'Google_Service_ChecksService_Resource_ProjectsPrivacypolicyOperations');
Note: See TracBrowser for help on using the repository browser.