Creates an iterator from another iterator that will keep the results of the inner iterator in memory, so that results don't have to be re-calculated.
$_buffer
protected SplDoublyLinkedList
$_current
protected mixed
$_finished
protected boolean
$_index
protected integer
$_key
protected mixed
$_started
protected boolean
Whether or not the internal iterator's rewind method was already called
Maintains an in-memory cache of the results yielded by the internal iterator.
Returns a string representation of this object that can be used to reconstruct it
__construct( array|Traversable $items )
Maintains an in-memory cache of the results yielded by the internal iterator.
$items
Cake\Collection\Collection::__construct()
count( )
Returns the number or items in this collection
Cake\Collection\Collection::count()
Countable::count()
current( )
Returns the current record in the iterator
IteratorIterator::current()
key( )
Returns the current key in the iterator
IteratorIterator::key()
next( )
Advances the iterator pointer to the next element
IteratorIterator::next()
serialize( )
Returns a string representation of this object that can be used to reconstruct it
Cake\Collection\Collection::serialize()
Serializable::serialize()
unserialize( string $buffer )
Unserializes the passed string and rebuilds the BufferedIterator instance
$buffer
Cake\Collection\Collection::unserialize()
Serializable::unserialize()
valid( )
Returns whether or not the iterator has more elements
IteratorIterator::valid()
__debugInfo( )
Returns an array that can be used to describe the internal state of this object.
_unwrap( )
append( $items )
cartesianProduct( callable $operation null , callable $filter null )
Cake\Collection\CollectionInterface
chunk( $chunkSize )
chunkWithKeys( $chunkSize , $preserveKeys true )
combine( $keyPath , $valuePath , $groupPath null )
compile( $preserveKeys true )
contains( $value )
countBy( $callback )
each( callable $c )
every( callable $c )
extract( $matcher )
first( )
firstMatch( array $conditions )
groupBy( $callback )
indexBy( $callback )
isEmpty( )
jsonSerialize( )
last( )
listNested( $dir 'desc' , $nestingKey 'children' )
Cake\Collection\Iterator\TreeIterator
match( array $conditions )
max( $callback , $type SORT_NUMERIC )
min( $callback , $type SORT_NUMERIC )
nest( $idPath , $parentPath , $nestingKey 'children' )
reduce( callable $c , $zero null )
sample( $size 10 )
shuffle( )
skip( $howMany )
some( callable $c )
sortBy( $callback , $dir SORT_DESC , $type SORT_NUMERIC )
sumOf( $matcher null )
take( $size 1 , $from 0 )
through( callable $handler )
toArray( $preserveKeys true )
toList( )
unfold( callable $transformer null )
unwrap( )
zip( $items )
zipWith( $items , $callable )
protected SplDoublyLinkedList
The in-memory cache containing results from previous iterators
protected boolean
Whether or not the internal iterator's rewind method was already called
false
© 2005–2017 The Cake Software Foundation, Inc.
Licensed under the MIT License.
CakePHP is a registered trademark of Cake Software Foundation, Inc.
We are not endorsed by or affiliated with CakePHP.
https://api.cakephp.org/3.4/class-Cake.Collection.Iterator.BufferedIterator.html