Exemplo n.º 1
0
 public function __construct($data = array(), $message = '')
 {
     parent::__construct($data);
     if ($this->isDataOk()) {
         $orderId = $data['Event']['Purchase']['PaymentMethod']['ReferenceId'];
         $this->order = new Order($orderId, '', $this->getAmount() / 100);
     }
     $this->message = $message;
 }
Exemplo n.º 2
0
 /**
  * New query response
  *
  * @param string $type Query type
  * @param array $data
  */
 public function __construct($type, array $data = [])
 {
     $this->type = $type;
     $this->data = $data;
     parent::__construct($data);
 }
Exemplo n.º 3
0
 /**
  * New network error response
  *
  * @param string $message
  * @param array $data
  */
 public function __construct($message, $data = array())
 {
     $this->message = $message;
     parent::__construct($data);
 }
Exemplo n.º 4
0
 /**
  * Creates new transaction
  *
  * @param Method $method Payment method
  * @param type $mode Query type
  * @param array $data
  */
 public function __construct(Method $method, $mode, array $data = [])
 {
     $this->method = $method;
     $this->mode = $mode;
     parent::__construct($data);
 }