summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcus Boerger <helly@php.net>2005-03-12 23:21:41 +0000
committerMarcus Boerger <helly@php.net>2005-03-12 23:21:41 +0000
commit5880260c78627217001e0304bcfd8f2d6d974f18 (patch)
treeb164501f8c03ea8a3a5f0a74380634b51a7a5822
parent6f668d49783b8815de395367aaa84c19ef64c8c9 (diff)
downloadphp-git-5880260c78627217001e0304bcfd8f2d6d974f18.tar.gz
- Update docu
-rwxr-xr-xext/spl/internal/recursiveiteratoriterator.inc24
1 files changed, 21 insertions, 3 deletions
diff --git a/ext/spl/internal/recursiveiteratoriterator.inc b/ext/spl/internal/recursiveiteratoriterator.inc
index bba713ba09..65f9a20ba9 100755
--- a/ext/spl/internal/recursiveiteratoriterator.inc
+++ b/ext/spl/internal/recursiveiteratoriterator.inc
@@ -92,9 +92,9 @@ class RecursiveIteratorIterator implements OuterIterator
while ($this->count) {
$it = $this->ait[$this->count];
if ($it->valid()) {
- if (!$it->recursed && $it->hasChildren()) {
+ if (!$it->recursed && callHasChildren()) {
$it->recursed = true;
- $sub = $it->getChildren();
+ $sub = callGetChildren();
$sub->recursed = false;
$sub->rewind();
if ($sub->valid()) {
@@ -147,14 +147,32 @@ class RecursiveIteratorIterator implements OuterIterator
{
return $this->level;
}
-
+
+ /** @return whether current sub iterators current element has children
+ * @since PHP 5.1
+ */
+ function callHasChildren()
+ {
+ return $this->ait[$this->count]->hasChildren();
+ }
+
+ /** @return current sub iterators current children
+ * @since PHP 5.1
+ */
+ function callGetChildren()
+ {
+ return $this->ait[$this->count]->getChildren();
+ }
+
/** Called right after calling getChildren()
+ * @since PHP 5.1
*/
function beginChildren()
{
}
/** Called after current child iterator is invalid
+ * @since PHP 5.1
*/
function endChildren()
{