Total Complexity | 10 |
Total Lines | 95 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
10 | class Contact |
||
11 | { |
||
12 | /** |
||
13 | * @var string |
||
14 | */ |
||
15 | private $name; |
||
16 | /** |
||
17 | * @var Contact|null |
||
18 | */ |
||
19 | private $manager; |
||
20 | /** |
||
21 | * @var Contact[] |
||
22 | */ |
||
23 | private $relations = []; |
||
24 | /** |
||
25 | * @var UploadedFileInterface |
||
26 | */ |
||
27 | private $photo; |
||
28 | /** |
||
29 | * @var DateTimeInterface |
||
30 | */ |
||
31 | private $birthDate; |
||
32 | |||
33 | public function __construct(string $name) |
||
34 | { |
||
35 | $this->name = $name; |
||
36 | } |
||
37 | |||
38 | /** |
||
39 | * @return string |
||
40 | */ |
||
41 | public function getName(): string |
||
42 | { |
||
43 | return $this->name; |
||
44 | } |
||
45 | |||
46 | public function getManager(): ?Contact |
||
47 | { |
||
48 | return $this->manager; |
||
49 | } |
||
50 | |||
51 | /** |
||
52 | * @param Contact|null $manager |
||
53 | */ |
||
54 | public function setManager(?Contact $manager): void |
||
57 | } |
||
58 | |||
59 | /** |
||
60 | * @return Contact[] |
||
61 | */ |
||
62 | public function getRelations(): array |
||
63 | { |
||
64 | return $this->relations; |
||
65 | } |
||
66 | |||
67 | /** |
||
68 | * @param Contact[] $relations |
||
69 | */ |
||
70 | public function setRelations(array $relations): void |
||
71 | { |
||
72 | $this->relations = $relations; |
||
73 | } |
||
74 | |||
75 | /** |
||
76 | * @return UploadedFileInterface |
||
77 | */ |
||
78 | public function getPhoto(): UploadedFileInterface |
||
81 | } |
||
82 | |||
83 | /** |
||
84 | * @param UploadedFileInterface $photo |
||
85 | */ |
||
86 | public function setPhoto(UploadedFileInterface $photo): void |
||
87 | { |
||
88 | $this->photo = $photo; |
||
89 | } |
||
90 | |||
91 | /** |
||
92 | * @return DateTimeInterface |
||
93 | */ |
||
94 | public function getBirthDate(): DateTimeInterface |
||
95 | { |
||
96 | return $this->birthDate; |
||
97 | } |
||
98 | |||
99 | /** |
||
100 | * @param DateTimeInterface $birthDate |
||
101 | */ |
||
102 | public function setBirthDate(DateTimeInterface $birthDate): void |
||
105 | } |
||
106 | } |
||
107 |