CakeFest 2024: The Official CakePHP Conference

IteratorIterator::__construct

(PHP 5 >= 5.1.0, PHP 7, PHP 8)

IteratorIterator::__constructtraversable な何かからイテレータを作成する

説明

public IteratorIterator::__construct(Traversable $iterator, ?string $class = null)

traversable な何かからイテレータを作成します。

パラメータ

iterator

traversable なイテレータ。

class

内側のイテレータのために使うクラス名。 これを使うと、与えられたイテレータをラップするために異なるイテレータクラスを指定できます。 デフォルトでは、IteratorIterator を使います。

参考

add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top