source: vendor/google/apiclient-services/src/Drive/Resource/Teamdrives.php

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

Upload project files

  • Property mode set to 100644
File size: 4.6 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\Drive\Resource;
19
20use Google\Service\Drive\TeamDrive;
21use Google\Service\Drive\TeamDriveList;
22
23/**
24 * The "teamdrives" collection of methods.
25 * Typical usage is:
26 * <code>
27 * $driveService = new Google\Service\Drive(...);
28 * $teamdrives = $driveService->teamdrives;
29 * </code>
30 */
31class Teamdrives extends \Google\Service\Resource
32{
33 /**
34 * Deprecated: Use `drives.create` instead. (teamdrives.create)
35 *
36 * @param string $requestId Required. An ID, such as a random UUID, which
37 * uniquely identifies this user's request for idempotent creation of a Team
38 * Drive. A repeated request by the same user and with the same request ID will
39 * avoid creating duplicates by attempting to create the same Team Drive. If the
40 * Team Drive already exists a 409 error will be returned.
41 * @param TeamDrive $postBody
42 * @param array $optParams Optional parameters.
43 * @return TeamDrive
44 * @throws \Google\Service\Exception
45 */
46 public function create($requestId, TeamDrive $postBody, $optParams = [])
47 {
48 $params = ['requestId' => $requestId, 'postBody' => $postBody];
49 $params = array_merge($params, $optParams);
50 return $this->call('create', [$params], TeamDrive::class);
51 }
52 /**
53 * Deprecated: Use `drives.delete` instead. (teamdrives.delete)
54 *
55 * @param string $teamDriveId The ID of the Team Drive
56 * @param array $optParams Optional parameters.
57 * @throws \Google\Service\Exception
58 */
59 public function delete($teamDriveId, $optParams = [])
60 {
61 $params = ['teamDriveId' => $teamDriveId];
62 $params = array_merge($params, $optParams);
63 return $this->call('delete', [$params]);
64 }
65 /**
66 * Deprecated: Use `drives.get` instead. (teamdrives.get)
67 *
68 * @param string $teamDriveId The ID of the Team Drive
69 * @param array $optParams Optional parameters.
70 *
71 * @opt_param bool useDomainAdminAccess Issue the request as a domain
72 * administrator; if set to true, then the requester will be granted access if
73 * they are an administrator of the domain to which the Team Drive belongs.
74 * @return TeamDrive
75 * @throws \Google\Service\Exception
76 */
77 public function get($teamDriveId, $optParams = [])
78 {
79 $params = ['teamDriveId' => $teamDriveId];
80 $params = array_merge($params, $optParams);
81 return $this->call('get', [$params], TeamDrive::class);
82 }
83 /**
84 * Deprecated: Use `drives.list` instead. (teamdrives.listTeamdrives)
85 *
86 * @param array $optParams Optional parameters.
87 *
88 * @opt_param int pageSize Maximum number of Team Drives to return.
89 * @opt_param string pageToken Page token for Team Drives.
90 * @opt_param string q Query string for searching Team Drives.
91 * @opt_param bool useDomainAdminAccess Issue the request as a domain
92 * administrator; if set to true, then all Team Drives of the domain in which
93 * the requester is an administrator are returned.
94 * @return TeamDriveList
95 * @throws \Google\Service\Exception
96 */
97 public function listTeamdrives($optParams = [])
98 {
99 $params = [];
100 $params = array_merge($params, $optParams);
101 return $this->call('list', [$params], TeamDriveList::class);
102 }
103 /**
104 * Deprecated: Use `drives.update` instead. (teamdrives.update)
105 *
106 * @param string $teamDriveId The ID of the Team Drive
107 * @param TeamDrive $postBody
108 * @param array $optParams Optional parameters.
109 *
110 * @opt_param bool useDomainAdminAccess Issue the request as a domain
111 * administrator; if set to true, then the requester will be granted access if
112 * they are an administrator of the domain to which the Team Drive belongs.
113 * @return TeamDrive
114 * @throws \Google\Service\Exception
115 */
116 public function update($teamDriveId, TeamDrive $postBody, $optParams = [])
117 {
118 $params = ['teamDriveId' => $teamDriveId, 'postBody' => $postBody];
119 $params = array_merge($params, $optParams);
120 return $this->call('update', [$params], TeamDrive::class);
121 }
122}
123
124// Adding a class alias for backwards compatibility with the previous class name.
125class_alias(Teamdrives::class, 'Google_Service_Drive_Resource_Teamdrives');
Note: See TracBrowser for help on using the repository browser.