The RecursiveIteratorIterator class

(PHP 5, PHP 7, PHP 8)

Introduction

Can be used to iterate through recursive iterators.

Class synopsis

classRecursiveIteratorIteratorimplementsOuterIterator {
publicconstintLEAVES_ONLY;
publicconstintSELF_FIRST;
publicconstintCHILD_FIRST;
publicconstintCATCH_GET_CHILD;
public__construct(Traversable$iterator, int$mode = RecursiveIteratorIterator::LEAVES_ONLY, int$flags = 0)
publiccurrent(): mixed
publicendChildren(): void
publicgetDepth(): int
publickey(): mixed
publicnext(): void
publicnextElement(): void
publicrewind(): void
publicsetMaxDepth(int$maxDepth = -1): void
publicvalid(): bool
}

Table of Contents

To Top