2020-06-09 13:17:26 +02:00
|
|
|
<?php
|
|
|
|
/**
|
|
|
|
* Invoice Ninja (https://invoiceninja.com)
|
|
|
|
*
|
|
|
|
* @link https://github.com/invoiceninja/invoiceninja source repository
|
|
|
|
*
|
|
|
|
* @copyright Copyright (c) 2020. Invoice Ninja LLC (https://invoiceninja.com)
|
|
|
|
*
|
|
|
|
* @license https://opensource.org/licenses/AAL
|
|
|
|
*/
|
|
|
|
|
|
|
|
namespace App\PaymentDrivers;
|
|
|
|
|
2020-06-24 07:20:33 +02:00
|
|
|
use App\Models\Payment;
|
|
|
|
|
2020-06-09 13:17:26 +02:00
|
|
|
abstract class AbstractPaymentDriver
|
|
|
|
{
|
|
|
|
|
2020-06-10 10:05:30 +02:00
|
|
|
abstract public function authorize($payment_method);
|
2020-06-09 13:17:26 +02:00
|
|
|
|
2020-06-15 13:42:46 +02:00
|
|
|
abstract public function purchase($amount, $return_client_response = false);
|
2020-06-09 13:17:26 +02:00
|
|
|
|
2020-06-24 07:20:33 +02:00
|
|
|
abstract public function refund(Payment $payment, $refund_amount, $return_client_response = false);
|
2020-06-09 13:17:26 +02:00
|
|
|
|
2020-06-16 14:41:56 +02:00
|
|
|
abstract public function setPaymentMethod($payment_method_id);
|
2020-06-16 02:21:40 +02:00
|
|
|
|
2020-06-09 13:17:26 +02:00
|
|
|
}
|