Passed
Push — master ( e66a3e...15c60f )
by Paweł
04:21
created

Bookmark   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 29
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 4
eloc 11
c 1
b 0
f 1
dl 0
loc 29
rs 10

4 Methods

Rating   Name   Duplication   Size   Complexity  
A getTimeInSeconds() 0 3 1
A setTitle() 0 3 1
A setTimeInSeconds() 0 3 1
A getTitle() 0 3 1
1
<?php
2
3
namespace App\Entity;
4
5
use App\Model\BookmarkInterface;
6
use App\Model\LessonAwareTrait;
7
use App\Model\OptionalUserAwareTrait;
8
use App\Model\PersistableAwareTrait;
9
use App\Model\TimestampableAwareTrait;
10
11
class Bookmark implements BookmarkInterface
12
{
13
    use PersistableAwareTrait;
14
    use TimestampableAwareTrait;
15
    use OptionalUserAwareTrait;
16
    use LessonAwareTrait;
17
18
    private $title;
19
20
    private $timeInSeconds = 0;
21
22
    public function getTitle(): ?string
23
    {
24
        return $this->title;
25
    }
26
27
    public function setTitle(string $title): void
28
    {
29
        $this->title = $title;
30
    }
31
32
    public function getTimeInSeconds(): int
33
    {
34
        return $this->timeInSeconds;
35
    }
36
37
    public function setTimeInSeconds(int $timeInSeconds): void
38
    {
39
        $this->timeInSeconds = $timeInSeconds;
40
    }
41
}
42