34 private $description = null;
44 private $countryCodeOrigin = null;
54 private $customsTariffNumber = null;
61 private $amount = null;
68 private $netWeightInKG = null;
75 private $customsValue = null;
87 public function __construct($description, $countryCodeOrigin, $customsTariffNumber, $amount, $netWeightInKG, $customsValue) {
88 if(! $description || ! $countryCodeOrigin || ! $amount || ! $netWeightInKG || ! $customsValue) {
89 trigger_error(
'PHP-DHL-API: ' . __CLASS__ .
'->' . __FUNCTION__ .
90 ': All values must be filled out! (Not null, Not false, Not 0, Not "", Not empty) - Ignore this function for this call now', E_USER_WARNING);
91 error_log(
'PHP-DHL-API: ' . __CLASS__ .
'->' . __FUNCTION__ .
92 ': All values must be filled out! (Not null, Not false, Not 0, Not "", Not empty) - Ignore this function for this call now', E_USER_WARNING);
96 $this->setDescription($description);
97 $this->setCountryCodeOrigin($countryCodeOrigin);
98 $this->setCustomsTariffNumber($customsTariffNumber);
99 $this->setAmount($amount);
100 $this->setNetWeightInKG((
float) $netWeightInKG);
101 $this->setCustomsValue((
float) $customsValue);
108 unset($this->description);
109 unset($this->countryCodeOrigin);
110 unset($this->customsTariffNumber);
111 unset($this->amount);
112 unset($this->netWeightInKG);
113 unset($this->customsValue);
122 return $this->description;
130 private function setDescription($description) {
131 $this->description = $description;
140 return $this->countryCodeOrigin;
148 private function setCountryCodeOrigin($countryCodeOrigin) {
149 $this->countryCodeOrigin = $countryCodeOrigin;
158 return $this->customsTariffNumber;
166 private function setCustomsTariffNumber($customsTariffNumber) {
167 $this->customsTariffNumber = $customsTariffNumber;
176 return $this->amount;
184 private function setAmount($amount) {
185 $this->amount = $amount;
194 return $this->netWeightInKG;
202 private function setNetWeightInKG($netWeightInKG) {
203 $this->netWeightInKG = $netWeightInKG;
212 return $this->customsValue;
220 private function setCustomsValue($customsValue) {
221 $this->customsValue = $customsValue;
232 trigger_error(
'[DHL-PHP-SDK]: Version 1 Methods are deprecated and will removed soon (Called method ' . __METHOD__ .
')!', E_USER_DEPRECATED);
233 trigger_error(
'[DHL-PHP-SDK]: Called Version 1 Method: ' . __METHOD__ .
' is incomplete (does nothing)!', E_USER_WARNING);
235 $class =
new StdClass;
246 $class =
new StdClass;
getExportDocPositionClass_v1()
__construct($description, $countryCodeOrigin, $customsTariffNumber, $amount, $netWeightInKG, $customsValue)
getExportDocPositionClass_v2()