API Documentation

Feed/Pubsubhubbub/Subscriber/Callback.php

Includes Classes 
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Feed_Pubsubhubbub
Classes
Zend_Feed_Pubsubhubbub_Subscriber_Callback

Description

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.

Zend_Feed_Pubsubhubbub_Subscriber_Callback

Extends from
Zend_Feed_Pubsubhubbub_CallbackAbstract
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Feed_Pubsubhubbub
Properties
$_feedUpdate
$_subscriptionKey
$_currentSubscriptionData
Methods
setSubscriptionKey
handle
isValidHubVerification
setFeedUpdate
hasFeedUpdate
getFeedUpdate
_hasValidVerifyToken
_detectVerifyTokenKey
_parseQueryString

Description

Properties

$_currentSubscriptionData

array $_currentSubscriptionData = 'null'

After verification, this is set to the verified subscription's data.

Details

$_currentSubscriptionData
array
visibility
protected
default
null
final
false
static
false

$_feedUpdate

string $_feedUpdate = 'null'

Contains the content of any feeds sent as updates to the Callback URL

Details

$_feedUpdate
string
visibility
protected
default
null
final
false
static
false

$_subscriptionKey

string $_subscriptionKey = 'null'

Holds a manually set subscription key (i.e. identifies a unique subscription) which is typical when it is not passed in the query string but is part of the Callback URL path, requiring manual retrieval e.g.

using a route and the Zend_Controller_Action::_getParam() method.

Details

$_subscriptionKey
string
visibility
protected
default
null
final
false
static
false

Methods

_detectVerifyTokenKey

_detectVerifyTokenKey( null|array $httpGetData = null ) : false|string

Attempt to detect the verification token key. This would be passed in the Callback URL (which we are handling with this class!) as a URI path part (the last part by convention).

Arguments
$httpGetData
nullarray
Output
false|string
Details
visibility
protected
final
false
static
false

_hasValidVerifyToken

_hasValidVerifyToken( array $httpGetData = null, bool $checkValue = true ) : bool

Check for a valid verify_token. By default attempts to compare values with that sent from Hub, otherwise merely ascertains its existence.

Arguments
$httpGetData
array
$checkValue
bool
Output
bool
Details
visibility
protected
final
false
static
false

_parseQueryString

_parseQueryString( ) : array|void

Build an array of Query String parameters.

This bypasses $_GET which munges parameter names and cannot accept multiple parameters with the same key.

Output
array|void
Details
visibility
protected
final
false
static
false

getFeedUpdate

getFeedUpdate( ) : string

Gets a newly received feed (Atom/RSS) sent by a Hub as an update to a Topic we've subscribed to.

Output
string
Details
visibility
public
final
false
static
false

handle

handle( array $httpGetData = null, bool $sendResponseNow = false ) : void

Handle any callback from a Hub Server responding to a subscription or unsubscription request. This should be the Hub Server confirming the the request prior to taking action on it.

Arguments
$httpGetData
array
GET data if available and not in $_GET
$sendResponseNow
bool
Whether to send response now or when asked
Details
visibility
public
final
false
static
false

hasFeedUpdate

hasFeedUpdate( ) : bool

Check if any newly received feed (Atom/RSS) update was received

Output
bool
Details
visibility
public
final
false
static
false

isValidHubVerification

isValidHubVerification( array $httpGetData ) : bool

Checks validity of the request simply by making a quick pass and confirming the presence of all REQUIRED parameters.

Arguments
$httpGetData
array
Output
bool
Details
visibility
public
final
false
static
false

setFeedUpdate

setFeedUpdate( string $feed ) : Zend_Feed_Pubsubhubbub_Subscriber_Callback

Sets a newly received feed (Atom/RSS) sent by a Hub as an update to a Topic we've subscribed to.

Arguments
$feed
string
Details
visibility
public
final
false
static
false

setSubscriptionKey

setSubscriptionKey( string $key ) : Zend_Feed_Pubsubhubbub_Subscriber_Callback

Set a subscription key to use for the current callback request manually.

Required if usePathParameter is enabled for the Subscriber.

Arguments
$key
string
Details
visibility
public
final
false
static
false
Documentation was generated by DocBlox.