src/ResourceObject.php
public function getIterator()
    {
        $isTraversal = (is_array($this->body) || $this->body instanceof \Traversable);

        return $isTraversal ? new \ArrayIterator($this->body) : new \ArrayIterator([]);
    }
public function getIterator()
    {
        $isTraversal = (is_array($this->body) || $this->body instanceof \Traversable);

        return $isTraversal ? new \ArrayIterator($this->body) : new \ArrayIterator([]);
    }
public function getIterator ( ) { $ isTraversal = ( is_array ( $ this -> body ) || $ this -> body instanceof \ Traversable ) ; return $ isTraversal ? new \ ArrayIterator ( $ this -> body ) : new \ ArrayIterator ( [ ] ) ; }
Get array iterator

@return \ArrayIterator
Get array iterator