-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
I went through all the tests that mentioned this and looked at them. All of them don't pass because of other missing SPL problems not related to this class (and this class is simple so I wouldn't assume them to blame to it). Closes #766
- Loading branch information
Showing
24 changed files
with
61 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
<?php | ||
|
||
// This doc comment block generated by idl/sysdoc.php | ||
/** | ||
* ( excerpt from http://php.net/manual/en/class.recursivearrayiterator.php | ||
* ) | ||
* | ||
* This iterator allows to unset and modify values and keys while | ||
* iterating over Arrays and Objects in the same way as the ArrayIterator. | ||
* Additionally it is possible to iterate over the current iterator entry. | ||
* | ||
*/ | ||
class RecursiveArrayIterator | ||
extends ArrayIterator | ||
implements RecursiveIterator { | ||
|
||
const CHILD_ARRAYS_ONLY = 4; | ||
|
||
// This doc comment block generated by idl/sysdoc.php | ||
/** | ||
* ( excerpt from | ||
* http://php.net/manual/en/recursivearrayiterator.getchildren.php ) | ||
* | ||
* Returns an iterator for the current iterator entry. | ||
* | ||
* @return mixed An iterator for the current entry, if it is an array | ||
* or object. | ||
*/ | ||
public function getChildren() { | ||
return new RecursiveArrayIterator( | ||
$this->hasChildren() ? $this->current() : null, | ||
$this->getFlags() | ||
); | ||
} | ||
|
||
// This doc comment block generated by idl/sysdoc.php | ||
/** | ||
* ( excerpt from | ||
* http://php.net/manual/en/recursivearrayiterator.haschildren.php ) | ||
* | ||
* Returns whether current entry is an array or an object for which an | ||
* iterator can be obtained via RecursiveArrayIterator::getChildren(). | ||
* | ||
* @return mixed Returns TRUE if the current entry is an array or an | ||
* object, otherwise FALSE is returned. | ||
*/ | ||
public function hasChildren() { | ||
return | ||
is_array($this->current()) || | ||
(is_object($this->current()) && | ||
($this->getFlags() & self::CHILD_ARRAYS_ONLY) == 0); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.