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.
enableRequestDebugLogging(
$logfile $logfile
)
:
This method enables logging of requests by changing the Zend_Http_Client_Adapter used for performing the requests.
NOTE: This will not work if you have customized the adapter already to use a proxy server or other interface.
generateIfMatchHeaderData(
$data, $allowWeek
)
:
string|null
Returns the data for an If-Match header based on the current Etag property. If Etags are not supported by the server or cannot be extracted from the data, then null will be returned.
getNextFeed(
Zend_Gdata_App_Feed $feed, string $className
=
null
)
:
Zend_Gdata_App_Feed|null
Retrieve next set of results based on a given feed.
getPreviousFeed(
Zend_Gdata_App_Feed $feed, string $className
=
null
)
:
Zend_Gdata_App_Feed|null
Retrieve previous set of results based on a given feed.
retrieveAllEntriesForFeed(
$feed $feed
)
:
mixed
Retrieve all entries for a feed, iterating through pages as necessary.
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.
useObjectMapping(
boolean $value
)
:
void
Enable/disable the use of XML to object mapping.
usingObjectMapping(
)
:
boolean
Determine whether service object is using XML to object mapping.
Provides Atom Publishing Protocol (APP) functionality. This class and all other components of Zend_Gdata_App are designed to work independently from other Zend_Gdata components in order to interact with generic APP services.
DEFAULT_MAJOR_PROTOCOL_VERSION = '1'
Default major protocol version.
DEFAULT_MINOR_PROTOCOL_VERSION = 'null'
Default minor protocol version.
string $_defaultPostUri = 'null'
Default URI to which to POST.
boolean $_gzipEnabled = 'false'
Enable gzipped responses?
Zend_Http_Client $_httpClient = ''
Client object used to communicate
boolean $_httpMethodOverride = 'false'
Override HTTP PUT and DELETE request methods?
$_majorProtocolVersion = ''
Indicates the major protocol version that should be used.
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.
int $_maxRedirects = '5'
Maximum number of redirects to follow during HTTP operations
$_minorProtocolVersion = ''
Indicates the minor protocol version that should be used. 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.
array $_registeredPackages = 'array'
Packages to search for classes when using magic __call method, in order.
Zend_Http_Client $_staticHttpClient = 'null'
Client object used to communicate in static context
boolean $_useObjectMapping = 'true'
Whether we want to use XML to object mapping when fetching data.
boolean $_verboseExceptionMessages = 'true'
Use verbose exception messages. In the case of HTTP errors, use the body of the HTTP response in the exception message.
__call(
string $method, array $args
)
:
Provides a magic factory method to instantiate new objects with shorter syntax than would otherwise be required by the Zend Framework naming conventions. 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
__construct(
Zend_Http_Client $client
=
null, string $applicationId
=
MyCompany-MyApp-1.0
)
:
Create Gdata object
delete(
mixed $data, $remainingRedirects
=
null
)
:
void
DELETE entry with client object
get(
string $uri, array $extraHeaders
=
array
)
:
Zend_Http_Response
GET a URI using client object.
getEntry(
string $uri, string $className
=
Zend_Gdata_App_Entry
)
:
string|Zend_Gdata_App_Entry
Retrieve entry as string or object
getFeed(
string $uri, string $className
=
Zend_Gdata_App_Feed
)
:
string|Zend_Gdata_App_Feed
Retrieve feed as string or object
getGzipEnabled(
)
:
boolean
Get the HTTP override state
getHttpClient(
)
:
Zend_Http_Client
Get the Zend_Http_Client object used for communication
getHttpMethodOverride(
)
:
boolean
Get the HTTP override state
getMajorProtocolVersion(
)
:
int
Get the major protocol version that is in use.
getMaxRedirects(
)
:
int
Get the maximum number of redirects to follow during HTTP operations
getMinorProtocolVersion(
)
:
(int|NULL)
Get the minor protocol version that is in use.
getStaticHttpClient(
)
:
Zend_Http_Client
Gets the HTTP client object. If none is set, a new Zend_Http_Client will be used.
getVerboseExceptionMessages(
)
:
boolean
Get whether to use verbose exception messages
In the case of HTTP errors, use the body of the HTTP response in the exception message.
import(
string $uri, Zend_Http_Client $client
=
null, string $className
=
Zend_Gdata_App_Feed
)
:
string|Zend_Gdata_App_Feed
Imports a feed located at $uri.
importFile(
string $filename, string $className
=
Zend_Gdata_App_Feed, string $useIncludePath
=
false
)
:
Zend_Gdata_App_Feed
Imports a feed from a file located at $filename.
importString(
string $string, string $className
=
Zend_Gdata_App_Feed, $majorProtocolVersion
=
null, $minorProtocolVersion
=
null
)
:
Zend_Gdata_App_Feed
Imports a feed represented by $string.
importUrl(
string $url, string $className
=
Zend_Gdata_App_Feed, array $extraHeaders
=
array
)
:
string|Zend_Gdata_App_Feed
Imports the specified URL (non-statically).
insertEntry(
mixed $data, string $uri, string $className
=
Zend_Gdata_App_Entry, array $extraHeaders
=
array
)
:
Zend_Gdata_App_Entry
Inserts an entry to a given URI and returns the response as a fully formed Entry.
performHttpRequest(
string $method, string $url, array $headers
=
null, string $body
=
null, string $contentType
=
null, int $remainingRedirects
=
null
)
:
Zend_Http_Response
Performs a HTTP request using the specified method
post(
mixed $data, string $uri
=
null, $remainingRedirects
=
null, string $contentType
=
null, array $extraHeaders
=
null
)
:
Zend_Http_Response
POST data with client object
prepareRequest(
string $method, string $url
=
null, array $headers
=
array, mixed $data
=
null, string $contentTypeOverride
=
null
)
:
array
Provides pre-processing for HTTP requests to APP services.
put(
mixed $data, string $uri
=
null, $remainingRedirects
=
null, string $contentType
=
null, array $extraHeaders
=
null
)
:
Zend_Http_Response
PUT data with client object
registerPackage(
string $name
)
:
void
Adds a Zend Framework package to the $_registeredPackages array.
This array is searched when using the magic __call method below to instantiante new objects.
setGzipEnabled(
boolean $enabled
=
false
)
:
void
Toggle requesting gzip encoded responses
setHttpClient(
Zend_Http_Client $client, $applicationId
=
MyCompany-MyApp-1.0
)
:
Zend_Gdata_App
Set the Zend_Http_Client object used for communication
setHttpMethodOverride(
boolean $override
=
true
)
:
void
Toggle using POST instead of PUT and DELETE HTTP methods
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.
setMajorProtocolVersion(
int $value
)
:
Set the major protocol version that should be used. Values < 1 will cause a Zend_Gdata_App_InvalidArgumentException to be thrown.
setMaxRedirects(
int $maxRedirects
)
:
void
Set the maximum number of redirects to follow during HTTP operations
setMinorProtocolVersion(
(int|NULL) $value
)
:
Set the minor protocol version that should be used. 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.
setStaticHttpClient(
Zend_Http_Client $httpClient
)
:
void
Set the static HTTP client instance
Sets the static HTTP client object to use for retrieving the feed.
setVerboseExceptionMessages(
boolean $verbose
)
:
Set whether to use verbose exception messages
In the case of HTTP errors, use the body of the HTTP response in the exception message.
updateEntry(
mixed $data, string|null $uri
=
null, string|null $className
=
null, array $extraHeaders
=
array
)
:
Zend_Gdata_App_Entry
Update an entry