From 06f945f27840b53e57795dadbc38e76f7e11ab1c Mon Sep 17 00:00:00 2001 From: Horus3 Date: Mon, 24 Feb 2014 16:42:14 +0100 Subject: init --- .../api/core/files/Gdata.YouTube.html | 466 +++++++++++++++++++++ 1 file changed, 466 insertions(+) create mode 100644 zend/documentation/api/core/files/Gdata.YouTube.html (limited to 'zend/documentation/api/core/files/Gdata.YouTube.html') diff --git a/zend/documentation/api/core/files/Gdata.YouTube.html b/zend/documentation/api/core/files/Gdata.YouTube.html new file mode 100644 index 0000000..96d602c --- /dev/null +++ b/zend/documentation/api/core/files/Gdata.YouTube.html @@ -0,0 +1,466 @@ + +Zend Gdata API Documentation

Gdata/YouTube.php

+ Show: + PublicProtectedPrivateinherited
+ Table of Contents +
Zend Framework

LICENSE

+ +

This source file is subject to the new BSD license that is bundled +with this package in the file LICENSE.txt. +It is also available through the world-wide-web at this URL: +http://framework.zend.com/license/new-bsd +If you did not receive a copy of the license and are unable to +obtain it through the world-wide-web, please send an email +to license@zend.com so we can send you a copy immediately.

Category
Zend +   +
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com) +   +
License
New BSD License +   +
Package
Zend_Gdata +   +
Subpackage
YouTube +   +
Version
$Id: YouTube.php 24796 2012-05-12 03:34:26Z adamlundrigan $ +   +

\Zend_Gdata_YouTube

Package: Zend\Gdata\YouTube
Service class for interacting with the YouTube Data API.

As the Google data API protocol is based upon the Atom Publishing Protocol +(APP), Gdata functionality extends the appropriate Zend_Gdata_App classes

Parent(s)
\Zend_Gdata_Media + < + \Zend_Gdata + < + \Zend_Gdata_App
Category
Zend +   +
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com) +   +
License
New BSD License +   +
Link
http://code.google.com/apis/youtube/ +   +

Constants

>VConstantstring  + AUTH_SERVICE_NAME + = 'youtube'
Service name for use with Google's authentication mechanisms
string

>VConstant  + CLIENTLOGIN_URL + = 'https://www.google.com/youtube/accounts/ClientLogin'
>VConstant  + STANDARD_TOP_RATED_URI + = 'https://gdata.youtube.com/feeds/api/standardfeeds/top_rated'
>VConstant  + STANDARD_MOST_VIEWED_URI + = 'https://gdata.youtube.com/feeds/api/standardfeeds/most_viewed'
>VConstant  + STANDARD_RECENTLY_FEATURED_URI + = 'https://gdata.youtube.com/feeds/api/standardfeeds/recently_featured'
>VConstant  + STANDARD_WATCH_ON_MOBILE_URI + = 'https://gdata.youtube.com/feeds/api/standardfeeds/watch_on_mobile'
>VConstant  + STANDARD_TOP_RATED_URI_V2 + = 'https://gdata.youtube.com/feeds/api/standardfeeds/top_rated'
>VConstant  + STANDARD_MOST_VIEWED_URI_V2 + = 'https://gdata.youtube.com/feeds/api/standardfeeds/most_viewed'
>VConstant  + STANDARD_RECENTLY_FEATURED_URI_V2 + = 'https://gdata.youtube.com/feeds/api/standardfeeds/recently_featured'
>VConstant  + STANDARD_WATCH_ON_MOBILE_URI_V2 + = 'https://gdata.youtube.com/feeds/api/standardfeeds/watch_on_mobile'
>VConstant  + USER_URI + = 'https://gdata.youtube.com/feeds/api/users'
>VConstant  + VIDEO_URI + = 'https://gdata.youtube.com/feeds/api/videos'
>VConstant  + PLAYLIST_REL + = 'http://gdata.youtube.com/schemas/2007#playlist'
>VConstant  + USER_UPLOADS_REL + = 'http://gdata.youtube.com/schemas/2007#user.uploads'
>VConstant  + USER_PLAYLISTS_REL + = 'http://gdata.youtube.com/schemas/2007#user.playlists'
>VConstant  + USER_SUBSCRIPTIONS_REL + = 'http://gdata.youtube.com/schemas/2007#user.subscriptions'
>VConstant  + USER_CONTACTS_REL + = 'http://gdata.youtube.com/schemas/2007#user.contacts'
>VConstant  + USER_FAVORITES_REL + = 'http://gdata.youtube.com/schemas/2007#user.favorites'
>VConstant  + VIDEO_RESPONSES_REL + = 'http://gdata.youtube.com/schemas/2007#video.responses'
>VConstant  + VIDEO_RATINGS_REL + = 'http://gdata.youtube.com/schemas/2007#video.ratings'
>VConstant  + VIDEO_COMPLAINTS_REL + = 'http://gdata.youtube.com/schemas/2007#video.complaints'
>VConstant  + ACTIVITY_FEED_URI + = 'https://gdata.youtube.com/feeds/api/events'
>VConstant  + FRIEND_ACTIVITY_FEED_URI + = 'https://gdata.youtube.com/feeds/api/users/default/friendsactivity'
>VConstantstring  + IN_REPLY_TO_SCHEME + = 'http://gdata.youtube.com/schemas/2007#in-reply-to'
The URI of the in-reply-to schema for comments in reply to +other comments.
string

>VConstantstring  + INBOX_FEED_URI + = 'https://gdata.youtube.com/feeds/api/users/default/inbox'
The URI of the inbox feed for the currently authenticated user.
string

