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/**
19 * The "thumbnails" collection of methods.
20 * Typical usage is:
21 *  <code>
22 *   $youtubeService = new Google_Service_YouTube(...);
23 *   $thumbnails = $youtubeService->thumbnails;
24 *  </code>
25 */
26class Google_Service_YouTube_Resource_Thumbnails extends Google_Service_Resource
27{
28  /**
29   * As this is not an insert in a strict sense (it supports uploading/setting of
30   * a thumbnail for multiple videos, which doesn't result in creation of a single
31   * resource), I use a custom verb here. (thumbnails.set)
32   *
33   * @param string $videoId Returns the Thumbnail with the given video IDs for
34   * Stubby or Apiary.
35   * @param array $optParams Optional parameters.
36   *
37   * @opt_param string onBehalfOfContentOwner *Note:* This parameter is intended
38   * exclusively for YouTube content partners. The *onBehalfOfContentOwner*
39   * parameter indicates that the request's authorization credentials identify a
40   * YouTube CMS user who is acting on behalf of the content owner specified in
41   * the parameter value. This parameter is intended for YouTube content partners
42   * that own and manage many different YouTube channels. It allows content owners
43   * to authenticate once and get access to all their video and channel data,
44   * without having to provide authentication credentials for each individual
45   * channel. The actual CMS account that the user authenticates with must be
46   * linked to the specified YouTube content owner.
47   * @return Google_Service_YouTube_ThumbnailSetResponse
48   */
49  public function set($videoId, $optParams = array())
50  {
51    $params = array('videoId' => $videoId);
52    $params = array_merge($params, $optParams);
53    return $this->call('set', array($params), "Google_Service_YouTube_ThumbnailSetResponse");
54  }
55}
56