Completed
Push — master ( f1d84d...653498 )
by Derek Stephen
03:51
created

EmailLink   A

Complexity

Total Complexity 8

Size/Duplication

Total Lines 97
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 8
lcom 0
cbo 0
dl 0
loc 97
ccs 0
cts 36
cp 0
rs 10
c 0
b 0
f 0

8 Methods

Rating   Name   Duplication   Size   Complexity  
A getId() 0 4 1
A setId() 0 5 1
A getUser() 0 4 1
A setUser() 0 5 1
A getExpiryDate() 0 4 1
A setExpiryDate() 0 5 1
A getToken() 0 4 1
A setToken() 0 5 1
1
<?php
2
3
namespace Del\Entity;
4
5
use DateTime;
6
7
/**
8
 * @Entity(repositoryClass="Del\Repository\EmailLink")
9
 */
10
class EmailLink
11
{
12
    /**
13
     * @Id @Column(type="integer")
14
     * @GeneratedValue
15
     */
16
    private $id;
17
18
    /**
19
     *  @ManyToOne(targetEntity="Del\Entity\User",cascade={"persist"})
20
     */
21
    private $user;
22
23
    /**
24
     * @Column(type="datetime")
25
     */
26
    private $expiry_date;
27
28
    /**
29
     * @Column(type="string")
30
     */
31
    private $token;
32
33
    /**
34
     * @return int
35
     */
36
    public function getId()
37
    {
38
        return $this->id;
39
    }
40
41
    /**
42
     * @param int $id
43
     * @return EmailLink
44
     */
45
    public function setId($id)
46
    {
47
        $this->id = $id;
48
        return $this;
49
    }
50
51
    /**
52
     * @return User
53
     */
54
    public function getUser()
55
    {
56
        return $this->user;
57
    }
58
59
    /**
60
     * @param User $user
61
     * @return EmailLink
62
     */
63
    public function setUser($user)
64
    {
65
        $this->user = $user;
66
        return $this;
67
    }
68
69
    /**
70
     * @return DateTime
71
     */
72
    public function getExpiryDate()
73
    {
74
        return $this->expiry_date;
75
    }
76
77
    /**
78
     * @param DateTime $expiry_date
79
     * @return EmailLink
80
     */
81
    public function setExpiryDate(DateTime $expiry_date)
82
    {
83
        $this->expiry_date = $expiry_date;
84
        return $this;
85
    }
86
87
    /**
88
     * @return mixed
89
     */
90
    public function getToken()
91
    {
92
        return $this->token;
93
    }
94
95
    /**
96
     * @param mixed $token
97
     * @return EmailLink
98
     */
99
    public function setToken($token)
100
    {
101
        $this->token = $token;
102
        return $this;
103
    }
104
105
106
}
107
108
109