Scorer::getGoals()   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
namespace OSS\CoreBundle\Entity;
4
5
class Scorer
6
{
7
    /**
8
     * @var Scorer[]
9
     */
10
    static $scorer = array();
11
12
    /**
13
     * @var Player
14
     */
15
    private $player;
16
17
    /**
18
     * @var int
19
     */
20
    private $goals;
21
22
    /**
23
     * @return Player
24
     */
25 2
    public function getPlayer()
26
    {
27 2
        return $this->player;
28
    }
29
30
    /**
31
     * @param Player $player
32
     */
33 2
    public function setPlayer(Player $player)
34
    {
35 2
        $this->player = $player;
36 2
    }
37
38
    /**
39
     * @return int
40
     */
41 2
    public function getGoals()
42
    {
43 2
        return $this->goals;
44
    }
45
46
    /**
47
     * @param int $goals
48
     */
49
    public function setGoals($goals)
50
    {
51
        $this->goals = $goals;
52
    }
53
54 2
    public function incrementGoals()
55
    {
56 2
        $this->goals++;
57 2
    }
58
}
59