User::getName()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
namespace SafeCrow\Model;
4
5
/**
6
 * Class User
7
 * @package SafeCrow\Model
8
 */
9
class User
10
{
11
    /**
12
     * @var int
13
     */
14
    private $id;
15
16
    /**
17
     * @var string
18
     */
19
    private $name;
20
21
    /**
22
     * @var string|null
23
     */
24
    private $email;
25
26
    /**
27
     * @var string|null
28
     */
29
    private $phone;
30
31
    /**
32
     * @var \DateTime
33
     */
34
    private $registeredAt;
35
36
    /**
37
     * @return int
38
     */
39
    public function getId(): int
40
    {
41
        return $this->id;
42
    }
43
44
    /**
45
     * @param int $id
46
     * @return User
47
     */
48
    public function setId(int $id): User
49
    {
50
        $this->id = $id;
51
52
        return $this;
53
    }
54
55
    /**
56
     * @return string
57
     */
58
    public function getName(): string
59
    {
60
        return $this->name;
61
    }
62
63
    /**
64
     * @param string $name
65
     * @return User
66
     */
67
    public function setName(string $name): User
68
    {
69
        $this->name = $name;
70
71
        return $this;
72
    }
73
74
    /**
75
     * @return null|string
76
     */
77
    public function getEmail(): string
78
    {
79
        return $this->email;
80
    }
81
82
    /**
83
     * @param null|string $email
84
     * @return User
85
     */
86
    public function setEmail($email): User
87
    {
88
        $this->email = $email;
89
90
        return $this;
91
    }
92
93
    /**
94
     * @return null|string
95
     */
96
    public function getPhone()
97
    {
98
        return $this->phone;
99
    }
100
101
    /**
102
     * @param null|string $phone
103
     * @return User
104
     */
105
    public function setPhone($phone): User
106
    {
107
        $this->phone = $phone;
108
109
        return $this;
110
    }
111
112
    /**
113
     * @return \DateTime
114
     */
115
    public function getRegisteredAt(): \DateTime
116
    {
117
        return $this->registeredAt;
118
    }
119
120
    /**
121
     * @param \DateTime $registeredAt
122
     * @return User
123
     */
124
    public function setRegisteredAt(\DateTime $registeredAt): User
125
    {
126
        $this->registeredAt = $registeredAt;
127
128
        return $this;
129
    }
130
}
131