cvs: phpdoc /en/reference/spl filteriterator.xml /en/reference/spl/filteriterator accept.xml /en/reference/spl/recursivearrayiterator
getchildren.xml haschildren.xml

From: Date: Sat, 04 Jul 2009 10:52:15 +0000
Subject: cvs: phpdoc /en/reference/spl filteriterator.xml /en/reference/spl/filteriterator accept.xml /en/reference/spl/recursivearrayiterator
getchildren.xml haschildren.xml
Groups: php.doc.cvs 
Request: Send a blank email to doc-cvs+get-4328@lists.php.net to get a copy of this message
joris Sat Jul 4 10:52:15 2009 UTC Added files: /phpdoc/en/reference/spl/filteriterator accept.xml Modified files: /phpdoc/en/reference/spl/recursivearrayiterator haschildren.xml getchildren.xml /phpdoc/en/reference/spl filteriterator.xml Log: Updated FilterIterator introduction and added documentation and examples for FilterIterator::accept method. Added see also to getChildren/hasChildren methods of RecursiveArrayIterator. http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/spl/recursivearrayiterator/haschildren.xml?r1=1.1&r2=1.2&diff_format=u Index: phpdoc/en/reference/spl/recursivearrayiterator/haschildren.xml diff -u phpdoc/en/reference/spl/recursivearrayiterator/haschildren.xml:1.1 phpdoc/en/reference/spl/recursivearrayiterator/haschildren.xml:1.2 --- phpdoc/en/reference/spl/recursivearrayiterator/haschildren.xml:1.1 Fri Jul 3 18:53:19 2009 +++ phpdoc/en/reference/spl/recursivearrayiterator/haschildren.xml Sat Jul 4 10:52:14 2009 @@ -1,5 +1,5 @@ <?xml version='1.0' encoding='iso-8859-1'?> -<!-- $Revision: 1.1 $ --> +<!-- $Revision: 1.2 $ --> <refentry xml:id="recursivearrayiterator.haschildren" xmlns="http://docbook.org/ns/docbook"> <refnamediv> <refname>RecursiveArrayIterator::hasChildren</refname> @@ -75,6 +75,15 @@ </para> </refsect1> + <refsect1 role="seealso"> + &reftitle.seealso; + <para> + <simplelist> + <member><function>RecursiveArrayIterator::getChildren</function></member> + </simplelist> + </para> + </refsect1> + </refentry> <!-- Keep this comment at the end of the file http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/spl/recursivearrayiterator/getchildren.xml?r1=1.1&r2=1.2&diff_format=u Index: phpdoc/en/reference/spl/recursivearrayiterator/getchildren.xml diff -u phpdoc/en/reference/spl/recursivearrayiterator/getchildren.xml:1.1 phpdoc/en/reference/spl/recursivearrayiterator/getchildren.xml:1.2 --- phpdoc/en/reference/spl/recursivearrayiterator/getchildren.xml:1.1 Fri Jul 3 18:53:19 2009 +++ phpdoc/en/reference/spl/recursivearrayiterator/getchildren.xml Sat Jul 4 10:52:14 2009 @@ -1,5 +1,5 @@ <?xml version='1.0' encoding='iso-8859-1'?> -<!-- $Revision: 1.1 $ --> +<!-- $Revision: 1.2 $ --> <refentry xml:id="recursivearrayiterator.getchildren" xmlns="http://docbook.org/ns/docbook"> <refnamediv> <refname>RecursiveArrayIterator::getChildren</refname> @@ -25,6 +25,12 @@ &reftitle.returnvalues; <para> An iterator for the current entry, if it is an <type>array</type> or <type>object</type>. + </para> + </refsect1> + + <refsect1 role="errors"> + &reftitle.errors; + <para> An <classname>InvalidArgumentException</classname> will be thrown if the current entry does not contain an <type>array</type> or an <type>object</type>. </para> @@ -65,13 +71,21 @@ No children. a : apple p : pear - ]]> </screen> </example> </para> </refsect1> + <refsect1 role="seealso"> + &reftitle.seealso; + <para> + <simplelist> + <member><function>RecursiveArrayIterator::hasChildren</function></member> + </simplelist> + </para> + </refsect1> + </refentry> <!-- Keep this comment at the end of the file http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/spl/filteriterator.xml?r1=1.4&r2=1.5&diff_format=u Index: phpdoc/en/reference/spl/filteriterator.xml diff -u phpdoc/en/reference/spl/filteriterator.xml:1.4 phpdoc/en/reference/spl/filteriterator.xml:1.5 --- phpdoc/en/reference/spl/filteriterator.xml:1.4 Sat Aug 23 14:09:14 2008 +++ phpdoc/en/reference/spl/filteriterator.xml Sat Jul 4 10:52:15 2009 @@ -1,27 +1,29 @@ <?xml version="1.0" encoding="utf-8"?> -<!-- $Revision: 1.4 $ --> +<!-- $Revision: 1.5 $ --> <phpdoc:classref xmlns:phpdoc="http://php.net/ns/phpdoc" xml:id="class.filteriterator" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xi="http://www.w3.org/2001/XInclude"> <title>The FilterIterator class</title> <titleabbrev>FilterIterator</titleabbrev> - + <partintro> - + <!-- {{{ FilterIterator intro --> <section xml:id="filteriterator.intro"> &reftitle.intro; <para> - ... + This abstract iterator filters out unwanted values. This class should be extended to + implement custom iterator filters. The <methodname>FilterIterator::accept()</methodname> + must be implemented in the subclass. </para> </section> <!-- }}} --> - + <section xml:id="filteriterator.synopsis"> &reftitle.classsynopsis; - + <!-- {{{ Synopsis --> <classsynopsis> <ooclass><classname>FilterIterator</classname></ooclass> - + <!-- {{{ Class synopsis --> <classsynopsisinfo> <ooclass> @@ -37,18 +39,18 @@ <oointerface> <interfacename>OuterIterator</interfacename> </oointerface> - + <oointerface> <interfacename>Traversable</interfacename> </oointerface> - + <oointerface> <interfacename>Iterator</interfacename> </oointerface> </classsynopsisinfo> <!-- }}} --> - + <!-- {{{ If the property is documented below (xml:id=filteriterator.props) use this <classsynopsisinfo role="comment">Properties</classsynopsisinfo> <fieldsynopsis> @@ -57,13 +59,13 @@ <varname linkend="filteriterator.props.name">name</varname> </fieldsynopsis> }}} --> - + <classsynopsisinfo role="comment">Methods</classsynopsisinfo> <xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.filteriterator')/db:refentry/db:refsect1[@role='description']/descendant::db:methodsynopsis[1])" /> </classsynopsis> - + </section> - + <!-- {{{ FilterIterator properties <section xml:id="filteriterator.props"> &reftitle.properties; @@ -77,13 +79,13 @@ </variablelist> </section> }}} --> - + </partintro> - + &reference.spl.entities.filteriterator; - + </phpdoc:classref> - + <!-- Keep this comment at the end of the file Local variables: mode: sgml http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/spl/filteriterator/accept.xml?view=markup&rev=1.1 Index: phpdoc/en/reference/spl/filteriterator/accept.xml +++ phpdoc/en/reference/spl/filteriterator/accept.xml <?xml version='1.0' encoding='iso-8859-1'?> <!-- $Revision: 1.1 $ --> <refentry xml:id="filteriterator.accept" xmlns="http://docbook.org/ns/docbook"> <refnamediv> <refname>FilterIterator::accept</refname> <refpurpose>Check whether the current element of the iterator is accessable.</refpurpose> </refnamediv> <refsect1 role="description"> &reftitle.description; <methodsynopsis> <modifier>abstract</modifier> <type>bool</type><methodname>FilterIterator::accept</methodname> <void/> </methodsynopsis> <para> Returns whether the current element of the iterator is accessable trough this filter. </para> </refsect1> <refsect1 role="parameters"> &reftitle.parameters; &no.function.parameters; </refsect1> <refsect1 role="returnvalues"> &reftitle.returnvalues; <para> &true; if the current element is accessable, otherwise &false;. </para> </refsect1> <refsect1 role="examples"> &reftitle.examples; <para> <example> <title><function>FilterIterator::accept</function> example</title> <programlisting role="php"> <![CDATA[ <?php // This iterator filters all values with less than 10 characters class LengthFilterIterator extends FilterIterator { public function accept() { // Only accept strings with a length of 10 and greater return strlen(parent::current()) > 10; } } $arrayIterator = new ArrayIterator(array('test1', 'more than 10 characters')); $lengthFilter = new LengthFilterIterator($arrayIterator); foreach ($lengthFilter as $value) { echo $value . "\n"; } ?> ]]> </programlisting> &example.outputs; <screen> <![CDATA[ more than 10 characters ]]> </screen> </example> </para> </refsect1> </refentry> <!-- Keep this comment at the end of the file Local variables: mode: sgml sgml-omittag:t sgml-shorttag:t sgml-minimize-attributes:nil sgml-always-quote-attributes:t sgml-indent-step:1 sgml-indent-data:t indent-tabs-mode:nil sgml-parent-document:nil sgml-default-dtd-file:"../../../../manual.ced" sgml-exposed-tags:nil sgml-local-catalogs:nil sgml-local-ecat-files:nil End: vim600: syn=xml fen fdm=syntax fdl=2 si vim: et tw=78 syn=sgml vi: ts=1 sw=1 -->

« previous php.doc.cvs (#4328) next »