| Total Complexity | 11 |
| Total Lines | 79 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 18 | class WorkingVolume implements Box, JsonSerializable |
||
| 19 | { |
||
| 20 | private int $width; |
||
| 21 | |||
| 22 | private int $length; |
||
| 23 | |||
| 24 | private int $depth; |
||
| 25 | |||
| 26 | private int $maxWeight; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * Constructor. |
||
| 30 | */ |
||
| 31 | 23 | public function __construct( |
|
| 32 | int $width, |
||
| 33 | int $length, |
||
| 34 | int $depth, |
||
| 35 | int $maxWeight |
||
| 36 | ) { |
||
| 37 | 23 | $this->width = $width; |
|
| 38 | 23 | $this->length = $length; |
|
| 39 | 23 | $this->depth = $depth; |
|
| 40 | 23 | $this->maxWeight = $maxWeight; |
|
| 41 | } |
||
| 42 | |||
| 43 | 22 | public function getReference(): string |
|
| 44 | { |
||
| 45 | 22 | return "Working Volume {$this->width}x{$this->length}x{$this->depth}"; |
|
| 46 | } |
||
| 47 | |||
| 48 | 1 | public function getOuterWidth(): int |
|
| 49 | { |
||
| 50 | 1 | return $this->width; |
|
| 51 | } |
||
| 52 | |||
| 53 | 1 | public function getOuterLength(): int |
|
| 56 | } |
||
| 57 | |||
| 58 | 1 | public function getOuterDepth(): int |
|
| 59 | { |
||
| 60 | 1 | return $this->depth; |
|
| 61 | } |
||
| 62 | |||
| 63 | 22 | public function getEmptyWeight(): int |
|
| 66 | } |
||
| 67 | |||
| 68 | 22 | public function getInnerWidth(): int |
|
| 69 | { |
||
| 70 | 22 | return $this->width; |
|
| 71 | } |
||
| 72 | |||
| 73 | 22 | public function getInnerLength(): int |
|
| 74 | { |
||
| 75 | 22 | return $this->length; |
|
| 76 | } |
||
| 77 | |||
| 78 | 22 | public function getInnerDepth(): int |
|
| 81 | } |
||
| 82 | |||
| 83 | 22 | public function getMaxWeight(): int |
|
| 84 | { |
||
| 85 | 22 | return $this->maxWeight; |
|
| 86 | } |
||
| 87 | |||
| 88 | 1 | #[ReturnTypeWillChange] |
|
| 97 | 1 | ]; |
|
| 98 | } |
||
| 99 | } |
||
| 100 |