Passed
Push — master ( 56813c...ebb300 )
by Paweł
03:29
created

Trophy::getName()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 3
ccs 0
cts 2
cp 0
crap 2
rs 10
1
<?php
2
3
declare(strict_types=1);
4
5
namespace AardsGerds\Game\Inventory\Trophy;
6
7
use AardsGerds\Game\Inventory\Coin;
8
use AardsGerds\Game\Inventory\InventoryItem;
9
10
abstract class Trophy implements InventoryItem
11
{
12
    public function __construct(
13
        protected string $name,
14
        protected string $description,
15
        protected Coin $sellValue,
16
    ) {}
17
18
    public function getName(): string
19
    {
20
        return $this->name;
21
    }
22
23
    public function getDescription(): string
24
    {
25
        return $this->description;
26
    }
27
28
    public function getSellValue(): Coin
29
    {
30
        return $this->sellValue;
31
    }
32
}
33