Completed
Push — master ( 4b2e15...e1e67f )
by Elf
03:57
created

Sex::string()   A

Complexity

Conditions 3
Paths 3

Size

Total Lines 8
Code Lines 5

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 12

Importance

Changes 0
Metric Value
cc 3
eloc 5
nc 3
nop 1
dl 0
loc 8
ccs 0
cts 8
cp 0
crap 12
rs 9.4285
c 0
b 0
f 0
1
<?php
2
3
namespace ElfSundae\Laravel\Support\Constants;
4
5
use ElfSundae\Laravel\Support\Enum;
6
use ElfSundae\Laravel\Support\Traits\EnumKeyString;
7
8
class Sex extends Enum
9
{
10
    use EnumKeyString;
11
12
    const UNKNOWN = 0;
13
    const MALE = 1;
14
    const FEMALE = 2;
15
16
    /**
17
     * The transfer keys.
18
     *
19
     * @var array
20
     */
21
    protected static $transferKeys = [
22
        'UNKNOWN' => '',
23
        'MALE' => '男',
24
        'FEMALE' => '女',
25
    ];
26
}
27