Route::getController()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
/**
3
 * ZfDebugModule. WebUI and Console commands for debugging ZF2 apps.
4
 *
5
 * @license http://www.opensource.org/licenses/mit-license.html MIT License
6
 * @copyright 2016 Vítor Brandão <[email protected]>
7
 */
8
9
namespace Noiselabs\ZfDebugModule\Util\Routing;
10
11
class Route
12
{
13
    /**
14
     * @var string
15
     */
16
    private $name;
17
18
    /**
19
     * @var string
20
     */
21
    private $url;
22
23
    /**
24
     * @var string
25
     */
26
    private $controller;
27
28
    /**
29
     * @var string
30
     */
31
    private $action;
32
33
    /**
34
     * @param string $name
35
     * @param $url
36
     * @param string $controller
37
     * @param string $action
38
     */
39 15
    public function __construct($name, $url, $controller, $action)
40
    {
41 15
        $this->name = $name;
42 15
        $this->url = $url;
43 15
        $this->controller = $controller;
44 15
        $this->action = $action;
45 15
    }
46
47
    /**
48
     * @return string
49
     */
50 15
    public function getName()
51
    {
52 15
        return $this->name;
53
    }
54
55
    /**
56
     * @return string
57
     */
58 11
    public function getUrl()
59
    {
60 11
        return $this->url;
61
    }
62
63
    /**
64
     * @return string
65
     */
66 8
    public function getController()
67
    {
68 8
        return $this->controller;
69
    }
70
71
    /**
72
     * @return string
73
     */
74 8
    public function getAction()
75
    {
76 8
        return $this->action;
77
    }
78
}
79