Completed
Push — master ( 577784...c1d3e6 )
by Portey
09:27
created

InputField   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Test Coverage

Coverage 60%

Importance

Changes 3
Bugs 1 Features 0
Metric Value
wmc 2
c 3
b 1
f 0
lcom 1
cbo 2
dl 0
loc 16
ccs 3
cts 5
cp 0.6
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getDefaultValue() 0 4 1
1
<?php
2
/*
3
* This file is a part of graphql-youshido project.
4
*
5
* @author Alexandr Viniychuk <[email protected]>
6
* created: 12/1/15 11:26 PM
7
*/
8
9
namespace Youshido\GraphQL\Type\Field;
10
11
12
use Youshido\GraphQL\Type\Config\Field\InputFieldConfig;
13
14
class InputField extends Field
15
{
16
    /** @var InputFieldConfig */
17
    protected $config;
18
19 13
    public function __construct($config)
20
    {
21 13
        $this->config = new InputFieldConfig($config);
22 13
    }
23
24
    public function getDefaultValue()
25
    {
26
        return $this->config->getDefaultValue();
27
    }
28
29
}