1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
namespace Ups\Entity; |
4
|
|
|
|
5
|
|
|
use LogicException; |
6
|
|
|
|
7
|
|
|
class ItemizedPaymentInformation |
8
|
|
|
{ |
9
|
|
|
|
10
|
|
|
/** |
11
|
|
|
* @var splitDutyVATIndicator |
12
|
|
|
*/ |
13
|
|
|
private $splitDutyVATIndicator; |
14
|
|
|
private $transportationShipmentCharge = null; |
15
|
|
|
private $dutiesAndTaxesShipmentCharge = null; |
16
|
|
|
|
17
|
|
|
public function __construct($attributes = null) |
|
|
|
|
18
|
|
|
{ |
19
|
|
|
} |
20
|
|
|
|
21
|
|
|
/** |
22
|
|
|
* @return transportationShipmentCharge |
23
|
|
|
*/ |
24
|
|
|
public function getTransportationShipmentCharge() |
25
|
|
|
{ |
26
|
|
|
return $this->transportationShipmentCharge; |
27
|
|
|
} |
28
|
|
|
|
29
|
|
|
/** |
30
|
|
|
* @param ShipmentCharge $shipmentCharge |
31
|
|
|
* @return ItemizedPaymentInformation |
32
|
|
|
*/ |
33
|
|
|
public function setShipmentCharge(ShipmentCharge $shipmentCharge) |
34
|
|
|
{ |
35
|
|
|
if ($shipmentCharge->getType() == ShipmentCharge::SHIPMENT_CHARGE_TYPE_TRANSPORTATION) { |
36
|
|
|
$this->transportationShipmentCharge = $shipmentCharge; |
37
|
|
|
} elseif ($shipmentCharge->getType() == ShipmentCharge::SHIPMENT_CHARGE_TYPE_DUTIES) { |
38
|
|
|
$this->dutiesAndTaxesShipmentCharge = $shipmentCharge; |
39
|
|
|
} else { |
40
|
|
|
throw new LogicException(sprintf('Unknown ShipmentCharge charge type requested: "%s"', $type)); |
41
|
|
|
} |
42
|
|
|
return $this; |
43
|
|
|
} |
44
|
|
|
|
45
|
|
|
/** |
46
|
|
|
* @return dutiesAndTaxesShipmentCharge |
47
|
|
|
*/ |
48
|
|
|
public function getDutiesAndTaxesShipmentCharge() |
49
|
|
|
{ |
50
|
|
|
return $this->dutiesAndTaxesShipmentCharge; |
51
|
|
|
} |
52
|
|
|
|
53
|
|
|
/** |
54
|
|
|
* @return splitDutyVATIndicator |
55
|
|
|
*/ |
56
|
|
|
public function getSplitDutyVATIndicator() |
57
|
|
|
{ |
58
|
|
|
return $this->splitDutyVATIndicator; |
59
|
|
|
} |
60
|
|
|
|
61
|
|
|
/** |
62
|
|
|
* @param splitDutyVATIndicator $splitDutyVATIndicator |
63
|
|
|
* @return ItemizedPaymentInformation |
64
|
|
|
*/ |
65
|
|
|
public function setSplitDutyVATIndicator($splitDutyVATIndicator) |
66
|
|
|
{ |
67
|
|
|
$this->splitDutyVATIndicator = $splitDutyVATIndicator; |
68
|
|
|
|
69
|
|
|
return $this; |
70
|
|
|
} |
71
|
|
|
} |
72
|
|
|
|
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.