## Class Auth_Yadis_XMLParser

Description

The base class for wrappers for available PHP XML-parsing

extensions. To work with this Yadis library, subclasses of this class MUST implement the API as defined in the remarks for this class. Subclasses of Auth_Yadis_XMLParser are used to wrap particular PHP XML extensions such as 'domxml'. These are used internally by the library depending on the availability of supported PHP XML extensions.

Located in /Auth/Yadis/XML.php (line 21)

Direct descendents

Class | Description
--- | ---
Auth_Yadis_domxml | This concrete implementation of Auth_Yadis_XMLParser implements
Auth_Yadis_dom | This concrete implementation of Auth_Yadis_XMLParser implements

Method Summary
array attributes (mixed $node)
string content (mixed $node)
array &evalXPath (string $xpath, [mixed $node = null])
boolean init (string $xml_string, array $namespace_map)
boolean registerNamespace (string $prefix, string $uri)
boolean setXML (string $xml_string)
Methods
attributes (line 121)

Return the attributes of a specified node.

- return: An array mapping attribute names to values.

array attributes (mixed $node)

- mixed $node: A node object from a previous call to $this->evalXPath().

Redefined in descendants as:

- Auth_Yadis_domxml::attributes()
- Auth_Yadis_dom::attributes()

content (line 107)

Return the textual content of a specified node.

- return: The content of this node.

string content (mixed $node)

- mixed $node: A node object from a previous call to $this->evalXPath().

Redefined in descendants as:

- Auth_Yadis_domxml::content()
- Auth_Yadis_dom::content()

evalXPath (line 94)

Evaluate an XPath expression and return the resulting node list. This should be overridden by subclasses.

- return: An array of matching opaque node objects to be used with other methods of this parser class.

array &evalXPath (string $xpath, [mixed $node = null])

- string $xpath: The XPath expression to be evaluated.
- mixed $node: A node object resulting from a previous evalXPath call. This node, if specified, provides the context for the evaluation of this xpath expression.

Redefined in descendants as:

- Auth_Yadis_domxml::evalXPath()
- Auth_Yadis_dom::evalXPath()

init (line 33)

Initialize an instance of Auth_Yadis_XMLParser with some XML and namespaces. This SHOULD NOT be overridden by subclasses.

- return: True if the initialization and namespace registration(s) succeeded; false otherwise.

boolean init (string $xml_string, array $namespace_map)

- string $xml_string: A string of XML to be parsed.
- array $namespace_map: An array of ($ns_name => $ns_uri) to be registered with the XML parser. May be empty.

registerNamespace (line 61)

Register a namespace with the XML parser. This should be overridden by subclasses.

- return: True if the registration succeeded; false otherwise.

boolean registerNamespace (string $prefix, string $uri)

- string $prefix: The namespace prefix to appear in XML tag names.
- string $uri: The namespace URI to be used to identify the namespace in the XML.

Redefined in descendants as:

- Auth_Yadis_domxml::registerNamespace()
- Auth_Yadis_dom::registerNamespace()

setXML (line 76)

Set this parser object's XML payload. This should be overridden by subclasses.

- return: True if the initialization succeeded; false otherwise.

boolean setXML (string $xml_string)

- string $xml_string: The XML string to pass to this object's XML parser.

Redefined in descendants as:

- Auth_Yadis_domxml::setXML()
- Auth_Yadis_dom::setXML()

Documentation generated on Tue, 21 Apr 2009 11:31:33 -0700 by phpDocumentor 1.3.2