public function SupportsVoidsInterface::voidPayment in Commerce Core 8.2
Voids the given payment.
Parameters
\Drupal\commerce_payment\Entity\PaymentInterface $payment: The payment to void.
Throws
\Drupal\commerce_payment\Exception\PaymentGatewayException Thrown when the transaction fails for any reason.
2 methods override SupportsVoidsInterface::voidPayment()
- Manual::voidPayment in modules/
payment/ src/ Plugin/ Commerce/ PaymentGateway/ Manual.php - Voids the given payment.
- Onsite::voidPayment in modules/
payment_example/ src/ Plugin/ Commerce/ PaymentGateway/ Onsite.php - Voids the given payment.
File
- modules/
payment/ src/ Plugin/ Commerce/ PaymentGateway/ SupportsVoidsInterface.php, line 34
Class
- SupportsVoidsInterface
- Defines the interface for gateways which support voiding payments.
Namespace
Drupal\commerce_payment\Plugin\Commerce\PaymentGatewayCode
public function voidPayment(PaymentInterface $payment);