Test Failed
Push — master ( 085c8a...c2447a )
by Alexey
01:55
created

Workspace::getUrl()   A

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 0
1
<?php
2
3
/*
4
 * This file is part of the WoW-Apps/Symfony-Slack-Bot bundle for Symfony.
5
 * https://github.com/wow-apps/symfony-slack-bot
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 * https://github.com/wow-apps/symfony-slack-bot/blob/master/LICENSE
10
 *
11
 * For technical documentation.
12
 * https://wow-apps.github.io/symfony-slack-bot/docs/
13
 *
14
 * Author Alexey Samara <[email protected]>
15
 *
16
 * Copyright 2016 WoW-Apps.
17
 */
18
19
namespace WowApps\SlackBundle\Entity;
20
21
class Workspace
22
{
23
    /**
24
     * @var string
25
     */
26
    private $url;
27
28
    /**
29
     * @var string|null
30
     */
31
    private $defaultIcon;
32
33
    /**
34
     * @var string|null
35
     */
36
    private $defaultUser;
37
38
    /**
39
     * Workspace constructor.
40
     *
41
     * @param string      $url
42
     * @param string|null $defaultIcon
43
     * @param string|null $defaultUser
44
     */
45
    public function __construct(string $url, string $defaultIcon = null, string $defaultUser = null)
46
    {
47
        $this->url = $url;
48
        $this->defaultIcon = empty($defaultIcon) ? null : $defaultIcon;
49
        $this->defaultUser = empty($defaultUser) ? null : $defaultUser;
50
    }
51
52
    /**
53
     * @return string
54
     */
55
    public function getUrl(): string
56
    {
57
        return $this->url;
58
    }
59
60
    /**
61
     * @return string|null
62
     */
63
    public function getDefaultIcon()
64
    {
65
        return $this->defaultIcon;
66
    }
67
68
    /**
69
     * @return string|null
70
     */
71
    public function getDefaultUser()
72
    {
73
        return $this->defaultUser;
74
    }
75
}
76