>VConstantinteger  + ACTIVITY_FEED_MAX_USERS + = 20
The maximum number of users for which activity can be requested for, +as enforced by the API.
integer

>VConstantstring  + FAVORITES_URI_SUFFIX + = 'favorites'
The suffix for a feed of favorites.
string

>VConstantstring  + UPLOADS_URI_SUFFIX + = 'uploads'
The suffix for the user's upload feed.
string

>VConstantstring  + RESPONSES_URI_SUFFIX + = 'responses'
The suffix for a feed of video responses.
string

>VConstantstring  + RELATED_URI_SUFFIX + = 'related'
The suffix for a feed of related videos.
string

>VConstantstring  + INBOX_URI_SUFFIX + = 'inbox'
The suffix for a feed of messages (inbox entries).
string

>VConstant  + DEFAULT_MAJOR_PROTOCOL_VERSION + = 1
Inherited_from
\Zend_Gdata_App::DEFAULT_MAJOR_PROTOCOL_VERSION +   +
Inherited_from
\Zend_Gdata::DEFAULT_MAJOR_PROTOCOL_VERSION +   +
Inherited_from
\Zend_Gdata_Media::DEFAULT_MAJOR_PROTOCOL_VERSION +   +
See
\_majorProtocolVersion +   +
>VConstant  + DEFAULT_MINOR_PROTOCOL_VERSION + = null
Inherited_from
\Zend_Gdata_App::DEFAULT_MINOR_PROTOCOL_VERSION +   +
Inherited_from
\Zend_Gdata::DEFAULT_MINOR_PROTOCOL_VERSION +   +
Inherited_from
\Zend_Gdata_Media::DEFAULT_MINOR_PROTOCOL_VERSION +   +
See
\_minorProtocolVersion +   +

Properties

>VPropertyprotectedstring $_defaultPostUri = null
inherited
Default URI to which to POST.
Inherited from: + \Zend_Gdata::$$_defaultPostUri\Zend_Gdata_Media::$$_defaultPostUri
Default valuenullDetails
Type
string
Inherited_from
\Zend_Gdata::$$_defaultPostUri +   +
Inherited_from
\Zend_Gdata_Media::$$_defaultPostUri +   +
>VPropertyprotectedboolean $_gzipEnabled = false
Default valuefalseDetails
Type
boolean
Inherited_from
\Zend_Gdata_App::$$_gzipEnabled +   +
Inherited_from
\Zend_Gdata::$$_gzipEnabled +   +
Inherited_from
\Zend_Gdata_Media::$$_gzipEnabled +   +
>VPropertyprotected\Zend_Gdata_HttpClient $_httpClient
inherited
Client object used to communicate
Inherited from: + \Zend_Gdata::$$_httpClient\Zend_Gdata_Media::$$_httpClient
Details
Type
\Zend_Gdata_HttpClient
Inherited_from
\Zend_Gdata::$$_httpClient +   +
Inherited_from
\Zend_Gdata_Media::$$_httpClient +   +
>VPropertyprotectedboolean $_httpMethodOverride = false
staticinherited
Override HTTP PUT and DELETE request methods?
Inherited from: + \Zend_Gdata_App::$$_httpMethodOverride\Zend_Gdata::$$_httpMethodOverride\Zend_Gdata_Media::$$_httpMethodOverride
Default valuefalseDetails
Type
boolean
Inherited_from
\Zend_Gdata_App::$$_httpMethodOverride +   +
Inherited_from
\Zend_Gdata::$$_httpMethodOverride +   +
Inherited_from
\Zend_Gdata_Media::$$_httpMethodOverride +   +
>VPropertyprotected$_majorProtocolVersion
inherited
Indicates the major protocol version that should be used.
Inherited from: + \Zend_Gdata_App::$$_majorProtocolVersion\Zend_Gdata::$$_majorProtocolVersion\Zend_Gdata_Media::$$_majorProtocolVersion

At present, recognized values are either 1 or 2. However, any integer +value >= 1 is considered valid.

+ +

Under most circumtances, this will be automatically set by +Zend_Gdata_App subclasses.

Details
Type
n/a
Inherited_from
\Zend_Gdata_App::$$_majorProtocolVersion +   +
Inherited_from
\Zend_Gdata::$$_majorProtocolVersion +   +
Inherited_from
\Zend_Gdata_Media::$$_majorProtocolVersion +   +
See
\setMajorProtocolVersion() +   +
See
\getMajorProtocolVersion() +   +
>VPropertyprotectedint $_maxRedirects = 5
staticinherited
Maximum number of redirects to follow during HTTP operations
Inherited from: + \Zend_Gdata_App::$$_maxRedirects\Zend_Gdata::$$_maxRedirects\Zend_Gdata_Media::$$_maxRedirects
Default value5Details
Type
int
Inherited_from
\Zend_Gdata_App::$$_maxRedirects +   +
Inherited_from
\Zend_Gdata::$$_maxRedirects +   +
Inherited_from
\Zend_Gdata_Media::$$_maxRedirects +   +
>VPropertyprotected$_minorProtocolVersion
inherited
Indicates the minor protocol version that should be used.
Inherited from: + \Zend_Gdata_App::$$_minorProtocolVersion\Zend_Gdata::$$_minorProtocolVersion\Zend_Gdata_Media::$$_minorProtocolVersion

Can be set +to either an integer >= 0, or NULL if no minor version should be sent +to the server.

+ +

At present, this field is not used by any Google services, but may be +used in the future.

+ +

Under most circumtances, this will be automatically set by +Zend_Gdata_App subclasses.

