Completed
Pull Request — master (#3464)
by Julito
14:18 queued 01:15
created

CDropboxPerson::setUser()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 1
dl 0
loc 5
rs 10
c 0
b 0
f 0
1
<?php
2
3
/* For licensing terms, see /license.txt */
4
5
namespace Chamilo\CourseBundle\Entity;
6
7
use Doctrine\ORM\Mapping as ORM;
8
use Chamilo\CoreBundle\Entity\User;
9
10
/**
11
 * CDropboxPerson.
12
 *
13
 * @ORM\Table(
14
 *  name="c_dropbox_person",
15
 *  indexes={
16
 *      @ORM\Index(name="course", columns={"c_id"}),
17
 *      @ORM\Index(name="user", columns={"user_id"})
18
 *  }
19
 * )
20
 * @ORM\Entity
21
 */
22
class CDropboxPerson
23
{
24
    /**
25
     * @var int
26
     *
27
     * @ORM\Column(name="iid", type="integer")
28
     * @ORM\Id
29
     * @ORM\GeneratedValue
30
     */
31
    protected $iid;
32
33
    /**
34
     * @var int
35
     *
36
     * @ORM\Column(name="c_id", type="integer")
37
     */
38
    protected $cId;
39
40
    /**
41
     * @var int
42
     *
43
     * @ORM\Column(name="file_id", type="integer")
44
     */
45
    protected $fileId;
46
47
    /**
48
     * @var User
49
     * @ORM\ManyToOne (
50
     *    targetEntity="Chamilo\CoreBundle\Entity\User",
51
     *    inversedBy="cDropboxPersons"
52
     * )
53
     * @ORM\JoinColumn(
54
     *    name="user_id",
55
     *    referencedColumnName="id",
56
     *    onDelete="CASCADE"
57
     * )
58
     */
59
    protected $user;
60
61
    /**
62
     * Get user.
63
     *
64
     */
65
    public function getUser(): User
66
    {
67
        return $this->user;
68
    }
69
70
    /**
71
     * Set user.
72
     *
73
     */
74
    public function setUser($user)
75
    {
76
        $this->user = $user;
77
78
        return $this;
79
    }
80
81
    /**
82
     * Set cId.
83
     *
84
     * @param int $cId
85
     *
86
     * @return CDropboxPerson
87
     */
88
    public function setCId($cId)
89
    {
90
        $this->cId = $cId;
91
92
        return $this;
93
    }
94
95
    /**
96
     * Get cId.
97
     *
98
     * @return int
99
     */
100
    public function getCId()
101
    {
102
        return $this->cId;
103
    }
104
105
    /**
106
     * Set fileId.
107
     *
108
     * @param int $fileId
109
     *
110
     * @return CDropboxPerson
111
     */
112
    public function setFileId($fileId)
113
    {
114
        $this->fileId = $fileId;
115
116
        return $this;
117
    }
118
119
    /**
120
     * Get fileId.
121
     *
122
     * @return int
123
     */
124
    public function getFileId()
125
    {
126
        return $this->fileId;
127
    }
128
129
}
130