Attendize/app/Payment/PaymentResponse.php

36 lines
732 B
PHP
Raw Normal View History

2019-08-16 13:04:50 +00:00
<?php
/**
* Created by PhpStorm.
* User: merdan
* Date: 8/16/2019
* Time: 13:30
*/
namespace App\Payment;
abstract class PaymentResponse
{
protected $response_data;
protected $exception_message;
public function setResponseData($data){
$this->response_data = json_decode($data, true);
}
public function setExceptionMessage($message){
$this->exception_message = $message;
}
public function errorMessage(){
if(!$this->exception_message)
2019-11-27 09:00:13 +00:00
{
return $this->response_data['ErrorMessage'];}
2019-08-16 13:04:50 +00:00
else
return $this->exception_message;
}
public abstract function isSuccessfull();
public abstract function getPaymentReferenceId();
2019-11-27 09:00:13 +00:00
}