Completed
Pull Request — 8.x-3.x (#524)
by Sebastian
03:35
created

MapType   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
dl 0
loc 23
rs 10
c 0
b 0
f 0
wmc 3
lcom 0
cbo 1

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getName() 0 3 1
A serialize() 0 2 1
A isValidValue() 0 3 1
1
<?php
2
3
namespace Drupal\graphql\GraphQL\Type\Scalars;
4
5
use Youshido\GraphQL\Type\Scalar\AbstractScalarType;
6
7
class MapType extends AbstractScalarType {
8
9
  /**
10
   * {@inheritdoc}
11
   */
12
  public function getName() {
13
    return 'Map';
14
  }
15
16
  /**
17
   * {@inheritdoc}
18
   */
19
  public function serialize($value) {
20
  }
21
22
  /**
23
   * {@inheritdoc}
24
   */
25
  public function isValidValue($value) {
26
    return is_array($value);
27
  }
28
29
}
30