Feed/Writer/Feed/FeedAbstract.php
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 [email protected] 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_Feed_Writer
- Version
- $Id: FeedAbstract.php 25160 2012-12-18 15:17:16Z matthew $
\Zend_Feed_Writer_Feed_FeedAbstract
- Children
- \Zend_Feed_Writer_Feed
- \Zend_Feed_Writer_Source
- Category
- Zend
- Copyright
- Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
- License
- New BSD License
Properties


array $_data = array()
Contains all Feed level date to append in feed output
array()
Details- Type
- array
Methods


__call(string $method, array $args) : mixed
Method overloading: call given method on first extension implementing it
Name | Type | Description |
---|---|---|
$method | string | |
$args | array |
Type | Description |
---|---|
mixed |
Exception | Description |
---|---|
\Zend_Feed_Exception | if no extensions implements the method |


__construct() : void
Constructor: Primarily triggers the registration of core extensions and loads those appropriate to this data container.


_validateTagUri(string $id) : bool
Validate a URI using the tag scheme (RFC 4151)
Name | Type | Description |
---|---|---|
$id | string |
Type | Description |
---|---|
bool |


addAuthor( $name, $email = null, $uri = null) : string | null
Set a single author
Name | Type | Description |
---|---|---|
$name | ||
$uri |
Type | Description |
---|---|
string | null |


addAuthors( $authors) : array
Set an array with feed authors
Name | Type | Description |
---|---|---|
$authors |
Type | Description |
---|---|
array |


addCategories(array $categories) : void
Set an array of feed categories
Name | Type | Description |
---|---|---|
$categories | array |


addCategory(string $category) : void
Add a feed category
Name | Type | Description |
---|---|---|
$category | string |


addHub(string $url) : void
Add a Pubsubhubbub hub endpoint URL
Name | Type | Description |
---|---|---|
$url | string |


addHubs(array $urls) : void
Add Pubsubhubbub hub endpoint URLs
Name | Type | Description |
---|---|---|
$urls | array |


getAuthor(int $index = 0) : string | null
Get a single author
Name | Type | Description |
---|---|---|
$index | int |
Type | Description |
---|---|
string | null |


getDateModified() : string | null
Get the feed modification date
Type | Description |
---|---|
string | null |


getHubs() : string | null
Get the URLs used as Pubsubhubbub hubs endpoints
Type | Description |
---|---|
string | null |


getLastBuildDate() : string | null
Get the feed last-build date
Type | Description |
---|---|
string | null |


getType() : string
Retrieve the current or last feed type exported.
Type | Description |
---|---|
string | Value will be "rss" or "atom" |


remove(string $name) : void
Unset a specific data point
Name | Type | Description |
---|---|---|
$name | string |


setCopyright( $copyright) : string | null
Set the copyright entry
Name | Type | Description |
---|---|---|
$copyright |
Type | Description |
---|---|
string | null |


setDateCreated( $date = null) : void
Set the feed creation date
Name | Type | Description |
---|---|---|
$date | null|integer|Zend_Date |


setDateModified( $date = null) : void
Set the feed modification date
Name | Type | Description |
---|---|---|
$date | null|integer|Zend_Date |


setDescription( $description) : string | null
Set the feed description
Name | Type | Description |
---|---|---|
$description |
Type | Description |
---|---|
string | null |


setEncoding(string $encoding) : void
Set the feed character encoding
Name | Type | Description |
---|---|---|
$encoding | string |


setFeedLink( $link, $type) : string | null
Set a link to an XML feed for any feed type/version
Name | Type | Description |
---|---|---|
$link | ||
$type |
Type | Description |
---|---|
string | null |


setGenerator( $name, $version = null, $uri = null) : string | null
Set the feed generator entry
Name | Type | Description |
---|---|---|
$name | ||
$version | ||
$uri |
Type | Description |
---|---|
string | null |


setIcon(array $data) : void
Set a feed icon (URI at minimum).
Parameter is a single array with the required key 'uri'. Only 'uri' is required and used for Atom rendering. RSS does not support an Icon tag except via Atom 1.0 as an extension.
Name | Type | Description |
---|---|---|
$data | array |


setId(string $id) : void
Set the feed ID - URI or URN (via PCRE pattern) supported
Name | Type | Description |
---|---|---|
$id | string |


setImage(array $data) : void
Set a feed image (URI at minimum).
Parameter is a single array with the required key 'uri'. When rendering as RSS, the required keys are 'uri', 'title' and 'link'. RSS also specifies three optional parameters 'width', 'height' and 'description'. Only 'uri' is required and used for Atom rendering.
Name | Type | Description |
---|---|---|
$data | array |


setLanguage( $language) : string | null
Set the feed language
Name | Type | Description |
---|---|---|
$language |
Type | Description |
---|---|
string | null |


setLastBuildDate( $date = null) : void
Set the feed last-build date.
Ignored for Atom 1.0.
Name | Type | Description |
---|---|---|
$date | null|integer|Zend_Date |


setLink(string $link) : void
Set a link to the HTML source
Name | Type | Description |
---|---|---|
$link | string |


setTitle( $title) : string | null
Set the feed title
Name | Type | Description |
---|---|---|
$title |
Type | Description |
---|---|
string | null |