PayU integration by Krzysztof Gzocha
  • Namespace
  • Class

Namespaces

  • Team3
    • PayU
      • Annotation
      • Communication
        • CurlRequestBuilder
        • HttpStatusParser
        • Notification
        • Process
          • NotificationProcess
          • ResponseDeserializer
        • Request
          • Model
        • Response
          • Model
        • Sender
      • Configuration
        • Credentials
      • Order
        • Autocomplete
          • Strategy
        • Model
          • Buyer
          • Money
          • Products
          • ShippingMethods
          • Traits
        • Transformer
          • UserOrder
            • Strategy
              • Product
              • ShippingMethod
      • PropertyExtractor
        • Reader
      • Serializer
      • SignatureCalculator
        • Encoder
          • Algorithms
          • Strategy
        • ParametersSorter
        • Validator
      • ValidatorBuilder

Classes

  • Team3\PayU\ValidatorBuilder\ValidatorBuilder

Interfaces

  • Team3\PayU\ValidatorBuilder\ValidatorBuilderInterface
 1 <?php
 2 /**
 3  * @author Krzysztof Gzocha <krzysztof.gzocha@xsolve.pl>
 4  */
 5 namespace Team3\PayU\Communication\Request\Model;
 6 
 7 use Team3\PayU\Order\Model\Money\MoneyInterface;
 8 use Team3\PayU\Order\Model\OrderInterface;
 9 use JMS\Serializer\Annotation as JMS;
10 use Team3\PayU\Serializer\SerializableInterface;
11 
12 /**
13  * Class RefundRequestModel
14  * @package Team3\PayU\Communication\Request\Model
15  * @JMS\AccessorOrder("alphabetical")
16  */
17 class RefundRequestModel implements SerializableInterface
18 {
19     /**
20      * @var RefundModelInterface
21      * @JMS\Type("Team3\PayU\Communication\Request\Model\RefundModel")
22      */
23     private $refund;
24 
25     /**
26      * @var string
27      * @JMS\Type("string")
28      */
29     private $orderId;
30 
31     /**
32      * @param OrderInterface      $order
33      * @param string              $description
34      * @param string|null         $bankDescription
35      * @param MoneyInterface|null $amount
36      */
37     public function __construct(
38         OrderInterface $order,
39         $description,
40         $bankDescription = null,
41         MoneyInterface $amount = null
42     ) {
43         $this->orderId = $order->getOrderId();
44         $this->refund = new RefundModel($description, $bankDescription, $amount);
45     }
46 
47     /**
48      * @return RefundModelInterface
49      */
50     public function getRefund()
51     {
52         return $this->refund;
53     }
54 
55     /**
56      * @return string
57      */
58     public function getOrderId()
59     {
60         return $this->orderId;
61     }
62 }
63 
PayU integration by Krzysztof Gzocha API documentation generated by ApiGen