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\PolyService\Resource;
19
20use Google\Service\PolyService\ListLikedAssetsResponse;
21
22/**
23 * The "likedassets" collection of methods.
24 * Typical usage is:
25 *  <code>
26 *   $polyService = new Google\Service\PolyService(...);
27 *   $likedassets = $polyService->likedassets;
28 *  </code>
29 */
30class UsersLikedassets extends \Google\Service\Resource
31{
32  /**
33   * Lists assets that the user has liked. Only the value 'me', representing the
34   * currently-authenticated user, is supported. May include assets with an access
35   * level of UNLISTED. (likedassets.listUsersLikedassets)
36   *
37   * @param string $name A valid user id. Currently, only the special value 'me',
38   * representing the currently-authenticated user is supported. To use 'me', you
39   * must pass an OAuth token with the request.
40   * @param array $optParams Optional parameters.
41   *
42   * @opt_param string format Return only assets with the matching format.
43   * Acceptable values are: `BLOCKS`, `FBX`, `GLTF`, `GLTF2`, `OBJ`, `TILT`.
44   * @opt_param string orderBy Specifies an ordering for assets. Acceptable values
45   * are: `BEST`, `NEWEST`, `OLDEST`, 'LIKED_TIME'. Defaults to `LIKED_TIME`,
46   * which ranks assets based on how recently they were liked.
47   * @opt_param int pageSize The maximum number of assets to be returned. This
48   * value must be between `1` and `100`. Defaults to `20`.
49   * @opt_param string pageToken Specifies a continuation token from a previous
50   * search whose results were split into multiple pages. To get the next page,
51   * submit the same request specifying the value from next_page_token.
52   * @return ListLikedAssetsResponse
53   */
54  public function listUsersLikedassets($name, $optParams = [])
55  {
56    $params = ['name' => $name];
57    $params = array_merge($params, $optParams);
58    return $this->call('list', [$params], ListLikedAssetsResponse::class);
59  }
60}
61
62// Adding a class alias for backwards compatibility with the previous class name.
63class_alias(UsersLikedassets::class, 'Google_Service_PolyService_Resource_UsersLikedassets');
64