SSH2Config::getMethods()   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
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 4
rs 10
c 0
b 0
f 0
ccs 2
cts 2
cp 1
crap 1
1
<?php
2
3
namespace Dazzle\SSH;
4
5
class SSH2Config implements SSH2ConfigInterface
6
{
7
    /**
8
     * @var string
9
     */
10
    protected $host;
11
12
    /**
13
     * @var int
14
     */
15
    protected $port;
16
17
    /**
18
     * @var mixed
19
     */
20
    protected $methods;
21
22
    /**
23
     * @param string $host
24
     * @param int $port
25
     * @param mixed $methods
26
     */
27 28
    public function __construct($host = 'localhost', $port = 22, $methods = [])
28
    {
29 28
        $this->host = $host;
30 28
        $this->port = $port;
31 28
        $this->methods = $methods;
32 28
    }
33
34
    /**
35
     * @override
36
     * @inheritDoc
37
     */
38 23
    public function getHost()
39
    {
40 23
        return $this->host;
41
    }
42
43
    /**
44
     * @override
45
     * @inheritDoc
46
     */
47 23
    public function getPort()
48
    {
49 23
        return $this->port;
50
    }
51
52
    /**
53
     * @override
54
     * @inheritDoc
55
     */
56 23
    public function getMethods()
57
    {
58 23
        return $this->methods;
59
    }
60
}
61