yoone-wc-moneris-payments/includes/blocks/ide-stub-wc-blocks.php

34 lines
1.2 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
/**
* IDE/Linter stub for WooCommerce Blocks classes.
*
* 重要说明此文件仅用于静态分析IDE/代码检查以消除“Undefined type”告警
* 不会也不应该在 WordPress 运行时被 include/require。
* 请勿在任何运行时路径中加载此文件。
*/
namespace Automattic\WooCommerce\Blocks\Payments;
// 如果真实类不存在,则为 IDE 提供一个最小的占位定义,避免类型未定义告警。
if (! class_exists(\Automattic\WooCommerce\Blocks\Payments\PaymentMethodType::class)) {
/**
* 最小占位基类:仅用于 IDE 类型解析。
* 注意:方法签名仅为常见实现提供参考,并不代表真实 Woo Blocks 行为。
*/
abstract class PaymentMethodType {
/** @return string */
abstract public function get_name();
/** @return bool */
public function is_active() { return true; }
/** @return array */
abstract public function get_payment_method_script_handles();
/** @return array */
public function get_payment_method_data() { return []; }
/** @return array */
public function get_supported_features() { return []; }
}
}