Player   A
last analyzed

Complexity

Total Complexity 9

Size/Duplication

Total Lines 114
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
wmc 9
lcom 0
cbo 0
dl 0
loc 114
rs 10
c 0
b 0
f 0

9 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getName() 0 4 1
A setName() 0 6 1
A getNumber() 0 4 1
A setNumber() 0 6 1
A getHeight() 0 4 1
A setHeight() 0 6 1
A isRegular() 0 4 1
A setRegular() 0 6 1
1
<?php
2
3
/*
4
 * This file is part of the rafrsr/lib-array2object package.
5
 *
6
 * (c) Rafael SR <https://github.com/rafrsr>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
namespace Rafrsr\LibArray2Object\Tests\Fixtures;
12
13
/**
14
 * Class Player.
15
 */
16
class Player
17
{
18
    /**
19
     * @var string
20
     */
21
    protected $name;
22
23
    /**
24
     * @var int
25
     */
26
    protected $number;
27
28
    /**
29
     * @var float
30
     */
31
    protected $height;
32
33
    /**
34
     * @var bool
35
     */
36
    protected $regular;
37
38
    /**
39
     * Player constructor.
40
     *
41
     * @param string $name
42
     * @param int    $number
43
     */
44
    public function __construct($name = null, $number = null)
45
    {
46
        $this->name = $name;
47
        $this->number = $number;
48
    }
49
50
    /**
51
     * @return string
52
     */
53
    public function getName()
54
    {
55
        return $this->name;
56
    }
57
58
    /**
59
     * @param string $name
60
     *
61
     * @return $this
62
     */
63
    public function setName($name)
64
    {
65
        $this->name = $name;
66
67
        return $this;
68
    }
69
70
    /**
71
     * @return int
72
     */
73
    public function getNumber()
74
    {
75
        return $this->number;
76
    }
77
78
    /**
79
     * @param int $number
80
     *
81
     * @return $this
82
     */
83
    public function setNumber($number)
84
    {
85
        $this->number = $number;
86
87
        return $this;
88
    }
89
90
    /**
91
     * @return float
92
     */
93
    public function getHeight()
94
    {
95
        return $this->height;
96
    }
97
98
    /**
99
     * @param float $height
100
     *
101
     * @return $this
102
     */
103
    public function setHeight($height)
104
    {
105
        $this->height = $height;
106
107
        return $this;
108
    }
109
110
    /**
111
     * @return bool
112
     */
113
    public function isRegular()
114
    {
115
        return $this->regular;
116
    }
117
118
    /**
119
     * @param bool $regular
120
     *
121
     * @return $this
122
     */
123
    public function setRegular($regular)
124
    {
125
        $this->regular = $regular;
126
127
        return $this;
128
    }
129
}
130