Rouble::getDerivative()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 1
dl 0
loc 3
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: rikosage
5
 * Date: 12/02/19
6
 * Time: 15:44
7
 */
8
9
namespace rikosage\NumberWordify\Unit\Currency;
10
11
use rikosage\NumberWordify\Base\Declinable;
12
use rikosage\NumberWordify\Unit\DerivativeInterface;
13
use rikosage\NumberWordify\Unit\UnitInterface;
14
15
/**
16
 * Единица измерения: рубль
17
 *
18
 * @package rikosage\NumberWordify\Unit\Currency
19
 */
20
class Rouble implements UnitInterface, DerivativeInterface
21
{
22
    /**
23
     * @inheritdoc
24
     */
25
    public function getGender()
26
    {
27
        return Declinable::TYPE_MASCULINE;
28
    }
29
30
    /**
31
     * @inheritdoc
32
     */
33
    public function getItems()
34
    {
35
        return ['рубль', 'рубля', 'рублей'];
36
    }
37
38
    /**
39
     * @inheritdoc
40
     */
41
    public function getDerivative(): UnitInterface
42
    {
43
        return new Copeck();
44
    }
45
}