package com.jeesharp.business.modules.pay.payalipayconfig.support;

import com.jeesharp.business.modules.pay.payalipayconfig.entity.PayAlipayConfig;

/**
 * 支付宝配置运行时判断。
 *
 * @author jeesharp
 * @since 2026-05-25
 */
public final class PayAlipayCredentialSupport {

    private PayAlipayCredentialSupport() {
    }

    public static boolean isAliEnabled(PayAlipayConfig config) {
        return config != null && config.getAliEnabled() != null && config.getAliEnabled() == 1;
    }

    public static boolean isCertModel(PayAlipayConfig config) {
        return config != null && config.getCertModel() != null && config.getCertModel() == 1;
    }
}
