Path

ez components / documentation / api reference / 2008.1 / feed


Feed: ezcFeedParser

[ Tutorial ] [ Specifications ] [ Class tree ] [ Element index ] [ ChangeLog ] [ Credits ]

Interface: ezcFeedParser

Interface for feed parsers. [source]
Currently implemented for these feed types: The implementing classes must implement these methods:
  • canParse() - Returns true if the class can parse the provided XML document.
  • parse() - Parse the provided XML document and return an ezcFeed object.

Method Summary

public static bool canParse( $xml )
Returns true if the parser can parse the provided XML document object, false otherwise.
public ezcFeed parse( $xml )
Parses the provided XML document object and returns an ezcFeed object from it.

Methods

canParse

bool canParse( $xml )
Returns true if the parser can parse the provided XML document object, false otherwise.

Parameters

Name Type Description
$xml DOMDocument The XML document object to check for parseability

parse

ezcFeed parse( $xml )
Parses the provided XML document object and returns an ezcFeed object from it.

Parameters

Name Type Description
$xml DOMDocument The XML document object to parse

Throws

ClassDescription
ezcFeedParseErrorException If an error was encountered during parsing.

Last updated: Wed, 18 Jun 2008