Passed
Push — master ( 782176...fdfe0b )
by Peter
44s
created

DetailedPlayer::createFromArray()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 22
Code Lines 18

Duplication

Lines 22
Ratio 100 %

Code Coverage

Tests 18
CRAP Score 1

Importance

Changes 0
Metric Value
dl 22
loc 22
ccs 18
cts 18
cp 1
rs 9.2
c 0
b 0
f 0
cc 1
eloc 18
nc 1
nop 1
crap 1
1
<?php
2
3
namespace PtrTn\Battlerite\Dto\Player;
4
5
class DetailedPlayer
6
{
7
    /**
8
     * @var string
9
     */
10
    public $type;
11
12
    /**
13
     * @var string
14
     */
15
    public $id;
16
17
    /**
18
     * @var string
19
     */
20
    public $name;
21
22
    /**
23
     * @var string
24
     */
25
    public $patchVersion;
26
27
    /**
28
     * @var string
29
     */
30
    public $shardId;
31
32
    /**
33
     * @var int
34
     */
35
    public $picture;
36
37
    /**
38
     * @var int
39
     */
40
    public $title;
41
42
    /**
43
     * @var string
44
     */
45
    public $titleId;
46
47
    /**
48
     * @var Stats
49
     */
50
    public $stats;
51
52 1
    public function __construct(
53
        string $type,
54
        string $id,
55
        string $name,
56
        string $patchVersion,
57
        string $shardId,
58
        int $picture,
59
        int $title,
60
        string $titleId,
61
        Stats $stats
62
    ) {
63 1
        $this->type = $type;
64 1
        $this->id = $id;
65 1
        $this->name = $name;
66 1
        $this->patchVersion = $patchVersion;
67 1
        $this->shardId = $shardId;
68 1
        $this->picture = $picture;
69 1
        $this->title = $title;
70 1
        $this->titleId = $titleId;
71 1
        $this->stats = $stats;
72 1
    }
73
}
74