Passed
Push — master ( b4cb9f...51bac7 )
by Anthony
02:22
created

UserLogs::getUser()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace PiouPiou\RibsAdminBundle\Entity;
4
5
use Doctrine\ORM\Mapping as ORM;
6
use Gedmo\Mapping\Annotation as Gedmo;
7
8
/**
9
 * UserLogs
10
 *
11
 * @ORM\Table(name="user_logs", indexes={@ORM\Index(name="fk_user_infos_user_idx", columns={"user_id"})})
12
 * @ORM\Entity
13
 */
14
class UserLogs
15
{
16
    /**
17
     * @var integer
18
     *
19
     * @ORM\Column(name="id", type="integer", nullable=false, options={"unsigned"=true})
20
     * @ORM\Id
21
     * @ORM\GeneratedValue(strategy="NONE")
22
     */
23
    private $id;
24
25
    /**
26
     * @var \User
27
     *
28
     * @ORM\Id
29
     * @ORM\GeneratedValue(strategy="NONE")
30
     * @ORM\OneToOne(targetEntity="User")
31
     * @ORM\JoinColumns({
32
     *   @ORM\JoinColumn(name="user_id", referencedColumnName="id")
33
     * })
34
     */
35
    private $user;
36
	
37
	/**
38
	 * @var \DateTime
39
	 *
40
	 * @Gedmo\Timestampable(on="create")
41
	 * @ORM\Column(name="creation_date", type="date", nullable=true)
42
	 */
43
	private $creationDate;
44
	
45
	/**
46
	 * @var \DateTime
47
	 *
48
	 * @Gedmo\Timestampable(on="update")
49
	 * @ORM\Column(name="update_date", type="date", nullable=true)
50
	 */
51
	private $updateDate;
52
53
    /**
54
     * @return int
55
     */
56
    public function getId()
57
    {
58
        return $this->id;
59
    }
60
61
    /**
62
     * @param int $id
63
     */
64
    public function setId($id)
65
    {
66
        $this->id = $id;
67
    }
68
69
    /**
70
     * @return \User
71
     */
72
    public function getUser()
73
    {
74
        return $this->user;
75
    }
76
77
    /**
78
     * @param \User $user
79
     */
80
    public function setUser($user)
81
    {
82
        $this->user = $user;
83
    }
84
	
85
	/**
86
	 * @return \DateTime
87
	 */
88
	public function getCreationDate(): \DateTime
89
	{
90
		return $this->creationDate;
91
	}
92
	
93
	/**
94
	 * @param \DateTime $creationDate
95
	 */
96
	public function setCreationDate(\DateTime $creationDate)
97
	{
98
		$this->creationDate = $creationDate;
99
	}
100
	
101
	/**
102
	 * @return \DateTime
103
	 */
104
	public function getUpdateDate(): \DateTime
105
	{
106
		return $this->updateDate;
107
	}
108
	
109
	/**
110
	 * @param \DateTime $updateDate
111
	 */
112
	public function setUpdateDate(\DateTime $updateDate)
113
	{
114
		$this->updateDate = $updateDate;
115
	}
116
}
117
118