DirectionEntity::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 5

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 6
CRAP Score 1

Importance

Changes 2
Bugs 0 Features 2
Metric Value
c 2
b 0
f 2
dl 0
loc 7
rs 9.4286
ccs 6
cts 6
cp 1
cc 1
eloc 5
nc 1
nop 4
crap 1
1
<?php
2
3
namespace OpenTribes\Core\Entity;
4
5
6
class DirectionEntity {
7
    private $name = '';
8
    private $key = '';
9
    private $minDegree = 0.0;
10
    private $maxDegree = 0.0;
11
12 7
    public function __construct($key, $name, $minDegree, $maxDegree)
13
    {
14 7
        $this->key = $key;
15 7
        $this->name = $name;
16 7
        $this->minDegree = $minDegree;
17 7
        $this->maxDegree = $maxDegree;
18 7
    }
19
20
21
    /**
22
     * @return string
23
     */
24 3
    public function getName()
25
    {
26 3
        return $this->name;
27
    }
28
29
}