source: vendor/google/apiclient-services/src/SASPortalTesting/Resource/CustomersDevices.php@ e3d4e0a

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

Upload project files

  • Property mode set to 100644
File size: 7.0 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\SASPortalTesting\Resource;
19
20use Google\Service\SASPortalTesting\SasPortalCreateSignedDeviceRequest;
21use Google\Service\SASPortalTesting\SasPortalDevice;
22use Google\Service\SASPortalTesting\SasPortalEmpty;
23use Google\Service\SASPortalTesting\SasPortalListDevicesResponse;
24use Google\Service\SASPortalTesting\SasPortalMoveDeviceRequest;
25use Google\Service\SASPortalTesting\SasPortalOperation;
26use Google\Service\SASPortalTesting\SasPortalSignDeviceRequest;
27use Google\Service\SASPortalTesting\SasPortalUpdateSignedDeviceRequest;
28
29/**
30 * The "devices" collection of methods.
31 * Typical usage is:
32 * <code>
33 * $prod_tt_sasportalService = new Google\Service\SASPortalTesting(...);
34 * $devices = $prod_tt_sasportalService->customers_devices;
35 * </code>
36 */
37class CustomersDevices extends \Google\Service\Resource
38{
39 /**
40 * Creates a device under a node or customer. (devices.create)
41 *
42 * @param string $parent Required. The name of the parent resource.
43 * @param SasPortalDevice $postBody
44 * @param array $optParams Optional parameters.
45 * @return SasPortalDevice
46 * @throws \Google\Service\Exception
47 */
48 public function create($parent, SasPortalDevice $postBody, $optParams = [])
49 {
50 $params = ['parent' => $parent, 'postBody' => $postBody];
51 $params = array_merge($params, $optParams);
52 return $this->call('create', [$params], SasPortalDevice::class);
53 }
54 /**
55 * Creates a signed device under a node or customer. (devices.createSigned)
56 *
57 * @param string $parent Required. The name of the parent resource.
58 * @param SasPortalCreateSignedDeviceRequest $postBody
59 * @param array $optParams Optional parameters.
60 * @return SasPortalDevice
61 * @throws \Google\Service\Exception
62 */
63 public function createSigned($parent, SasPortalCreateSignedDeviceRequest $postBody, $optParams = [])
64 {
65 $params = ['parent' => $parent, 'postBody' => $postBody];
66 $params = array_merge($params, $optParams);
67 return $this->call('createSigned', [$params], SasPortalDevice::class);
68 }
69 /**
70 * Deletes a device. (devices.delete)
71 *
72 * @param string $name Required. The name of the device.
73 * @param array $optParams Optional parameters.
74 * @return SasPortalEmpty
75 * @throws \Google\Service\Exception
76 */
77 public function delete($name, $optParams = [])
78 {
79 $params = ['name' => $name];
80 $params = array_merge($params, $optParams);
81 return $this->call('delete', [$params], SasPortalEmpty::class);
82 }
83 /**
84 * Gets details about a device. (devices.get)
85 *
86 * @param string $name Required. The name of the device.
87 * @param array $optParams Optional parameters.
88 * @return SasPortalDevice
89 * @throws \Google\Service\Exception
90 */
91 public function get($name, $optParams = [])
92 {
93 $params = ['name' => $name];
94 $params = array_merge($params, $optParams);
95 return $this->call('get', [$params], SasPortalDevice::class);
96 }
97 /**
98 * Lists devices under a node or customer. (devices.listCustomersDevices)
99 *
100 * @param string $parent Required. The name of the parent resource.
101 * @param array $optParams Optional parameters.
102 *
103 * @opt_param string filter The filter expression. The filter should have one of
104 * the following formats: "sn=123454" or "display_name=MyDevice". sn corresponds
105 * to serial number of the device. The filter is case insensitive.
106 * @opt_param int pageSize The maximum number of devices to return in the
107 * response. If empty or zero, all devices will be listed. Must be in the range
108 * [0, 1000].
109 * @opt_param string pageToken A pagination token returned from a previous call
110 * to ListDevices that indicates where this listing should continue from.
111 * @return SasPortalListDevicesResponse
112 * @throws \Google\Service\Exception
113 */
114 public function listCustomersDevices($parent, $optParams = [])
115 {
116 $params = ['parent' => $parent];
117 $params = array_merge($params, $optParams);
118 return $this->call('list', [$params], SasPortalListDevicesResponse::class);
119 }
120 /**
121 * Moves a device under another node or customer. (devices.move)
122 *
123 * @param string $name Required. The name of the device to move.
124 * @param SasPortalMoveDeviceRequest $postBody
125 * @param array $optParams Optional parameters.
126 * @return SasPortalOperation
127 * @throws \Google\Service\Exception
128 */
129 public function move($name, SasPortalMoveDeviceRequest $postBody, $optParams = [])
130 {
131 $params = ['name' => $name, 'postBody' => $postBody];
132 $params = array_merge($params, $optParams);
133 return $this->call('move', [$params], SasPortalOperation::class);
134 }
135 /**
136 * Updates a device. (devices.patch)
137 *
138 * @param string $name Output only. The resource path name.
139 * @param SasPortalDevice $postBody
140 * @param array $optParams Optional parameters.
141 *
142 * @opt_param string updateMask Fields to be updated.
143 * @return SasPortalDevice
144 * @throws \Google\Service\Exception
145 */
146 public function patch($name, SasPortalDevice $postBody, $optParams = [])
147 {
148 $params = ['name' => $name, 'postBody' => $postBody];
149 $params = array_merge($params, $optParams);
150 return $this->call('patch', [$params], SasPortalDevice::class);
151 }
152 /**
153 * Signs a device. (devices.signDevice)
154 *
155 * @param string $name Output only. The resource path name.
156 * @param SasPortalSignDeviceRequest $postBody
157 * @param array $optParams Optional parameters.
158 * @return SasPortalEmpty
159 * @throws \Google\Service\Exception
160 */
161 public function signDevice($name, SasPortalSignDeviceRequest $postBody, $optParams = [])
162 {
163 $params = ['name' => $name, 'postBody' => $postBody];
164 $params = array_merge($params, $optParams);
165 return $this->call('signDevice', [$params], SasPortalEmpty::class);
166 }
167 /**
168 * Updates a signed device. (devices.updateSigned)
169 *
170 * @param string $name Required. The name of the device to update.
171 * @param SasPortalUpdateSignedDeviceRequest $postBody
172 * @param array $optParams Optional parameters.
173 * @return SasPortalDevice
174 * @throws \Google\Service\Exception
175 */
176 public function updateSigned($name, SasPortalUpdateSignedDeviceRequest $postBody, $optParams = [])
177 {
178 $params = ['name' => $name, 'postBody' => $postBody];
179 $params = array_merge($params, $optParams);
180 return $this->call('updateSigned', [$params], SasPortalDevice::class);
181 }
182}
183
184// Adding a class alias for backwards compatibility with the previous class name.
185class_alias(CustomersDevices::class, 'Google_Service_SASPortalTesting_Resource_CustomersDevices');
Note: See TracBrowser for help on using the repository browser.