Details
Type
n/a
Inherited_from
\Zend_Gdata_App::$$_minorProtocolVersion +   +
Inherited_from
\Zend_Gdata::$$_minorProtocolVersion +   +
Inherited_from
\Zend_Gdata_Media::$$_minorProtocolVersion +   +
See
\setMinorProtocolVersion() +   +
See
\getMinorProtocolVersion() +   +
>VPropertyprotectedarray $_registeredPackages = array('Zend_Gdata_Kind', 'Zend_Gdata_Extension', 'Zend_Gdata', 'Zend_Gdata_App_Extension', 'Zend_Gdata_App')
inherited
Packages to search for classes when using magic __call method, in order.
Inherited from: + \Zend_Gdata::$$_registeredPackages\Zend_Gdata_Media::$$_registeredPackages
Default valuearray('Zend_Gdata_Kind', 'Zend_Gdata_Extension', 'Zend_Gdata', 'Zend_Gdata_App_Extension', 'Zend_Gdata_App')Details
Type
array
Inherited_from
\Zend_Gdata::$$_registeredPackages +   +
Inherited_from
\Zend_Gdata_Media::$$_registeredPackages +   +
>VPropertyprotected\Zend_Gdata_HttpClient $_staticHttpClient = null
staticinherited
Client object used to communicate in static context
Inherited from: + \Zend_Gdata::$$_staticHttpClient\Zend_Gdata_Media::$$_staticHttpClient
Default valuenullDetails
Type
\Zend_Gdata_HttpClient
Inherited_from
\Zend_Gdata::$$_staticHttpClient +   +
Inherited_from
\Zend_Gdata_Media::$$_staticHttpClient +   +
>VPropertyprotectedboolean $_useObjectMapping = true
inherited
Whether we want to use XML to object mapping when fetching data.
Inherited from: + \Zend_Gdata_App::$$_useObjectMapping\Zend_Gdata::$$_useObjectMapping\Zend_Gdata_Media::$$_useObjectMapping
Default valuetrueDetails
Type
boolean
Inherited_from
\Zend_Gdata_App::$$_useObjectMapping +   +
Inherited_from
\Zend_Gdata::$$_useObjectMapping +   +
Inherited_from
\Zend_Gdata_Media::$$_useObjectMapping +   +
>VPropertyprotectedboolean $_verboseExceptionMessages = true

In the case of HTTP errors, +use the body of the HTTP response in the exception message.

Default valuetrueDetails
Type
boolean
Inherited_from
\Zend_Gdata_App::$$_verboseExceptionMessages +   +
Inherited_from
\Zend_Gdata::$$_verboseExceptionMessages +   +
Inherited_from
\Zend_Gdata_Media::$$_verboseExceptionMessages +   +
>VPropertypublicarray $namespaces = array(array('yt', 'http://gdata.youtube.com/schemas/2007', 1, 0), array('georss', 'http://www.georss.org/georss', 1, 0), array('gml', 'http://www.opengis.net/gml', 1, 0), array('media', 'http://search.yahoo.com/mrss/', 1, 0))
static
Namespaces used for Zend_Gdata_YouTube
Default valuearray(array('yt', 'http://gdata.youtube.com/schemas/2007', 1, 0), array('georss', 'http://www.georss.org/georss', 1, 0), array('gml', 'http://www.opengis.net/gml', 1, 0), array('media', 'http://search.yahoo.com/mrss/', 1, 0))Details
Type
array

Methods

methodpublic__call(string $method, array $args) : void
inherited

Provides a magic factory method to instantiate new objects with +shorter syntax than would otherwise be required by the Zend Framework +naming conventions.

Inherited from: + \Zend_Gdata_App::__call()\Zend_Gdata::__call()\Zend_Gdata_Media::__call()

For instance, to construct a new +Zend_Gdata_Calendar_Extension_Color, a developer simply needs to do +$gCal->newColor(). For this magic constructor, packages are searched +in the same order as which they appear in the $_registeredPackages +array

Parameters
NameTypeDescription
$methodstring

The method name being called

$argsarray

The arguments passed to the call

Throws
ExceptionDescription
\Zend_Gdata_App_Exception
methodpublic__construct(\Zend_Http_Client $client = null, string $applicationId = 'MyCompany-MyApp-1.0', string $clientId = null, string $developerKey = null) : void

Create Zend_Gdata_YouTube object

Parameters
NameTypeDescription
$client\Zend_Http_Client

(optional) The HTTP client to use when + when communicating with the Google servers.

+
$applicationIdstring

The identity of the app in the form of + Company-AppName-Version

+
$clientIdstring

The clientId issued by the YouTube dashboard

$developerKeystring

The developerKey issued by the YouTube dashboard

methodpublicdelete(mixed $data,  $remainingRedirects = null) : void
inherited

DELETE entry with client object

Inherited from: + \Zend_Gdata_App::delete()\Zend_Gdata::delete()\Zend_Gdata_Media::delete()
Parameters
NameTypeDescription
$datamixed

The Zend_Gdata_App_Entry or URL to delete

$remainingRedirects
Throws
ExceptionDescription
\Zend_Gdata_App_Exception
\Zend_Gdata_App_HttpException
\Zend_Gdata_App_InvalidArgumentException
methodpublicenableRequestDebugLogging(string $logfile) : void
inherited

This method enables logging of requests by changing the +Zend_Http_Client_Adapter used for performing the requests.

Inherited from: + \Zend_Gdata_App::enableRequestDebugLogging()\Zend_Gdata::enableRequestDebugLogging()\Zend_Gdata_Media::enableRequestDebugLogging()

NOTE: This will not work if you have customized the adapter +already to use a proxy server or other interface.

Parameters
NameTypeDescription
$logfilestring

The logfile to use when logging the requests

methodpublicgenerateIfMatchHeaderData( $data,  $allowWeek) : string | null
inherited

