cvs: peardoc /en/core ppm.xml /en/core/ppm pear-xmlparser.xml /en/core/ppm/pear-xmlparser getdata.xml parse.xml preprocessstupidsaxon.xml
| From: | Greg Beaver | Date: | Thu, 09 Jun 2005 03:00:48 +0000 |
| Subject: | cvs: peardoc /en/core ppm.xml /en/core/ppm pear-xmlparser.xml /en/core/ppm/pear-xmlparser getdata.xml parse.xml preprocessstupidsaxon.xml | ||
| Groups: | php.pear.doc | ||
| Request: | Send a blank email to pear-doc+get-6256@lists.php.net to get a copy of this message | ||
cellog Wed Jun 8 23:00:48 2005 EDT
Added files:
/peardoc/en/core/ppm pear-xmlparser.xml
/peardoc/en/core/ppm/pear-xmlparser getdata.xml parse.xml
preprocessstupidsaxon.xml
Modified files:
/peardoc/en/core ppm.xml
Log:
add docs for PEAR_XMLParser
http://cvs.php.net/diff.php/peardoc/en/core/ppm.xml?r1=1.9&r2=1.10&ty=u
Index: peardoc/en/core/ppm.xml
diff -u peardoc/en/core/ppm.xml:1.9 peardoc/en/core/ppm.xml:1.10
--- peardoc/en/core/ppm.xml:1.9 Tue Jun 7 23:42:46 2005
+++ peardoc/en/core/ppm.xml Wed Jun 8 23:00:46 2005
@@ -1,4 +1,4 @@
-<!-- $Revision: 1.9 $ -->
+<!-- $Revision: 1.10 $ -->
<chapter id="core.ppm">
<title>PEAR Installer classes</title>
@@ -27,6 +27,7 @@
&core.ppm.pear-remote;
&core.ppm.pear-rest;
&core.ppm.pear-validate;
+ &core.ppm.pear-xmlparser;
</chapter>
<!-- Keep this comment at the end of the file
http://cvs.php.net/co.php/peardoc/en/core/ppm/pear-xmlparser.xml?r=1.1&p=1
Index: peardoc/en/core/ppm/pear-xmlparser.xml
+++ peardoc/en/core/ppm/pear-xmlparser.xml
<sect1 id="core.ppm.pear-xmlparser">
<title>PEAR</title>
<refentry id="core.ppm.pear-xmlparser-summary">
<refnamediv>
<refname>
Class Summary
<classname>PEAR_XMLParser</classname>
</refname>
<refpurpose>Parser for any xml file</refpurpose>
</refnamediv>
<refsect1>
<title>Parser for any xml file</title>
¬documented;
</refsect1>
<refsect1>
<title>
Class Trees for
<classname>PEAR_XMLParser</classname>
</title>
<para>
<itemizedlist>
<listitem>
<para>PEAR_XMLParser</para>
</listitem>
</itemizedlist>
</para>
</refsect1>
</refentry>
&core.ppm.pear-xmlparser.getdata;
&core.ppm.pear-xmlparser.parse;
&core.ppm.pear-xmlparser.preprocessstupidsaxon;
</sect1>
http://cvs.php.net/co.php/peardoc/en/core/ppm/pear-xmlparser/getdata.xml?r=1.1&p=1
Index: peardoc/en/core/ppm/pear-xmlparser/getdata.xml
+++ peardoc/en/core/ppm/pear-xmlparser/getdata.xml
<refentry id="core.ppm.pear-xmlparser.getdata">
<refnamediv>
<refname>
<function>PEAR_XMLParser::getData</function>
</refname>
<refpurpose>getData</refpurpose>
</refnamediv>
<refsynopsisdiv>
<funcsynopsis>
<funcsynopsisinfo>require_once '/XMLParser.php';</funcsynopsisinfo>
<funcprototype>
<funcdef>
array
<function>PEAR_XMLParser::getData</function>
</funcdef>
<paramdef />
</funcprototype>
</funcsynopsis>
</refsynopsisdiv>
<refsect1 id="core.ppm.pear-xmlparser.getdata.desc">
&title.desc;
<para>
Return the array representation of XML as parsed by
<link
linkend="core.ppm.pear-xmlparser.parse"><function>parse</function></link>.
</para>
</refsect1>
<refsect1 id="core.ppm.pear-xmlparser.getdata.throws">
&title.throws;
<para>
<emphasis>throws</emphasis>
no exceptions thrown
</para>
</refsect1>
<refsect1 id="core.ppm.pear-xmlparser.getdata.note">
&title.note;
¬e.notstatic;
</refsect1>
</refentry>
http://cvs.php.net/co.php/peardoc/en/core/ppm/pear-xmlparser/parse.xml?r=1.1&p=1
Index: peardoc/en/core/ppm/pear-xmlparser/parse.xml
+++ peardoc/en/core/ppm/pear-xmlparser/parse.xml
<refentry id="core.ppm.pear-xmlparser.parse">
<refnamediv>
<refname>
<function>PEAR_XMLParser::parse</function>
</refname>
<refpurpose>parse</refpurpose>
</refnamediv>
<refsynopsisdiv>
<funcsynopsis>
<funcsynopsisinfo>require_once '/XMLParser.php';</funcsynopsisinfo>
<funcprototype>
<funcdef>
<replaceable>true|PEAR_Error</replaceable>
<function>PEAR_XMLParser::parse</function>
</funcdef>
<paramdef>
string
<parameter>$data</parameter>
</paramdef>
</funcprototype>
</funcsynopsis>
</refsynopsisdiv>
<refsect1 id="core.ppm.pear-xmlparser.parse.desc">
&title.desc;
<para>
Return an array that matches the XML parsed. This code is lifted from
Stephan Schmidt's <link
linkend="package.xml.xml-serializer.xml-unserializer.unserialize"><classname>XML_Unserializer</classname></link>
class in the XML_Serializer package. As such, tags are represented by an associative
array. Multiple tags are represented with a 0-based array of tag contents, and
attributes are represented by an array index named <literal>attribs</literal>.
If attributes are present, the array index <literal>_contents</literal> is used to
hold the contents of the xml tag.
</para>
</refsect1>
<refsect1 id="core.ppm.pear-xmlparser.parse.param">
&title.param;
<para>
<variablelist>
<varlistentry>
<term>
&type.string;
<parameter>$data</parameter>
</term>
<listitem>
<para>xml content</para>
</listitem>
</varlistentry>
</variablelist>
</para>
</refsect1>
<refsect1 id="core.ppm.pear-xmlparser.parse.throws">
&title.throws;
<para>
<emphasis>throws</emphasis>
no exceptions thrown
</para>
</refsect1>
<refsect1 id="core.ppm.pear-xmlparser.parse.note">
&title.note;
¬e.notstatic;
</refsect1>
</refentry>
http://cvs.php.net/co.php/peardoc/en/core/ppm/pear-xmlparser/preprocessstupidsaxon.xml?r=1.1&p=1
Index: peardoc/en/core/ppm/pear-xmlparser/preprocessstupidsaxon.xml
+++ peardoc/en/core/ppm/pear-xmlparser/preprocessstupidsaxon.xml
<refentry id="core.ppm.pear-xmlparser.preprocessstupidsaxon">
<refnamediv>
<refname>
<function>PEAR_XMLParser::preProcessStupidSaxon</function>
</refname>
<refpurpose>pre-process xml to weed out characters/entities that would kill
parsing</refpurpose>
</refnamediv>
<refsynopsisdiv>
<funcsynopsis>
<funcsynopsisinfo>require_once '/XMLParser.php';</funcsynopsisinfo>
<funcprototype>
<funcdef>
string
<function>PEAR_XMLParser::preProcessStupidSaxon</function>
</funcdef>
<paramdef>
string
<parameter>$data</parameter>
</paramdef>
</funcprototype>
</funcsynopsis>
</refsynopsisdiv>
<refsect1 id="core.ppm.pear-xmlparser.preprocessstupidsaxon.desc">
&title.desc;
<para>
This method examines xml data prior to parsing and replaces all entities
like &agrave; with their equivalent (&#224; in this case). It also
scans the file for any non-ascii characters like à and replaces them with
their entity equivalent (&#224).
</para>
<para>
This prevents saxon in PHP 4 and PHP 5 from choking on non-ISO-8859-1 characters.
</para>
</refsect1>
<refsect1 id="core.ppm.pear-xmlparser.preprocessstupidsaxon.param">
&title.param;
<para>
<variablelist>
<varlistentry>
<term>
&type.string;
<parameter>$data</parameter>
</term>
<listitem>
<para>
The xml data.
</para>
</listitem>
</varlistentry>
</variablelist>
</para>
</refsect1>
<refsect1 id="core.ppm.pear-xmlparser.preprocessstupidsaxon.throws">
&title.throws;
<para>
<emphasis>throws</emphasis>
no exceptions thrown
</para>
</refsect1>
<refsect1 id="core.ppm.pear-xmlparser.preprocessstupidsaxon.note">
&title.note;
¬e.notstatic;
</refsect1>
</refentry>