Blog::setLink()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
1
<?php
2
3
declare(strict_types=1);
4
5
/*
6
 * This file is part of the Sonata Project package.
7
 *
8
 * (c) Thomas Rabaix <[email protected]>
9
 *
10
 * For the full copyright and license information, please view the LICENSE
11
 * file that was distributed with this source code.
12
 */
13
14
namespace Sonata\NewsBundle\Model;
15
16
use Sonata\NewsBundle\Permalink\PermalinkInterface;
17
18
class Blog implements BlogInterface
19
{
20
    /**
21
     * @var string
22
     */
23
    protected $title;
24
25
    /**
26
     * @var string
27
     */
28
    protected $link;
29
30
    /**
31
     * @var string
32
     */
33
    protected $description;
34
35
    /**
36
     * @var PermalinkInterface
37
     */
38
    protected $permalinkGenerator;
39
40
    /**
41
     * @param string $title
42
     * @param string $link
43
     * @param string $description
44
     */
45
    public function __construct($title, $link, $description, PermalinkInterface $permalinkGenerator)
46
    {
47
        $this->title = $title;
48
        $this->link = $link;
49
        $this->description = $description;
50
        $this->permalinkGenerator = $permalinkGenerator;
51
    }
52
53
    public function getPermalinkGenerator()
54
    {
55
        return $this->permalinkGenerator;
56
    }
57
58
    public function setDescription($description): void
59
    {
60
        $this->description = $description;
61
    }
62
63
    public function getDescription()
64
    {
65
        return $this->description;
66
    }
67
68
    public function setLink($link): void
69
    {
70
        $this->link = $link;
71
    }
72
73
    public function getLink()
74
    {
75
        return $this->link;
76
    }
77
78
    public function setTitle($title): void
79
    {
80
        $this->title = $title;
81
    }
82
83
    public function getTitle()
84
    {
85
        return $this->title;
86
    }
87
}
88