1 | <?php |
||
18 | class CreateMaterialRequest |
||
19 | { |
||
20 | /** @var string */ |
||
21 | private $name; |
||
22 | |||
23 | /** @var string */ |
||
24 | private $code; |
||
25 | |||
26 | /** @var UnitInterface */ |
||
27 | private $unit; |
||
28 | |||
29 | /** @var CategoryInterface */ |
||
30 | private $category; |
||
31 | |||
32 | /** |
||
33 | * CreateMaterialRequest constructor. |
||
34 | * |
||
35 | * @param string $name |
||
36 | * @param string $code |
||
37 | * @param UnitInterface $unit |
||
38 | * @param CategoryInterface $category |
||
39 | */ |
||
40 | public function __construct($name, $code, CategoryInterface $category, UnitInterface $unit = null) |
||
47 | |||
48 | /** |
||
49 | * @return string |
||
50 | */ |
||
51 | public function getName() |
||
55 | |||
56 | /** |
||
57 | * @return string |
||
58 | */ |
||
59 | public function getCode() |
||
63 | |||
64 | /** |
||
65 | * @return UnitInterface|null |
||
66 | */ |
||
67 | public function getUnit() |
||
71 | |||
72 | /** |
||
73 | * @return CategoryInterface |
||
74 | */ |
||
75 | public function getCategory() |
||
79 | } |