Class BatchSizeDivisor
Divides batches into smaller batches under a certain size
-
Guzzle\Batch\BatchSizeDivisor
implements
Guzzle\Batch\BatchDivisorInterface
Methods summary
public
|
#
__construct( integer $size )
Parameters
- $size
integer $size Size of each batch
|
public
Guzzle\Batch\BatchSizeDivisor
|
#
setSize( integer $size )
Set the size of each batch
Set the size of each batch
Parameters
- $size
integer $size Size of each batch
Returns
|
public
integer
|
#
getSize( )
Get the size of each batch
Get the size of each batch
Returns
integer
|
public
array|Traversable
|
#
createBatches( SplQueue $queue )
Divide a queue of items into an array batches
Divide a queue of items into an array batches
Parameters
- $queue
SplQueue
$queue Queue of items to divide into batches. Items are removed as they are
iterated.
Returns
array|Traversable Returns an array or Traversable object that contains arrays of items to transfer
Implementation of
|
Properties summary
protected
integer
|
$size
|
|
|