Total Complexity | 6 |
Total Lines | 91 |
Duplicated Lines | 0 % |
Coverage | 90% |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
9 | class User extends \stdClass |
||
10 | { |
||
11 | const SEX_MALE = 'male'; |
||
12 | const SEX_FEMALE = 'female'; |
||
13 | |||
14 | /** |
||
15 | * @var string |
||
16 | */ |
||
17 | public $id; |
||
18 | |||
19 | /** |
||
20 | * @var string |
||
21 | */ |
||
22 | public $firstname; |
||
23 | |||
24 | /** |
||
25 | * @var string |
||
26 | */ |
||
27 | public $lastname; |
||
28 | |||
29 | /** |
||
30 | * @var string |
||
31 | */ |
||
32 | public $email; |
||
33 | |||
34 | /** |
||
35 | * @var bool |
||
36 | */ |
||
37 | public $emailVerified = false; |
||
38 | |||
39 | /** |
||
40 | * @var \DateTime|null |
||
41 | */ |
||
42 | protected $birthday; |
||
43 | |||
44 | /** |
||
45 | * @var string|null |
||
46 | */ |
||
47 | public $username; |
||
48 | |||
49 | /** |
||
50 | * Should be female or male |
||
51 | * |
||
52 | * @var string|null |
||
53 | */ |
||
54 | protected $sex; |
||
55 | |||
56 | /** |
||
57 | * @var string|null |
||
58 | */ |
||
59 | public $fullname; |
||
60 | |||
61 | /** |
||
62 | * @var string|null |
||
63 | */ |
||
64 | public $pictureURL; |
||
65 | |||
66 | /** |
||
67 | * @return \DateTime|null |
||
68 | */ |
||
69 | 1 | public function getBirthday(): ?\DateTime |
|
70 | { |
||
71 | 1 | return $this->birthday; |
|
72 | } |
||
73 | |||
74 | /** |
||
75 | * @param \DateTime|null $birthday |
||
76 | */ |
||
77 | 2 | public function setBirthday(?\DateTime $birthday): void |
|
78 | { |
||
79 | 2 | $this->birthday = $birthday; |
|
80 | } |
||
81 | |||
82 | /** |
||
83 | * @return string|null |
||
84 | */ |
||
85 | 2 | public function getSex(): ?string |
|
86 | { |
||
87 | 2 | return $this->sex; |
|
88 | } |
||
89 | |||
90 | /** |
||
91 | * @param string $sex |
||
92 | */ |
||
93 | 3 | public function setSex(string $sex): void |
|
100 | } |
||
101 | } |
||
102 |