Copied!

BatchIteratorAdapter

BatchIteratorAdapter.php : 27

This adapter is used to fetch payment methods in batches.

The following example loops through all the payment methods:

$paymentMethods = new BatchIterator(new BatchIteratorAdapter($this->paymentMethodService))
foreach ($paymentMethods as $paymentMethod) {
   // ...
}

Methods

public__construct()

BatchIteratorAdapter.php : 33
public __construct(PaymentMethodServiceInterface $paymentMethodService[, PaymentMethodQuery|null $query = null ])

Parameters

Name Type Default value Description
$paymentMethodService PaymentMethodServiceInterface - -
$query PaymentMethodQuery|null null -

publicfetch()

BatchIteratorAdapter.php : 39
public fetch(int $offset, int $limit) : Iterator

Parameters

Name Type Default value Description
$offset int - -
$limit int - -

Return values

Iterator