NodeInfo   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 49
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 4
c 1
b 0
f 0
lcom 0
cbo 0
dl 0
loc 49
ccs 11
cts 11
cp 1
rs 10

4 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 1
A getServer() 0 4 1
A getId() 0 4 1
A getPriority() 0 4 1
1
<?php
2
3
namespace Phloppy;
4
5
class NodeInfo {
6
7
    /**
8
     * @var string
9
     */
10
    private $id;
11
12
    /**
13
     * @var string
14
     */
15
    private $server;
16
17
    /**
18
     * @var int
19
     */
20
    private $priority;
21
22 2
    public function __construct($id, $server, $priority)
23
    {
24 2
        $this->id       = $id;
25 2
        $this->server   = $server;
26 2
        $this->priority = $priority;
27 2
    }
28
29
    /**
30
     * @return string
31
     */
32 2
    public function getServer()
33
    {
34 2
        return $this->server;
35
    }
36
37
38
    /**
39
     * @return string
40
     */
41 1
    public function getId()
42
    {
43 1
        return $this->id;
44
    }
45
46
    /**
47
     * @return int
48
     */
49 1
    public function getPriority()
50
    {
51 1
        return $this->priority;
52
    }
53
}
54