source: vendor/google/apiclient-services/src/RapidMigrationAssessment/Resource/ProjectsLocationsCollectors.php@ e3d4e0a

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

Upload project files

  • Property mode set to 100644
File size: 8.3 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\RapidMigrationAssessment\Resource;
19
20use Google\Service\RapidMigrationAssessment\Collector;
21use Google\Service\RapidMigrationAssessment\ListCollectorsResponse;
22use Google\Service\RapidMigrationAssessment\Operation;
23use Google\Service\RapidMigrationAssessment\PauseCollectorRequest;
24use Google\Service\RapidMigrationAssessment\RegisterCollectorRequest;
25use Google\Service\RapidMigrationAssessment\ResumeCollectorRequest;
26
27/**
28 * The "collectors" collection of methods.
29 * Typical usage is:
30 * <code>
31 * $rapidmigrationassessmentService = new Google\Service\RapidMigrationAssessment(...);
32 * $collectors = $rapidmigrationassessmentService->projects_locations_collectors;
33 * </code>
34 */
35class ProjectsLocationsCollectors extends \Google\Service\Resource
36{
37 /**
38 * Create a Collector to manage the on-prem appliance which collects information
39 * about Customer assets. (collectors.create)
40 *
41 * @param string $parent Required. Name of the parent (project+location).
42 * @param Collector $postBody
43 * @param array $optParams Optional parameters.
44 *
45 * @opt_param string collectorId Required. Id of the requesting object.
46 * @opt_param string requestId Optional. An optional request ID to identify
47 * requests.
48 * @return Operation
49 * @throws \Google\Service\Exception
50 */
51 public function create($parent, Collector $postBody, $optParams = [])
52 {
53 $params = ['parent' => $parent, 'postBody' => $postBody];
54 $params = array_merge($params, $optParams);
55 return $this->call('create', [$params], Operation::class);
56 }
57 /**
58 * Deletes a single Collector - changes state of collector to "Deleting".
59 * Background jobs does final deletion thorugh producer api. (collectors.delete)
60 *
61 * @param string $name Required. Name of the resource.
62 * @param array $optParams Optional parameters.
63 *
64 * @opt_param string requestId Optional. An optional request ID to identify
65 * requests. Specify a unique request ID so that if you must retry your request,
66 * the server will know to ignore the request if it has already been completed.
67 * The server will guarantee that for at least 60 minutes after the first
68 * request. For example, consider a situation where you make an initial request
69 * and the request times out. If you make the request again with the same
70 * request ID, the server can check if original operation with the same request
71 * ID was received, and if so, will ignore the second request. This prevents
72 * clients from accidentally creating duplicate commitments. The request ID must
73 * be a valid UUID with the exception that zero UUID is not supported
74 * (00000000-0000-0000-0000-000000000000).
75 * @return Operation
76 * @throws \Google\Service\Exception
77 */
78 public function delete($name, $optParams = [])
79 {
80 $params = ['name' => $name];
81 $params = array_merge($params, $optParams);
82 return $this->call('delete', [$params], Operation::class);
83 }
84 /**
85 * Gets details of a single Collector. (collectors.get)
86 *
87 * @param string $name Required. Name of the resource.
88 * @param array $optParams Optional parameters.
89 * @return Collector
90 * @throws \Google\Service\Exception
91 */
92 public function get($name, $optParams = [])
93 {
94 $params = ['name' => $name];
95 $params = array_merge($params, $optParams);
96 return $this->call('get', [$params], Collector::class);
97 }
98 /**
99 * Lists Collectors in a given project and location.
100 * (collectors.listProjectsLocationsCollectors)
101 *
102 * @param string $parent Required. Parent value for ListCollectorsRequest.
103 * @param array $optParams Optional parameters.
104 *
105 * @opt_param string filter Filtering results.
106 * @opt_param string orderBy Hint for how to order the results.
107 * @opt_param int pageSize Requested page size. Server may return fewer items
108 * than requested. If unspecified, server will pick an appropriate default.
109 * @opt_param string pageToken A token identifying a page of results the server
110 * should return.
111 * @return ListCollectorsResponse
112 * @throws \Google\Service\Exception
113 */
114 public function listProjectsLocationsCollectors($parent, $optParams = [])
115 {
116 $params = ['parent' => $parent];
117 $params = array_merge($params, $optParams);
118 return $this->call('list', [$params], ListCollectorsResponse::class);
119 }
120 /**
121 * Updates the parameters of a single Collector. (collectors.patch)
122 *
123 * @param string $name name of resource.
124 * @param Collector $postBody
125 * @param array $optParams Optional parameters.
126 *
127 * @opt_param string requestId Optional. An optional request ID to identify
128 * requests. Specify a unique request ID so that if you must retry your request,
129 * the server will know to ignore the request if it has already been completed.
130 * The server will guarantee that for at least 60 minutes since the first
131 * request. For example, consider a situation where you make an initial request
132 * and the request times out. If you make the request again with the same
133 * request ID, the server can check if original operation with the same request
134 * ID was received, and if so, will ignore the second request. This prevents
135 * clients from accidentally creating duplicate commitments. The request ID must
136 * be a valid UUID with the exception that zero UUID is not supported
137 * (00000000-0000-0000-0000-000000000000).
138 * @opt_param string updateMask Required. Field mask is used to specify the
139 * fields to be overwritten in the Collector resource by the update. The fields
140 * specified in the update_mask are relative to the resource, not the full
141 * request. A field will be overwritten if it is in the mask. If the user does
142 * not provide a mask then all fields will be overwritten.
143 * @return Operation
144 * @throws \Google\Service\Exception
145 */
146 public function patch($name, Collector $postBody, $optParams = [])
147 {
148 $params = ['name' => $name, 'postBody' => $postBody];
149 $params = array_merge($params, $optParams);
150 return $this->call('patch', [$params], Operation::class);
151 }
152 /**
153 * Pauses the given collector. (collectors.pause)
154 *
155 * @param string $name Required. Name of the resource.
156 * @param PauseCollectorRequest $postBody
157 * @param array $optParams Optional parameters.
158 * @return Operation
159 * @throws \Google\Service\Exception
160 */
161 public function pause($name, PauseCollectorRequest $postBody, $optParams = [])
162 {
163 $params = ['name' => $name, 'postBody' => $postBody];
164 $params = array_merge($params, $optParams);
165 return $this->call('pause', [$params], Operation::class);
166 }
167 /**
168 * Registers the given collector. (collectors.register)
169 *
170 * @param string $name Required. Name of the resource.
171 * @param RegisterCollectorRequest $postBody
172 * @param array $optParams Optional parameters.
173 * @return Operation
174 * @throws \Google\Service\Exception
175 */
176 public function register($name, RegisterCollectorRequest $postBody, $optParams = [])
177 {
178 $params = ['name' => $name, 'postBody' => $postBody];
179 $params = array_merge($params, $optParams);
180 return $this->call('register', [$params], Operation::class);
181 }
182 /**
183 * Resumes the given collector. (collectors.resume)
184 *
185 * @param string $name Required. Name of the resource.
186 * @param ResumeCollectorRequest $postBody
187 * @param array $optParams Optional parameters.
188 * @return Operation
189 * @throws \Google\Service\Exception
190 */
191 public function resume($name, ResumeCollectorRequest $postBody, $optParams = [])
192 {
193 $params = ['name' => $name, 'postBody' => $postBody];
194 $params = array_merge($params, $optParams);
195 return $this->call('resume', [$params], Operation::class);
196 }
197}
198
199// Adding a class alias for backwards compatibility with the previous class name.
200class_alias(ProjectsLocationsCollectors::class, 'Google_Service_RapidMigrationAssessment_Resource_ProjectsLocationsCollectors');
Note: See TracBrowser for help on using the repository browser.