Returns the data for an If-Match header based on the current Etag +property.

Inherited from: + \Zend_Gdata_App::generateIfMatchHeaderData()\Zend_Gdata::generateIfMatchHeaderData()\Zend_Gdata_Media::generateIfMatchHeaderData()

If Etags are not supported by the server or cannot be +extracted from the data, then null will be returned.

Parameters
NameTypeDescription
$data
$allowWeek
Returns
TypeDescription
string | null$data
methodpublicget(string $uri, array $extraHeaders = array()) : \Zend_Http_Response
inherited

GET a URI using client object.

Inherited from: + \Zend_Gdata_App::get()\Zend_Gdata::get()\Zend_Gdata_Media::get()
Parameters
NameTypeDescription
$uristring

GET URI

$extraHeadersarray

Extra headers to add to the request, as an + array of string-based key/value pairs.

+
Returns
TypeDescription
\Zend_Http_Response
Throws
ExceptionDescription
\Zend_Gdata_App_HttpException
methodpublicgetActivityForUser( $username) : \Zend_Gdata_YouTube_ActivityFeed

Retrieves the activity feed for users

Parameters
NameTypeDescription
$username
Returns
TypeDescription
\Zend_Gdata_YouTube_ActivityFeed
Throws
ExceptionDescription
\Zend_Gdata_App_VersionExceptionif using version less than 2.
methodpublicgetContactFeed(string $user = null, mixed $location = null) : \Zend_Gdata_YouTube_ContactFeed

Retrieves a feed of a user's contacts

Parameters
NameTypeDescription
$userstring

(optional) The username of interest

+
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_ContactFeedThe feed of contacts
methodpublicgetEntry(mixed $location,  $className = 'Zend_Gdata_Entry') : string | \Zend_Gdata_App_Entry
inherited

Retrieve entry as string or object

Inherited from: + \Zend_Gdata::getEntry()\Zend_Gdata_Media::getEntry()
Parameters
NameTypeDescription
$locationmixed

The location as string or Zend_Gdata_Query

$className
Returns
TypeDescription
string | \Zend_Gdata_App_EntryReturns string only if the object + mapping has been disabled explicitly + by passing false to the + useObjectMapping() function.
Throws
ExceptionDescription
\Zend_Gdata_App_InvalidArgumentException
methodpublicgetFeed(mixed $location, string $className = 'Zend_Gdata_Feed') : string | \Zend_Gdata_App_Feed
inherited

Retrieve feed as string or object

Inherited from: + \Zend_Gdata::getFeed()\Zend_Gdata_Media::getFeed()
Parameters
NameTypeDescription
$locationmixed

The location as string or Zend_Gdata_Query

$classNamestring

The class type to use for returning the feed

Returns
TypeDescription
string | \Zend_Gdata_App_FeedReturns string only if the object + mapping has been disabled explicitly + by passing false to the + useObjectMapping() function.
Throws
ExceptionDescription
\Zend_Gdata_App_InvalidArgumentException
methodpublicgetFormUploadToken(\Zend_Gdata_YouTube_VideoEntry $videoEntry, string $url = 'https://gdata.youtube.com/action/GetUploadToken') : array

Retrieves a YouTube token

Parameters
NameTypeDescription
$videoEntry\Zend_Gdata_YouTube_VideoEntry

The video entry

$urlstring

The location as a string URL

Returns
TypeDescription
arrayAn array containing a token and URL
Throws
ExceptionDescription
\Zend_Gdata_App_Exception
methodpublicgetFriendActivityForCurrentUser() : \Zend_Gdata_YouTube_ActivityFeed

Retrieve the activity of the currently authenticated users friend.

Returns
TypeDescription
\Zend_Gdata_YouTube_ActivityFeed
Throws
ExceptionDescription
\Zend_Gdata_App_Exceptionif not logged in.
methodpublicgetFullVideoEntry( $videoId) : \Zend_Gdata_YouTube_VideoEntry | null

Retrieves a video entry from the user's upload feed.

Parameters
NameTypeDescription
$videoId
Returns
TypeDescription
\Zend_Gdata_YouTube_VideoEntry | nullThe video entry to be + retrieved, or null if it was not found or the user requesting it + did not have the appropriate permissions.
Throws
ExceptionDescription
\Zend_Gdata_App_HttpException
methodpublicgetGzipEnabled() : boolean
Returns
TypeDescription
boolean
methodpublicgetHttpClient() : \Zend_Http_Client
inherited

Get the Zend_Http_Client object used for communication

Inherited from: + \Zend_Gdata_App::getHttpClient()\Zend_Gdata::getHttpClient()\Zend_Gdata_Media::getHttpClient()
Returns
TypeDescription
\Zend_Http_Client
methodpublicgetHttpMethodOverride() : boolean
Returns
TypeDescription
boolean
methodpublicgetInboxFeedForCurrentUser() : \Zend_Gdata_YouTube_InboxFeed | null

Retrieve a feed of messages in the currently authenticated user's inbox.

Returns
TypeDescription
\Zend_Gdata_YouTube_InboxFeed | null
Throws
ExceptionDescription
\Zend_Gdata_App_Exceptionif not logged in.
methodpublicgetMajorProtocolVersion() : int
Returns
TypeDescription
intThe major protocol version in use.
Details
See
\_majorProtocolVersion +   +
methodpublicgetMaxRedirects() : int
staticinherited

Get the maximum number of redirects to follow during HTTP operations

