ValueWriter   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Test Coverage

Coverage 100%

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A write() 0 4 1
1
<?php
2
3
/*
4
 * This file is part of Payload.
5
 *
6
 * (c) DraperStudio <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace DraperStudio\Payload\Writers;
13
14
use DraperStudio\Payload\Serialisers\ValueSerialiser;
15
16
/**
17
 * Class ValueWriter.
18
 */
19
class ValueWriter extends Writer
20
{
21
    /**
22
     * @param $path
23
     * @param $input
24
     *
25
     * @return bool
26
     */
27 3
    public function write($path, $input)
28
    {
29 3
        return $this->put($path, (new ValueSerialiser())->serialise($input));
30
    }
31
}
32