| 1 | <?php |
||
| 11 | abstract class AbstractMerchant implements MerchantInterface |
||
| 12 | { |
||
| 13 | /** |
||
| 14 | * @var GatewayInterface |
||
| 15 | */ |
||
| 16 | protected $gateway; |
||
| 17 | /** |
||
| 18 | * @var CredentialsInterface |
||
| 19 | */ |
||
| 20 | protected $credentials; |
||
| 21 | /** |
||
| 22 | * @var GatewayFactoryInterface |
||
| 23 | */ |
||
| 24 | protected $gatewayFactory; |
||
| 25 | /** |
||
| 26 | * @var MoneyFormatter |
||
| 27 | */ |
||
| 28 | protected $moneyFormatter; |
||
| 29 | /** |
||
| 30 | * @var MoneyParser |
||
| 31 | */ |
||
| 32 | protected $moneyParser; |
||
| 33 | |||
| 34 | public function __construct( |
||
| 46 | |||
| 47 | /** |
||
| 48 | * @return CredentialsInterface |
||
| 49 | */ |
||
| 50 | public function getCredentials(): CredentialsInterface |
||
| 54 | |||
| 55 | /** |
||
| 56 | * @return GatewayInterface |
||
| 57 | */ |
||
| 58 | abstract protected function createGateway(); |
||
| 59 | |||
| 60 | } |
||
| 61 |