1493. Class

1493.1. Zend\Feed\PubSubHubbub\Publisher

1493.1.1. Methods

1493.1.1.1. __construct

__construct()

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

Parameters:array|Traversable

1493.1.1.2. setOptions

setOptions()

Process any injected configuration options

Parameters:array|Traversable – Options array or Traversable object
Return type:Publisher
Throws :ExceptionInvalidArgumentException

1493.1.1.3. addHubUrl

addHubUrl()

Add a Hub Server URL supported by Publisher

Parameters:string
Return type:Publisher
Throws :ExceptionInvalidArgumentException

1493.1.1.4. addHubUrls

addHubUrls()

Add an array of Hub Server URLs supported by Publisher

Parameters:array
Return type:Publisher

1493.1.1.5. removeHubUrl

removeHubUrl()

Remove a Hub Server URL

Parameters:string
Return type:Publisher

1493.1.1.6. getHubUrls

getHubUrls()

Return an array of unique Hub Server URLs currently available

Return type:array

1493.1.1.7. addUpdatedTopicUrl

addUpdatedTopicUrl()

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

Parameters:string
Return type:Publisher
Throws :ExceptionInvalidArgumentException

1493.1.1.8. addUpdatedTopicUrls

addUpdatedTopicUrls()

Add an array of Topic URLs which have been updated

Parameters:array
Return type:Publisher

1493.1.1.9. removeUpdatedTopicUrl

removeUpdatedTopicUrl()

Remove an updated topic URL

Parameters:string
Return type:Publisher

1493.1.1.10. getUpdatedTopicUrls

getUpdatedTopicUrls()

Return an array of unique updated topic URLs currently available

Return type:array

1493.1.1.11. notifyHub

notifyHub()

Notifies a single Hub Server URL of changes

Parameters:string – The Hub Server’s URL
Return type:void
Throws :ExceptionInvalidArgumentException
Throws :ExceptionRuntimeException

1493.1.1.12. notifyAll

notifyAll()

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.

Return type:void
Throws :ExceptionRuntimeException

1493.1.1.13. setParameter

setParameter()

Add an optional parameter to the update notification requests

Parameters:
  • string
  • string|null
Return type:

Publisher

Throws :

ExceptionInvalidArgumentException

1493.1.1.14. setParameters

setParameters()

Add an optional parameter to the update notification requests

Parameters:array
Return type:Publisher

1493.1.1.15. removeParameter

removeParameter()

Remove an optional parameter for the notification requests

Parameters:string
Return type:Publisher
Throws :ExceptionInvalidArgumentException

1493.1.1.16. getParameters

getParameters()

Return an array of optional parameters for notification requests

Return type:array

1493.1.1.17. isSuccess

isSuccess()

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

Return type:bool

1493.1.1.18. getErrors

getErrors()

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

Return type:array

1493.1.1.19. _getHttpClient

_getHttpClient()

Get a basic prepared HTTP client for use

Return type:ZendHttpClient
Throws :ExceptionRuntimeException