Total Complexity | 6 |
Total Lines | 85 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php declare(strict_types=1); |
||
8 | class Registration |
||
9 | { |
||
10 | /** |
||
11 | * @var UuidInterface |
||
12 | */ |
||
13 | private $id; |
||
14 | /** |
||
15 | * @var string |
||
16 | */ |
||
17 | private $hashCode; |
||
18 | |||
19 | /** |
||
20 | * @var User |
||
21 | */ |
||
22 | private $user; |
||
23 | |||
24 | /** |
||
25 | * @var \DateTimeImmutable |
||
26 | */ |
||
27 | private $createdOn; |
||
28 | |||
29 | /** |
||
30 | * @var bool |
||
31 | */ |
||
32 | private $passwordReset; |
||
33 | |||
34 | /** |
||
35 | * @param UuidInterface $id |
||
36 | * @param string $hashCode |
||
37 | * @param User $user |
||
38 | * @param \DateTimeImmutable $createdOn |
||
39 | * @param bool $passwordReset |
||
40 | */ |
||
41 | public function __construct( |
||
42 | UuidInterface $id, |
||
43 | string $hashCode, |
||
44 | User $user, |
||
45 | \DateTimeImmutable $createdOn, |
||
46 | bool $passwordReset |
||
47 | ) { |
||
48 | $this->id = $id; |
||
49 | $this->hashCode = $hashCode; |
||
50 | $this->user = $user; |
||
51 | $this->createdOn = $createdOn; |
||
52 | $this->passwordReset = $passwordReset; |
||
53 | } |
||
54 | |||
55 | /** |
||
56 | * @return UuidInterface |
||
57 | */ |
||
58 | public function getId(): UuidInterface |
||
61 | } |
||
62 | |||
63 | /** |
||
64 | * @return string |
||
65 | */ |
||
66 | public function getHashCode(): string |
||
67 | { |
||
68 | return $this->hashCode; |
||
69 | } |
||
70 | |||
71 | /** |
||
72 | * @return User |
||
73 | */ |
||
74 | public function getUser(): User |
||
75 | { |
||
76 | return $this->user; |
||
77 | } |
||
78 | |||
79 | /** |
||
80 | * @return \DateTimeImmutable |
||
81 | */ |
||
82 | public function getCreatedOn(): \DateTimeImmutable |
||
83 | { |
||
84 | return $this->createdOn; |
||
85 | } |
||
86 | |||
87 | /** |
||
88 | * @return bool |
||
89 | */ |
||
90 | public function isPasswordReset(): bool |
||
93 | } |
||
94 | } |
||
95 |