phpday 2027 - Call for Papers

CachingIterator::valid

(PHP 5, PHP 7, PHP 8)

CachingIterator::valid — Check whether the current element is valid

说明

public function CachingIterator::valid(): bool

Checks whether the current element is valid.

A CachingIterator has no current element until CachingIterator::rewind() is called, which foreach does automatically.

参数

此函数没有参数。

返回值

Returns true if the current element is valid, false otherwise.

参见

+添加备注

用户贡献的备注

此页面尚无用户贡献的备注。
To Top