| Total Complexity | 12 |
| Total Lines | 88 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 5 | trait CommonFilter |
||
| 6 | { |
||
| 7 | protected $length; |
||
| 8 | protected $width; |
||
| 9 | protected $height; |
||
| 10 | protected $volumetricWeight; |
||
| 11 | |||
| 12 | /** |
||
| 13 | * @param int|string $length Длина |
||
| 14 | * @return $this |
||
| 15 | */ |
||
| 16 | public function setLength($length): self |
||
| 21 | } |
||
| 22 | |||
| 23 | /** |
||
| 24 | * @param int|string $width Ширина |
||
| 25 | * @return $this |
||
| 26 | */ |
||
| 27 | public function setWidth($width): self |
||
| 28 | { |
||
| 29 | $this->width = $width; |
||
| 30 | |||
| 31 | return $this; |
||
| 32 | } |
||
| 33 | |||
| 34 | /** |
||
| 35 | * @param int|string $height Высота |
||
| 36 | * @return $this |
||
| 37 | */ |
||
| 38 | public function setHeight($height): self |
||
| 43 | } |
||
| 44 | |||
| 45 | /** |
||
| 46 | * @param int|string $volumetricWeight Объемный вес |
||
| 47 | * @return $this |
||
| 48 | */ |
||
| 49 | public function setVolumetricWeight($volumetricWeight): self |
||
| 54 | } |
||
| 55 | |||
| 56 | /** |
||
| 57 | * @return void |
||
| 58 | */ |
||
| 59 | public function getLength(): void |
||
| 60 | { |
||
| 61 | if ($this->length) { |
||
| 62 | $this->methodProperties['Length'] = $this->length; |
||
| 63 | } |
||
| 64 | } |
||
| 65 | |||
| 66 | /** |
||
| 67 | * @return void |
||
| 68 | */ |
||
| 69 | public function getWidth(): void |
||
| 73 | } |
||
| 74 | } |
||
| 75 | |||
| 76 | /** |
||
| 77 | * @return void |
||
| 78 | */ |
||
| 79 | public function getHeight(): void |
||
| 80 | { |
||
| 81 | if ($this->height) { |
||
| 82 | $this->methodProperties['Height'] = $this->height; |
||
| 83 | } |
||
| 84 | } |
||
| 85 | |||
| 86 | /** |
||
| 87 | * @return void |
||
| 88 | */ |
||
| 89 | public function getVolumetricWeight(): void |
||
| 93 | } |
||
| 94 | } |
||
| 95 | } |
||
| 96 |