The Zend_Feed_Abstract class is an abstract class representing feeds.
Zend_Feed_Abstract implements two core PHP 5 interfaces: ArrayAccess and Iterator. In both cases the collection being treated as an array is considered to be the entry collection, such that iterating over the feed takes you through each of the feed.s entries.
category | Zend |
---|---|
package | Zend_Feed |
copyright | Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com) |
license | New BSD License |
inherited_from | \Zend_Feed_Element |
__call(string $var, mixed $unused) : mixed
Map method calls to get the string value of the requested element. If there are multiple elements that match, this will return an array of those objects.
string
The element to get the string value of.
mixed
This parameter is not used.
mixed
The node's value, null, or an array of nodes.__construct(string $uri= null
, string $string= null
, \Zend_Feed_Builder_Interface $builder= null
) : void
The Zend_Feed_Abstract constructor takes the URI of a feed or a feed represented as a string and loads it as XML.
inherited_from | \Zend_Feed_Element::__construct() |
---|
string
The full URI of the feed to load, or NULL if not retrieved via HTTP or as an array.
string
The feed as a string, or NULL if retrieved via HTTP or as an array.
\Zend_Feed_Builder_Interface
The feed as a builder instance or NULL if retrieved as a string or via HTTP.
\Zend_Feed_Exception |
If loading the feed failed. |
---|
__construct(\DOMElement $element = null
) : void
\DOMElement
The DOM element we're encapsulating.
__get(string $var) : mixed
Get-style access returns a Zend_Feed_Element representing the child element accessed. To get string values, use method syntax with the __call() overriding.
string
The property to access.
mixed
__isset(string $var) : boolean
string
boolean
__set(string $var, string $val) : void
string
The property to change.
string
The property's new value.
\Zend_Feed_Exception |
---|
__sleep() : array
array
__toString() : string
string
__unset(string $var) : void
string
__wakeup() : void
\Zend_Feed_Exception |
---|
count() : integer
integer
Entry count.current() : mixed
mixed
The current row, or null if no rows.getDOM() : \DOMDocument
Returns the underlying DOM object, which can then be manipulated with full DOM methods.
\DOMDocument
getEncoding() : string
string
key() : mixed
mixed
The current row number (starts at 0), or NULL if no rowsnext() : mixed
mixed
The next row, or null if no more rows.offsetExists(string $offset) : boolean
string
boolean
offsetGet(string $offset) : string
string
string
offsetSet(string $offset, string $value) : string
string
string
string
offsetUnset(string $offset) : boolean
string
boolean
rewind() : void
saveXml() : string
Returns a string of this element's XML, including the XML prologue.
string
saveXmlFragment() : string
Returns a string of this element's XML without prologue.
string
send() : void
\Zend_Feed_Exception |
if headers have already been sent |
---|
setDOM(\DOMElement $element) : void
Take a DOMElement object, which may be originally from a call to getDOM() or may be custom created, and use it as the DOM tree for this Zend_Feed_Element.
\DOMElement
setEncoding(string $value) : \Zend_Feed_Element
string
Encoding to use
\Zend_Feed_Element
setParent(\Zend_Feed_Element $element) : void
\Zend_Feed_Element
valid() : boolean
boolean
Whether the iteration is valid_buildEntryCache() : void
_children(string $var) : array
Similar to SimpleXML's children() method.
string
Tagname to match, can be either namespace:tagName or just tagName.
array
_importFeedFromString(string $feed) : string
Protects against XXE attack vectors.
string
\Zend_Feed_Exception |
on detection of an XXE vector |
---|
string
_mapFeedEntries(\DOMElement $root, array $array) : \DOMElement
\DOMElement
the root node to use
array
the data to use
\DOMElement
root node_mapFeedHeaders(array $array) : \DOMElement
array
the data to use
\DOMElement
root nodeensureAppended() : void
$_appended : boolean
true
$_element : \DOMElement
$_encoding : string
'UTF-8'
$_entries : array
$_entryIndex : integer
0
$_parentElement : \Zend_Feed_Element