|
Open Journal Systems
3.3.0
|
Public Member Functions | |
| __construct ($callable, $context=null) | |
| transfer (array $batch) | |
Protected Attributes | |
| $callable | |
| $context | |
Batch transfer strategy where transfer logic can be defined via a Closure. This class is to be used with {
Definition at line 11 of file BatchClosureTransfer.php.
| Guzzle\Batch\BatchClosureTransfer::__construct | ( | $callable, | |
$context = null |
|||
| ) |
| mixed | $callable | Callable that performs the transfer. This function should accept two arguments: (array $batch, mixed $context). |
| mixed | $context | Optional context to pass to the batch divisor |
| InvalidArgumentException |
Definition at line 32 of file BatchClosureTransfer.php.
References Guzzle\Batch\BatchClosureTransfer\$callable, and Guzzle\Batch\BatchClosureTransfer\$context.
| Guzzle\Batch\BatchClosureTransfer::transfer | ( | array | $batch | ) |
Transfer an array of items
| array | $batch | Array of items to transfer |
Implements Guzzle\Batch\BatchTransferInterface.
Definition at line 42 of file BatchClosureTransfer.php.
|
protected |
A closure that performs the transfer
Definition at line 17 of file BatchClosureTransfer.php.
Referenced by Guzzle\Batch\BatchClosureTransfer\__construct().
|
protected |
$context Context passed to the callable
Definition at line 23 of file BatchClosureTransfer.php.
Referenced by Guzzle\Batch\BatchClosureTransfer\__construct().