Inherited from: + \Zend_Gdata_App::getMaxRedirects()\Zend_Gdata::getMaxRedirects()\Zend_Gdata_Media::getMaxRedirects()
Returns
TypeDescription
intMaximum number of redirects to follow
methodpublicgetMinorProtocolVersion() : \(int | \NULL)
Returns
TypeDescription
\(int | \NULL)The major protocol version in use, or NULL if no + minor version is specified.
Details
See
\_minorProtocolVersion +   +
methodpublicgetMostViewedVideoFeed(mixed $location = null) : \Zend_Gdata_YouTube_VideoFeed

Retrieves a feed of the most viewed videos.

Parameters
NameTypeDescription
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_VideoFeedThe feed of videos found at the + specified URL.
methodpublicgetNextFeed(\Zend_Gdata_App_Feed $feed, string $className = null) : \Zend_Gdata_App_Feed | null
inherited

Retrieve next set of results based on a given feed.

Inherited from: + \Zend_Gdata_App::getNextFeed()\Zend_Gdata::getNextFeed()\Zend_Gdata_Media::getNextFeed()
Parameters
NameTypeDescription
$feed\Zend_Gdata_App_Feed

The feed from which to + retreive the next set of results.

$classNamestring

(optional) The class of feed to be returned. + If null, the next feed (if found) will be the same class as + the feed that was given as the first argument.

+
Returns
TypeDescription
\Zend_Gdata_App_Feed | nullReturns a + Zend_Gdata_App_Feed or null if no next set of results + exists.
methodpublicgetPlaylistListFeed(string $user = null, mixed $location = null) : \Zend_Gdata_YouTube_PlaylistListFeed

Retrieves a feed which lists a user's playlist

Parameters
NameTypeDescription
$userstring

(optional) The username of interest

+
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_PlaylistListFeedThe feed of playlists
methodpublicgetPlaylistVideoFeed(mixed $location) : \Zend_Gdata_YouTube_PlaylistVideoFeed

Retrieves a feed of videos in a particular playlist

Parameters
NameTypeDescription
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_PlaylistVideoFeedThe feed of videos found at + the specified URL.
methodpublicgetPreviousFeed(\Zend_Gdata_App_Feed $feed, string $className = null) : \Zend_Gdata_App_Feed | null
inherited

Retrieve previous set of results based on a given feed.

Inherited from: + \Zend_Gdata_App::getPreviousFeed()\Zend_Gdata::getPreviousFeed()\Zend_Gdata_Media::getPreviousFeed()
Parameters
NameTypeDescription
$feed\Zend_Gdata_App_Feed

The feed from which to + retreive the previous set of results.

$classNamestring

(optional) The class of feed to be returned. + If null, the previous feed (if found) will be the same class as + the feed that was given as the first argument.

+
Returns
TypeDescription
\Zend_Gdata_App_Feed | nullReturns a + Zend_Gdata_App_Feed or null if no previous set of results + exists.
methodpublicgetRecentlyFeaturedVideoFeed(mixed $location = null) : \Zend_Gdata_YouTube_VideoFeed

Retrieves a feed of recently featured videos.

Parameters
NameTypeDescription
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_VideoFeedThe feed of videos found at the + specified URL.
methodpublicgetRelatedVideoFeed(string $videoId = null, mixed $location = null) : \Zend_Gdata_YouTube_VideoFeed

Retrieves a feed of videos related to the specified video ID.

Parameters
NameTypeDescription
$videoIdstring

The videoId of interest

$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_VideoFeedThe feed of videos found at the + specified URL.
methodpublicgetStaticHttpClient() : \Zend_Http_Client

If none is set, a new Zend_Http_Client will be used.

Returns
TypeDescription
\Zend_Http_Client
methodpublicgetSubscriptionFeed(string $user = null, mixed $location = null) : \Zend_Gdata_YouTube_SubscriptionListFeed

Retrieves a feed of a user's subscriptions

Parameters
NameTypeDescription
$userstring

(optional) The username of interest

+
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_SubscriptionListFeedThe feed of subscriptions
methodpublicgetTopRatedVideoFeed(mixed $location = null) : \Zend_Gdata_YouTube_CommentFeed

Retrieves a feed of comments related to the specified video ID.

Parameters
NameTypeDescription
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_CommentFeedThe feed of videos found at the + specified URL.
methodpublicgetUserFavorites(string $user = null, mixed $location = null) : \Zend_Gdata_YouTube_VideoFeed

Retrieves a user's favorites

Parameters
NameTypeDescription
$userstring

(optional) The username of interest

+
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_VideoFeedThe videos favorited by the user
methodpublicgetUserProfile(string $user = null, mixed $location = null) : \Zend_Gdata_YouTube_UserProfileEntry

Retrieves a user's profile as an entry

Parameters
NameTypeDescription
$userstring

(optional) The username of interest

+
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_UserProfileEntryThe user profile entry
methodpublicgetUserUploads(string $user = null, mixed $location = null) : \Zend_Gdata_YouTube_VideoFeed

Retrieves a user's uploads

Parameters
NameTypeDescription
$userstring

(optional) The username of interest

+
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_VideoFeedThe videos uploaded by the user
methodpublicgetVerboseExceptionMessages() : boolean

In the case of HTTP errors, use the body of the HTTP response +in the exception message.

Returns
TypeDescription
boolean
methodpublicgetVideoCommentFeed(string $videoId = null, mixed $location = null) : \Zend_Gdata_YouTube_CommentFeed

Retrieves a feed of comments related to the specified video ID.

Parameters
NameTypeDescription
$videoIdstring

The videoId of interest

$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_CommentFeedThe feed of videos found at the + specified URL.
methodpublicgetVideoEntry(mixed $videoId = null, mixed $location = null, boolean $fullEntry = false) : \Zend_Gdata_YouTube_VideoEntry

Retrieves a specific video entry.

Parameters
NameTypeDescription
$videoIdmixed

The ID of the video to retrieve.

$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined.

+
$fullEntryboolean

