src/Client/Red.php
public static function run($channel, $config, $metadata)
    {
        if (! in_array($channel, self::$supportChannel)) {
            throw new PayException('sdk当前不支持该支付渠道，当前仅支持：' . implode(',', self::$supportChannel));
        }

        try {
            $instance = self::getInstance($channel, $config);

            $ret = $instance->red($metadata);
        } catch (PayException $e) {
            throw $e;
        }

        return $ret;
    }
public static function run($channel, $config, $metadata)
    {
        if (! in_array($channel, self::$supportChannel)) {
            throw new PayException('sdk当前不支持该支付渠道，当前仅支持：' . implode(',', self::$supportChannel));
        }

        try {
            $instance = self::getInstance($channel, $config);

            $ret = $instance->red($metadata);
        } catch (PayException $e) {
            throw $e;
        }

        return $ret;
    }
public static function run ( $ channel , $ config , $ metadata ) { if ( ! in_array ( $ channel , self :: $ supportChannel ) ) { throw new PayException ( 'sdk当前不支持该支付渠道，当前仅支持：' . implode(',', self::$supportChan e )); } try { $ instance = self :: getInstance ( $ channel , $ config ) ; $ ret = $ instance -> red ( $ metadata ) ; } catch ( PayException $ e ) { throw $ e ; } return $ ret ; }
@param string $channel
@param array $config
@param array $metadata

@return mixed
@throws PayException
@param string $channel @param array $config @param array $metadata