Automattic\WooCommerce\Blocks\Payments
Api::register_payment_method_integrations()
Register payment method integrations bundled with blocks.
Метод класса: Api{}
Хуков нет.
Возвращает
null
. Ничего (null).
Использование
$Api = new Api(); $Api->register_payment_method_integrations( $payment_method_registry );
- $payment_method_registry(PaymentMethodRegistry) (обязательный)
- Payment method registry instance.
Код Api::register_payment_method_integrations() Api::register payment method integrations WC 9.8.1
public function register_payment_method_integrations( PaymentMethodRegistry $payment_method_registry ) { $payment_method_registry->register( Package::container()->get( Cheque::class ) ); $payment_method_registry->register( Package::container()->get( PayPal::class ) ); $payment_method_registry->register( Package::container()->get( BankTransfer::class ) ); $payment_method_registry->register( Package::container()->get( CashOnDelivery::class ) ); }