Completed
Push — master ( 17976d...325209 )
by Portey
07:00
created

EpisodeEnum   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 29
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 1
Bugs 1 Features 1
Metric Value
wmc 2
c 1
b 1
f 1
lcom 0
cbo 1
dl 0
loc 29
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getValues() 0 17 1
A getName() 0 4 1
1
<?php
2
/**
3
 * Date: 07.12.15
4
 *
5
 * @author Portey Vasil <[email protected]>
6
 */
7
8
namespace Youshido\Tests\StarWars\Schema;
9
10
11
use Youshido\GraphQL\Type\Object\AbstractEnumType;
12
13
class EpisodeEnum extends AbstractEnumType
14
{
15
16
    public function getValues()
17
    {
18
        return [
19
            'NEWHOPE' => [
20
                'value'       => 4,
21
                'description' => 'Released in 1977.'
22
            ],
23
            'EMPIRE'  => [
24
                'value'       => 5,
25
                'description' => 'Released in 1980.'
26
            ],
27
            'JEDI'    => [
28
                'value'       => 6,
29
                'description' => 'Released in 1983.'
30
            ],
31
        ];
32
    }
33
34
    /**
35
     * @return String type name
36
     */
37
    public function getName()
38
    {
39
        return 'Episode';
40
    }
41
}