Batch transfer strategy where transfer logic can be defined via a Closure.
This class is to be used with
- Guzzle\Batch\BatchClosureTransfer implements Guzzle\Batch\BatchTransferInterface
__construct ( mixed $callable, mixed $context = null )
transfer ( array $batch )
Transfer an array of items
__construct( mixed $callable, mixed $context = null )
$callable Callable that performs the transfer. This function should accept two arguments: (array $batch, mixed $context).
$context Optional context to pass to the batch divisor
Magic methods summary
A closure that performs the transfer
$context Context passed to the callable