Passed
Push — master ( 4c4023...2b0e92 )
by Julito
07:08
created

CStudentPublicationRelDocument::getPublication()   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
declare(strict_types=1);
4
5
/* For licensing terms, see /license.txt */
6
7
namespace Chamilo\CourseBundle\Entity;
8
9
use Doctrine\ORM\Mapping as ORM;
10
11
/**
12
 * CStudentPublicationRelDocument.
13
 *
14
 * @ORM\Table(
15
 *     name="c_student_publication_rel_document",
16
 *     indexes={
17
 *     }
18
 * )
19
 * @ORM\Entity
20
 */
21
class CStudentPublicationRelDocument
22
{
23
    /**
24
     * @ORM\Column(name="iid", type="integer")
25
     * @ORM\Id
26
     * @ORM\GeneratedValue
27
     */
28
    protected int $iid;
29
30
    /**
31
     * @ORM\ManyToOne(targetEntity="CStudentPublication")
32
     * @ORM\JoinColumn(name="work_id", referencedColumnName="iid", onDelete="CASCADE")
33
     */
34
    protected CStudentPublication $publication;
35
36
    /**
37
     * @ORM\ManyToOne(targetEntity="Chamilo\CourseBundle\Entity\CDocument")
38
     * @ORM\JoinColumn(name="document_id", referencedColumnName="iid", onDelete="CASCADE")
39
     */
40
    protected CDocument $document;
41
42
    public function getPublication(): CStudentPublication
43
    {
44
        return $this->publication;
45
    }
46
47
    public function setPublication(CStudentPublication $publication): self
48
    {
49
        $this->publication = $publication;
50
51
        return $this;
52
    }
53
54
    public function getDocument(): CDocument
55
    {
56
        return $this->document;
57
    }
58
59
    public function setDocument(CDocument $document): self
60
    {
61
        $this->document = $document;
62
63
        return $this;
64
    }
65
66
    /**
67
     * @return int
68
     */
69
    public function getIid()
70
    {
71
        return $this->iid;
72
    }
73
}
74