Passed
Pull Request — 1.11.x (#4900)
by Angel Fernando Quiroz
09:12
created

Log::getId()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 1
c 1
b 0
f 0
dl 0
loc 3
rs 10
cc 1
nop 0
nc 1
1
<?php
2
3
/* For licensing terms, see /license.txt */
4
5
namespace Chamilo\PluginBundle\ExerciseMonitoring\Entity;
6
7
use Chamilo\CoreBundle\Entity\TrackEExercises;
8
use Chamilo\CoreBundle\Traits\TimestampableTypedEntity;
9
use Chamilo\CourseBundle\Entity\CQuiz;
10
use Doctrine\ORM\Mapping as ORM;
11
12
/**
13
 * @ORM\Entity(repositoryClass="Chamilo\PluginBundle\ExerciseMonitoring\Repository\LogRepository")
14
 * @ORM\Table(name="plugin_exercisemonitoring_log")
15
 */
16
class Log
17
{
18
    use TimestampableTypedEntity;
19
20
    /**
21
     * @var int
22
     *
23
     * @ORM\Column(name="id", type="integer")
24
     * @ORM\Id
25
     * @ORM\GeneratedValue
26
     */
27
    protected $id;
28
29
    /**
30
     * @var CQuiz
31
     *
32
     * @ORM\ManyToOne(targetEntity="Chamilo\CourseBundle\Entity\CQuiz")
33
     * @ORM\JoinColumn(name="exercise_id", referencedColumnName="iid")
34
     */
35
    protected $exercise;
36
37
    /**
38
     * @var TrackEExercises
39
     *
40
     * @ORM\ManyToOne(targetEntity="Chamilo\CoreBundle\Entity\TrackEExercises")
41
     * @ORM\JoinColumn(name="exe_id", referencedColumnName="exe_id")
42
     */
43
    private $exe;
44
45
    /**
46
     * @var int
47
     *
48
     * @ORM\Column(name="level", type="integer")
49
     */
50
    private $level;
51
52
    /**
53
     * @var string
54
     *
55
     * @ORM\Column(name="image_filename", type="string")
56
     */
57
    private $imageFilename;
58
59
    /**
60
     * @var bool
61
     *
62
     * @ORM\Column(name="removed", type="boolean", nullable=false, options={"default": false})
63
     */
64
    private $removed;
65
66
    public function __construct()
67
    {
68
        $this->removed = false;
69
    }
70
71
    public function getId(): int
72
    {
73
        return $this->id;
74
    }
75
76
    public function getExercise(): CQuiz
77
    {
78
        return $this->exercise;
79
    }
80
81
    public function setExercise(CQuiz $exercise): Log
82
    {
83
        $this->exercise = $exercise;
84
85
        return $this;
86
    }
87
88
    public function getExe(): ?TrackEExercises
89
    {
90
        return $this->exe;
91
    }
92
93
    public function setExe(?TrackEExercises $exe): Log
94
    {
95
        $this->exe = $exe;
96
97
        return $this;
98
    }
99
100
    public function getLevel(): int
101
    {
102
        return $this->level;
103
    }
104
105
    public function setLevel(int $level): Log
106
    {
107
        $this->level = $level;
108
109
        return $this;
110
    }
111
112
    public function getImageFilename(): string
113
    {
114
        return $this->imageFilename;
115
    }
116
117
    public function setImageFilename(string $imageFilename): Log
118
    {
119
        $this->imageFilename = $imageFilename;
120
121
        return $this;
122
    }
123
124
    public function isRemoved(): bool
125
    {
126
        return $this->removed;
127
    }
128
129
    public function setRemoved(bool $removed): void
130
    {
131
        $this->removed = $removed;
132
    }
133
}
134