(optional) Retrieve the full metadata for the + entry. Only possible if entry belongs to currently authenticated + user. An exception will be thrown otherwise.

+
Returns
TypeDescription
\Zend_Gdata_YouTube_VideoEntryThe video entry found at the + specified URL.
Throws
ExceptionDescription
\Zend_Gdata_App_HttpException
methodpublicgetVideoFeed(mixed $location = null) : \Zend_Gdata_YouTube_VideoFeed

Retrieves a feed of videos.

Parameters
NameTypeDescription
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_VideoFeedThe feed of videos found at the + specified URL.
methodpublicgetVideoResponseFeed(string $videoId = null, mixed $location = null) : \Zend_Gdata_YouTube_VideoFeed

Retrieves a feed of video responses related to the specified video ID.

Parameters
NameTypeDescription
$videoIdstring

The videoId of interest

$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_VideoFeedThe feed of videos found at the + specified URL.
methodpublicgetWatchOnMobileVideoFeed(mixed $location = null) : \Zend_Gdata_YouTube_VideoFeed

Retrieves a feed of videos recently featured for mobile devices.

These videos will have RTSP links in the $entry->mediaGroup->content

Parameters
NameTypeDescription
$locationmixed

(optional) The URL to query or a + Zend_Gdata_Query object from which a URL can be determined

+
Returns
TypeDescription
\Zend_Gdata_YouTube_VideoFeedThe feed of videos found at the + specified URL.
methodpublicimport(string $uri, \Zend_Http_Client $client = null, string $className = 'Zend_Gdata_Feed') : string | \Zend_Gdata_App_Feed
staticinherited

Imports a feed located at $uri.

Inherited from: + \Zend_Gdata::import()\Zend_Gdata_Media::import()
Parameters
NameTypeDescription
$uristring
$client\Zend_Http_Client

The client used for communication

$classNamestring

The class which is used as the return type

Returns
TypeDescription
string | \Zend_Gdata_App_FeedReturns string only if the object + mapping has been disabled explicitly + by passing false to the + useObjectMapping() function.
Throws
ExceptionDescription
\Zend_Gdata_App_Exception
methodpublicimportFile(string $filename, string $className = 'Zend_Gdata_App_Feed', string $useIncludePath = false) : \Zend_Gdata_App_Feed
staticinherited

Imports a feed from a file located at $filename.

Inherited from: + \Zend_Gdata_App::importFile()\Zend_Gdata::importFile()\Zend_Gdata_Media::importFile()
Parameters
NameTypeDescription
$filenamestring
$classNamestring

The class which is used as the return type

$useIncludePathstring

Whether the include_path should be searched

Returns
TypeDescription
\Zend_Gdata_App_Feed
Throws
ExceptionDescription
\Zend_Gdata_App_Exception
methodpublicimportString(string $string, string $className = 'Zend_Gdata_App_Feed',  $majorProtocolVersion = null,  $minorProtocolVersion = null) : \Zend_Gdata_App_Feed
staticinherited

Imports a feed represented by $string.

Inherited from: + \Zend_Gdata_App::importString()\Zend_Gdata::importString()\Zend_Gdata_Media::importString()
Parameters
NameTypeDescription
$stringstring
$classNamestring

The class which is used as the return type

$majorProtocolVersion
$minorProtocolVersion
Returns
TypeDescription
\Zend_Gdata_App_Feed
Throws
ExceptionDescription
\Zend_Gdata_App_Exception
methodpublicimportUrl(string $url, string $className = 'Zend_Gdata_App_Feed', array $extraHeaders = array()) : string | \Zend_Gdata_App_Feed
inherited

Imports the specified URL (non-statically).

Inherited from: + \Zend_Gdata_App::importUrl()\Zend_Gdata::importUrl()\Zend_Gdata_Media::importUrl()
Parameters
NameTypeDescription
$urlstring

The URL to import

$classNamestring

The class which is used as the return type

$extraHeadersarray

Extra headers to add to the request, as an + array of string-based key/value pairs.

+
Returns
TypeDescription
string | \Zend_Gdata_App_FeedReturns string only if the object + mapping has been disabled explicitly + by passing false to the + useObjectMapping() function.
Throws
ExceptionDescription
\Zend_Gdata_App_Exception
methodpublicinsertEntry(mixed $data, string $uri, string $className = 'Zend_Gdata_App_Entry', array $extraHeaders = array()) : \Zend_Gdata_App_Entry
inherited

Inserts an entry to a given URI and returns the response as a +fully formed Entry.

Inherited from: + \Zend_Gdata_App::insertEntry()\Zend_Gdata::insertEntry()\Zend_Gdata_Media::insertEntry()
Parameters
NameTypeDescription
$datamixed

The Zend_Gdata_App_Entry or XML to post

$uristring

POST URI

$classNamestring

The class of entry to be returned.

$extraHeadersarray

Extra headers to add to the request, as an + array of string-based key/value pairs.

+
Returns
TypeDescription
\Zend_Gdata_App_EntryThe entry returned by the service after + insertion.
methodpublicisAuthenticated() : boolean
inherited

Determines whether service object is authenticated.

Inherited from: + \Zend_Gdata::isAuthenticated()\Zend_Gdata_Media::isAuthenticated()
Returns
TypeDescription
booleanTrue if service object is authenticated, false otherwise.
methodpublicparseFormUploadTokenResponse(string $response) : array
static

Helper function for parsing a YouTube token response

Parameters
NameTypeDescription
$responsestring

The service response

Returns
TypeDescription
arrayAn array containing the token and URL
Throws
ExceptionDescription
\Zend_Gdata_App_Exception
methodpublicperformHttpRequest(string $method, string $url, array $headers = array(), string $body = null, string $contentType = null, int $remainingRedirects = null) : \Zend_Http_Response
inherited

