[e3d4e0a] | 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 |
|
---|
| 18 | namespace Google\Service\Books\Resource;
|
---|
| 19 |
|
---|
| 20 | use Google\Service\Books\BooksCloudloadingResource;
|
---|
| 21 | use Google\Service\Books\BooksEmpty;
|
---|
| 22 |
|
---|
| 23 | /**
|
---|
| 24 | * The "cloudloading" collection of methods.
|
---|
| 25 | * Typical usage is:
|
---|
| 26 | * <code>
|
---|
| 27 | * $booksService = new Google\Service\Books(...);
|
---|
| 28 | * $cloudloading = $booksService->cloudloading;
|
---|
| 29 | * </code>
|
---|
| 30 | */
|
---|
| 31 | class Cloudloading extends \Google\Service\Resource
|
---|
| 32 | {
|
---|
| 33 | /**
|
---|
| 34 | * Add a user-upload volume and triggers processing. (cloudloading.addBook)
|
---|
| 35 | *
|
---|
| 36 | * @param array $optParams Optional parameters.
|
---|
| 37 | *
|
---|
| 38 | * @opt_param string drive_document_id A drive document id. The
|
---|
| 39 | * upload_client_token must not be set.
|
---|
| 40 | * @opt_param string mime_type The document MIME type. It can be set only if the
|
---|
| 41 | * drive_document_id is set.
|
---|
| 42 | * @opt_param string name The document name. It can be set only if the
|
---|
| 43 | * drive_document_id is set.
|
---|
| 44 | * @opt_param string upload_client_token Scotty upload token.
|
---|
| 45 | * @return BooksCloudloadingResource
|
---|
| 46 | * @throws \Google\Service\Exception
|
---|
| 47 | */
|
---|
| 48 | public function addBook($optParams = [])
|
---|
| 49 | {
|
---|
| 50 | $params = [];
|
---|
| 51 | $params = array_merge($params, $optParams);
|
---|
| 52 | return $this->call('addBook', [$params], BooksCloudloadingResource::class);
|
---|
| 53 | }
|
---|
| 54 | /**
|
---|
| 55 | * Remove the book and its contents (cloudloading.deleteBook)
|
---|
| 56 | *
|
---|
| 57 | * @param string $volumeId The id of the book to be removed.
|
---|
| 58 | * @param array $optParams Optional parameters.
|
---|
| 59 | * @return BooksEmpty
|
---|
| 60 | * @throws \Google\Service\Exception
|
---|
| 61 | */
|
---|
| 62 | public function deleteBook($volumeId, $optParams = [])
|
---|
| 63 | {
|
---|
| 64 | $params = ['volumeId' => $volumeId];
|
---|
| 65 | $params = array_merge($params, $optParams);
|
---|
| 66 | return $this->call('deleteBook', [$params], BooksEmpty::class);
|
---|
| 67 | }
|
---|
| 68 | /**
|
---|
| 69 | * Updates a user-upload volume. (cloudloading.updateBook)
|
---|
| 70 | *
|
---|
| 71 | * @param BooksCloudloadingResource $postBody
|
---|
| 72 | * @param array $optParams Optional parameters.
|
---|
| 73 | * @return BooksCloudloadingResource
|
---|
| 74 | * @throws \Google\Service\Exception
|
---|
| 75 | */
|
---|
| 76 | public function updateBook(BooksCloudloadingResource $postBody, $optParams = [])
|
---|
| 77 | {
|
---|
| 78 | $params = ['postBody' => $postBody];
|
---|
| 79 | $params = array_merge($params, $optParams);
|
---|
| 80 | return $this->call('updateBook', [$params], BooksCloudloadingResource::class);
|
---|
| 81 | }
|
---|
| 82 | }
|
---|
| 83 |
|
---|
| 84 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
| 85 | class_alias(Cloudloading::class, 'Google_Service_Books_Resource_Cloudloading');
|
---|