API Documentation

Feed/Pubsubhubbub/Publisher.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_Publisher

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_Publisher

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
$_hubUrls
$_updatedTopicUrls
$_errors
$_parameters
Methods
__construct
setConfig
addHubUrl
addHubUrls
removeHubUrl
getHubUrls
addUpdatedTopicUrl
addUpdatedTopicUrls
removeUpdatedTopicUrl
getUpdatedTopicUrls
notifyHub
notifyAll
setParameter
setParameters
removeParameter
getParameters
isSuccess
getErrors
_getHttpClient

Description

Properties

$_errors

array $_errors = 'array'

An array of any errors including keys for 'response', 'hubUrl'.

The response is the actual Zend_Http_Response object.

Details

$_errors
array
visibility
protected
default
array
final
false
static
false

$_hubUrls

array $_hubUrls = 'array'

An array of URLs for all Hub Servers used by the Publisher, and to which all topic update notifications will be sent.

Details

$_hubUrls
array
visibility
protected
default
array
final
false
static
false

$_parameters

array $_parameters = 'array'

An array of topic (Atom or RSS feed) URLs which have been updated and whose updated status will be notified to all Hub Servers.

Details

$_parameters
array
visibility
protected
default
array
final
false
static
false

$_updatedTopicUrls

array $_updatedTopicUrls = 'array'

An array of topic (Atom or RSS feed) URLs which have been updated and whose updated status will be notified to all Hub Servers.

Details

$_updatedTopicUrls
array
visibility
protected
default
array
final
false
static
false

Methods

__construct

__construct(  $config = null ) : void

Constructor; accepts an array or Zend_Config instance to preset options for the Publisher without calling all supported setter methods in turn.

Arguments
$config
Details
visibility
public
final
false
static
false

_getHttpClient

_getHttpClient( ) : Zend_Http_Client

Get a basic prepared HTTP client for use

Details
visibility
protected
final
false
static
false

addHubUrl

addHubUrl( string $url ) : Zend_Feed_Pubsubhubbub_Publisher

Add a Hub Server URL supported by Publisher

Arguments
$url
string
Details
visibility
public
final
false
static
false

addHubUrls

addHubUrls( array $urls ) : Zend_Feed_Pubsubhubbub_Publisher

Add an array of Hub Server URLs supported by Publisher

Arguments
$urls
array
Details
visibility
public
final
false
static
false

addUpdatedTopicUrl

addUpdatedTopicUrl( string $url ) : Zend_Feed_Pubsubhubbub_Publisher

Add a URL to a topic (Atom or RSS feed) which has been updated

Arguments
$url
string
Details
visibility
public
final
false
static
false

addUpdatedTopicUrls

addUpdatedTopicUrls( array $urls ) : Zend_Feed_Pubsubhubbub_Publisher

Add an array of Topic URLs which have been updated

Arguments
$urls
array
Details
visibility
public
final
false
static
false

getErrors

getErrors( ) : array

Return an array of errors met from any failures, including keys: 'response' => the Zend_Http_Response object from the failure 'hubUrl' => the URL of the Hub Server whose notification failed

Output
array
Details
visibility
public
final
false
static
false

getHubUrls

getHubUrls( ) : array

Return an array of unique Hub Server URLs currently available

Output
array
Details
visibility
public
final
false
static
false

getParameters

getParameters( ) : array

Return an array of optional parameters for notification requests

Output
array
Details
visibility
public
final
false
static
false

getUpdatedTopicUrls

getUpdatedTopicUrls( ) : array

Return an array of unique updated topic URLs currently available

Output
array
Details
visibility
public
final
false
static
false

isSuccess

isSuccess( ) : bool

Returns a boolean indicator of whether the notifications to Hub Servers were ALL successful. If even one failed, FALSE is returned.

Output
bool
Details
visibility
public
final
false
static
false

notifyAll

notifyAll( ) : void

Notifies all Hub Server URLs of changes

If a Hub notification fails, certain data will be retained in an an array retrieved using getErrors(), if a failure occurs for any Hubs the isSuccess() check will return FALSE. This method is designed not to needlessly fail with an Exception/Error unless from Zend_Http_Client.

Details
visibility
public
final
false
static
false
throws
Thrown if no hubs attached

notifyHub

notifyHub( string $url ) : void

Notifies a single Hub Server URL of changes

Arguments
$url
string
The Hub Server's URL
Details
visibility
public
final
false
static
false
throws
Thrown on failure

removeHubUrl

removeHubUrl( string $url ) : Zend_Feed_Pubsubhubbub_Publisher

Remove a Hub Server URL

Arguments
$url
string
Details
visibility
public
final
false
static
false

removeParameter

removeParameter( string $name ) : Zend_Feed_Pubsubhubbub_Publisher

Remove an optional parameter for the notification requests

Arguments
$name
string
Details
visibility
public
final
false
static
false

removeUpdatedTopicUrl

removeUpdatedTopicUrl( string $url ) : Zend_Feed_Pubsubhubbub_Publisher

Remove an updated topic URL

Arguments
$url
string
Details
visibility
public
final
false
static
false

setConfig

setConfig(  $config ) : Zend_Feed_Pubsubhubbub_Publisher

Process any injected configuration options

Arguments
$config
Details
visibility
public
final
false
static
false

setParameter

setParameter( string $name, string|null $value = null ) : Zend_Feed_Pubsubhubbub_Publisher

Add an optional parameter to the update notification requests

Arguments
$name
string
$value
stringnull
Details
visibility
public
final
false
static
false

setParameters

setParameters( array $parameters ) : Zend_Feed_Pubsubhubbub_Publisher

Add an optional parameter to the update notification requests

Arguments
$parameters
array
Details
visibility
public
final
false
static
false
Documentation was generated by DocBlox.