Performs a HTTP request using the specified method.

Inherited from: + \Zend_Gdata::performHttpRequest()\Zend_Gdata_Media::performHttpRequest()

Overrides the definition in the parent (Zend_Gdata_App) +and uses the Zend_Gdata_HttpClient functionality +to filter the HTTP requests and responses.

Parameters
NameTypeDescription
$methodstring

The HTTP method for the request - + 'GET', 'POST', 'PUT', 'DELETE'

+
$urlstring

The URL to which this request is being performed, + or null if found in $data

+
$headersarray

An associative array of HTTP headers + for this request

$bodystring

The body of the HTTP request

$contentTypestring

The value for the content type of the + request body

$remainingRedirectsint

Number of redirects to follow + if requests results in one

Returns
TypeDescription
\Zend_Http_ResponseThe response object
methodpublicpost(mixed $data, string $uri = null,  $remainingRedirects = null, string $contentType = null, array $extraHeaders = null) : \Zend_Http_Response
inherited

POST data with client object

Inherited from: + \Zend_Gdata_App::post()\Zend_Gdata::post()\Zend_Gdata_Media::post()
Parameters
NameTypeDescription
$datamixed

The Zend_Gdata_App_Entry or XML to post

$uristring

POST URI

$remainingRedirects
$contentTypestring

Content-type of the data

+
$extraHeadersarray

Extra headers to add to the request, as an + array of string-based key/value pairs.

+
Returns
TypeDescription
\Zend_Http_Response
Throws
ExceptionDescription
\Zend_Gdata_App_Exception
\Zend_Gdata_App_HttpException
\Zend_Gdata_App_InvalidArgumentException
methodpublicprepareRequest(string $method, string $url = null, array $headers = array(), mixed $data = null, string $contentTypeOverride = null) : array
inherited

Provides pre-processing for HTTP requests to APP services.

Inherited from: + \Zend_Gdata_App::prepareRequest()\Zend_Gdata::prepareRequest()\Zend_Gdata_Media::prepareRequest()
    +
  1. Checks the $data element and, if it's an entry, extracts the XML, +multipart data, edit link (PUT,DELETE), etc.
  2. +
  3. If $data is a string, sets the default content-type header as +'application/atom+xml' if it's not already been set.
  4. +
  5. Adds a x-http-method override header and changes the HTTP method +to 'POST' if necessary as per getHttpMethodOverride()
  6. +
Parameters
NameTypeDescription
$methodstring

The HTTP method for the request - 'GET', 'POST', + 'PUT', 'DELETE'

+
$urlstring

The URL to which this request is being performed, + or null if found in $data

+
$headersarray

An associative array of HTTP headers for this + request

$datamixed

The Zend_Gdata_App_Entry or XML for the + body of the request

$contentTypeOverridestring

The override value for the + content type of the request body

Returns
TypeDescription
arrayAn associative array containing the determined + 'method', 'url', 'data', 'headers', 'contentType'
methodpublicput(mixed $data, string $uri = null,  $remainingRedirects = null, string $contentType = null, array $extraHeaders = null) : \Zend_Http_Response
inherited

PUT data with client object

Inherited from: + \Zend_Gdata_App::put()\Zend_Gdata::put()\Zend_Gdata_Media::put()
Parameters
NameTypeDescription
$datamixed

The Zend_Gdata_App_Entry or XML to post

$uristring

PUT URI

$remainingRedirects
$contentTypestring

Content-type of the data

+
$extraHeadersarray

Extra headers to add to the request, as an + array of string-based key/value pairs.

+
Returns
TypeDescription
\Zend_Http_Response
Throws
ExceptionDescription
\Zend_Gdata_App_Exception
\Zend_Gdata_App_HttpException
\Zend_Gdata_App_InvalidArgumentException
methodpublicregisterPackage(string $name) : void
inherited

Adds a Zend Framework package to the $_registeredPackages array.

Inherited from: + \Zend_Gdata_App::registerPackage()\Zend_Gdata::registerPackage()\Zend_Gdata_Media::registerPackage()

This array is searched when using the magic __call method below +to instantiante new objects.

Parameters
NameTypeDescription
$namestring

The name of the package (eg Zend_Gdata_App)

+
methodpublicreplyToCommentEntry(\Zend_Gdata_YouTube_CommentEntry $commentEntry, string $commentText) : \Zend_Gdata_YouTube_CommentEntry

Post a comment in reply to an existing comment

Parameters
NameTypeDescription
$commentEntry\Zend_Gdata_YouTube_CommentEntry

The comment entry + to reply to

$commentTextstring

The text of the + comment to post

Returns
TypeDescription
\Zend_Gdata_YouTube_CommentEntrythe posted comment
methodpublicretrieveAllEntriesForFeed(object $feed) : mixed
inherited

Retrieve all entries for a feed, iterating through pages as necessary.

Inherited from: + \Zend_Gdata_App::retrieveAllEntriesForFeed()\Zend_Gdata::retrieveAllEntriesForFeed()\Zend_Gdata_Media::retrieveAllEntriesForFeed()

Be aware that calling this function on a large dataset will take a +significant amount of time to complete. In some cases this may cause +execution to timeout without proper precautions in place.

Parameters
NameTypeDescription
$feedobject

The feed to iterate through.

Returns
TypeDescription
mixedA new feed of the same type as the one originally + passed in, containing all relevent entries.
methodpublicsendVideoMessage(string $body, \Zend_Gdata_YouTube_VideoEntry $videoEntry = null, string $videoId = null, string $recipientUserName) : \Zend_Gdata_YouTube_InboxEntry | null

