Weekday::getType()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 3
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
eloc 1
nc 1
nop 0
crap 1
1
<?php
2
declare(strict_types=1);
3
/**
4
 * This file is part of the Enum package.
5
 * For the full copyright information please view the LICENCE file that was
6
 * distributed with this package.
7
 *
8
 * @copyright Simon Deeley 2017
9
 */
10
11
namespace simondeeley\Enums;
12
13
use simondeeley\Enum;
14
15
/**
16
 * Example of an enum providing the days of the week
17
 *
18
 * @author Simon Deeley <[email protected]>
19
 * @final
20
 */
21
final class Weekday extends Enum
22
{
23
    const MONDAY = 'Monday';
24
    const TUESDAY = 'Tuesday';
25
    const WEDNESDAY = 'Wednesday';
26
    const THURSDAY = 'Thursday';
27
    const FRIDAY = 'Friday';
28
    const SATURDAY = 'Saturday';
29
    const SUNDAY = 'Sunday';
30
31
    /**
32
     * Returns the type of this enum
33
     *
34
     * @return string
35
     */
36 9
    final public static function getType(): string
0 ignored issues
show
Coding Style introduced by
Unnecessary FINAL modifier in FINAL class
Loading history...
37
    {
38 9
        return 'WEEKDAY';
39
    }
40
}
41