Passed
Push — master ( 86b291...5e082c )
by Willy
02:08
created

WeaponInfoValueObject   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 55
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 0%

Importance

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

4 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 9 1
A getDamage() 0 4 1
A getWeaponSpeed() 0 4 1
A getDps() 0 4 1
1
<?php
2
3
namespace Kubinashi\BattlenetApi\WorldOfWarcraft\CharacterProfileApi\Model\Item;
4
5
/**
6
 * @author  Willy Reiche
7
 * @since   2017-08-23
8
 * @version 1.0
9
 */
10
class WeaponInfoValueObject
11
{
12
    /**
13
     * @var DamageValueObject
14
     */
15
    private $damage;
16
    /**
17
     * @var float
18
     */
19
    private $weaponSpeed;
20
    /**
21
     * @var float
22
     */
23
    private $dps;
24
25
    /**
26
     * WeaponInfoValueObject constructor.
27
     * @param DamageValueObject $damage
28
     * @param float             $weaponSpeed
29
     * @param float             $dps
30
     */
31
    public function __construct(
32
        $damage,
33
        $weaponSpeed,
34
        $dps
35
    ) {
36
        $this->damage = $damage;
37
        $this->weaponSpeed = $weaponSpeed;
38
        $this->dps = $dps;
39
    }
40
41
    /**
42
     * @return DamageValueObject
43
     */
44
    public function getDamage()
45
    {
46
        return $this->damage;
47
    }
48
49
    /**
50
     * @return float
51
     */
52
    public function getWeaponSpeed()
53
    {
54
        return $this->weaponSpeed;
55
    }
56
57
    /**
58
     * @return float
59
     */
60
    public function getDps()
61
    {
62
        return $this->dps;
63
    }
64
}
65