Notification::setRead()   A
last analyzed

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
nc 1
nop 1
1
<?php
2
3
namespace JK\NotificationBundle\Entity;
4
5
use Gedmo\Timestampable\Traits\Timestampable;
6
7
class Notification
8
{
9
    use Timestampable;
10
11
    /**
12
     * @var int
13
     */
14
    protected $id;
15
16
    /**
17
     * @var string
18
     */
19
    protected $title;
20
21
    /**
22
     * @var string
23
     */
24
    protected $content;
25
26
    /**
27
     * @var string
28
     */
29
    protected $ownerId;
30
31
    /**
32
     * @var string
33
     */
34
    protected $ownerReference;
35
36
    /**
37
     * @var bool
38
     */
39
    protected $read = false;
40
41
    public function getId(): int
42
    {
43
        return $this->id;
44
    }
45
46
    public function setId(int $id): void
47
    {
48
        $this->id = $id;
49
    }
50
51
    public function getTitle(): string
52
    {
53
        return $this->title;
54
    }
55
56
    public function setTitle(string $title): void
57
    {
58
        $this->title = $title;
59
    }
60
61
    public function getContent(): string
62
    {
63
        return $this->content;
64
    }
65
66
    public function setContent(string $content): void
67
    {
68
        $this->content = $content;
69
    }
70
71
    public function isRead(): bool
72
    {
73
        return $this->read;
74
    }
75
76
    public function setRead(bool $read): void
77
    {
78
        $this->read = $read;
79
    }
80
81
    public function getOwnerId(): string
82
    {
83
        return $this->ownerId;
84
    }
85
86
    public function setOwnerId(string $ownerId): void
87
    {
88
        $this->ownerId = $ownerId;
89
    }
90
91
    public function hasOwnerId(): bool
92
    {
93
        return null !== $this->ownerId;
94
    }
95
96
    public function getOwnerReference(): string
97
    {
98
        return $this->ownerReference;
99
    }
100
101
    public function setOwnerReference(string $ownerReference): void
102
    {
103
        $this->ownerReference = $ownerReference;
104
    }
105
}
106