protected function nextObject(\Iterator $iterator)
    {
        if ($iterator->valid()) {
            $object = $iterator->current();

            $iterator->next();

            return $object;
        }

        return false;
    }