Send a video message.

Note: Either a Zend_Gdata_YouTube_VideoEntry or a valid video ID must +be provided.

Parameters
NameTypeDescription
$bodystring

The body of the message

$videoEntry\Zend_Gdata_YouTube_VideoEntry

(optional) The video entry to send

+
$videoIdstring

The id of the video to send

$recipientUserNamestring

The username of the recipient

Returns
TypeDescription
\Zend_Gdata_YouTube_InboxEntry | nullThe + Zend_Gdata_YouTube_Inbox_Entry representing the sent message.
Throws
ExceptionDescription
\Zend_Gdata_App_InvalidArgumentExceptionif no valid + Zend_Gdata_YouTube_VideoEntry or videoId were provided
methodpublicsetGzipEnabled(boolean $enabled = false) : void
staticinherited

Toggle requesting gzip encoded responses

Inherited from: + \Zend_Gdata_App::setGzipEnabled()\Zend_Gdata::setGzipEnabled()\Zend_Gdata_Media::setGzipEnabled()
Parameters
NameTypeDescription
$enabledboolean

Whether or not to enable gzipped responses

methodpublicsetHttpClient(\Zend_Http_Client $client,  $applicationId = 'MyCompany-MyApp-1.0',  $clientId = null,  $developerKey = null) : \Zend_Gdata_App

Set the Zend_Http_Client object used for communication

Parameters
NameTypeDescription
$client\Zend_Http_Client

The client to use for communication

$applicationId
$clientId
$developerKey
Returns
TypeDescription
\Zend_Gdata_AppProvides a fluent interface
Throws
ExceptionDescription
\Zend_Gdata_App_HttpException
methodpublicsetHttpMethodOverride(boolean $override = true) : void
staticinherited

Toggle using POST instead of PUT and DELETE HTTP methods

Inherited from: + \Zend_Gdata_App::setHttpMethodOverride()\Zend_Gdata::setHttpMethodOverride()\Zend_Gdata_Media::setHttpMethodOverride()

Some feed implementations do not accept PUT and DELETE HTTP +methods, or they can't be used because of proxies or other +measures. This allows turning on using POST where PUT and +DELETE would normally be used; in addition, an +X-Method-Override header will be sent with a value of PUT or +DELETE as appropriate.

Parameters
NameTypeDescription
$overrideboolean

Whether to override PUT and DELETE with POST.

methodpublicsetMajorProtocolVersion(int $value) : void

Values < 1 will +cause a Zend_Gdata_App_InvalidArgumentException to be thrown.

Parameters
NameTypeDescription
$valueint

The major protocol version to use.

Throws
ExceptionDescription
\Zend_Gdata_App_InvalidArgumentException
Details
See
\_majorProtocolVersion +   +
methodpublicsetMaxRedirects(int $maxRedirects) : void
staticinherited

Set the maximum number of redirects to follow during HTTP operations

Inherited from: + \Zend_Gdata_App::setMaxRedirects()\Zend_Gdata::setMaxRedirects()\Zend_Gdata_Media::setMaxRedirects()
Parameters
NameTypeDescription
$maxRedirectsint

Maximum number of redirects to follow

methodpublicsetMinorProtocolVersion(\(int | \NULL) $value) : void

If set to NULL, no +minor protocol version will be sent to the server. Values < 0 will +cause a Zend_Gdata_App_InvalidArgumentException to be thrown.

Parameters
NameTypeDescription
$value\(int | \NULL)

The minor protocol version to use.

Throws
ExceptionDescription
\Zend_Gdata_App_InvalidArgumentException
Details
See
\_minorProtocolVersion +   +
methodpublicsetStaticHttpClient(\Zend_Http_Client $httpClient) : void

Sets the static HTTP client object to use for retrieving the feed.

Parameters
NameTypeDescription
$httpClient\Zend_Http_Client
methodpublicsetVerboseExceptionMessages(boolean $verbose) : void

In the case of HTTP errors, use the body of the HTTP response +in the exception message.

Parameters
NameTypeDescription
$verboseboolean

Whether to use verbose exception messages

methodpublicupdateEntry(mixed $data, string | null $uri = null, string | null $className = null, array $extraHeaders = array()) : \Zend_Gdata_App_Entry
Parameters
NameTypeDescription
$datamixed

Zend_Gdata_App_Entry or XML (w/ID and link rel='edit')

+
$uristring | null

The URI to send requests to, or null if $data + contains the URI.

+
$classNamestring | null

The name of the class that should be deserialized + from the server response. If null, then 'Zend_Gdata_App_Entry' + will be used.

+
$extraHeadersarray

Extra headers to add to the request, as an + array of string-based key/value pairs.

+
Returns
TypeDescription
\Zend_Gdata_App_EntryThe entry returned from the server
Throws
ExceptionDescription
\Zend_Gdata_App_Exception
methodpublicuseObjectMapping(boolean $value) : void
inherited

Enable/disable the use of XML to object mapping.

Inherited from: + \Zend_Gdata_App::useObjectMapping()\Zend_Gdata::useObjectMapping()\Zend_Gdata_Media::useObjectMapping()
Parameters
NameTypeDescription
$valueboolean

Pass in true to use the XML to object mapping. + Pass in false or null to disable it.

methodpublicusingObjectMapping() : boolean
inherited

Determine whether service object is using XML to object mapping.

Inherited from: + \Zend_Gdata_App::usingObjectMapping()\Zend_Gdata::usingObjectMapping()\Zend_Gdata_Media::usingObjectMapping()
Returns
TypeDescription
booleanTrue if service object is using XML to object mapping, + false otherwise.
+ Documentation was generated by + phpDocumentor + 2.0.0a12. + -- cgit v1.2.3