next element. * * @since 5.5.0 * * @link https://www.php.net/manual/en/iterator.next.php */ #[ReturnTypeWillChange] public function next() { next( $this->blocks ); } /** * Checks if current position is valid. * * @since 5.5.0 * * @link https://www.php.net/manual/en/iterator.valid.php */ #[ReturnTypeWillChange] public function valid() { return null !== key( $this->blocks ); } /** * Returns the count of blocks in the list. * * @since 5.5.0 * * @link https://www.php.net/manual/en/countable.count.php * * @return int Block count. */ #[ReturnTypeWillChange] public function count() { return count( $this->blocks ); } }