Completed
Push — PSR-11-2 ( a5ad88...7f5041 )
by Nikolaos
03:59
created

None   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 62.5%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 1
dl 0
loc 22
c 0
b 0
f 0
ccs 5
cts 8
cp 0.625
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A serialize() 0 4 1
A unserialize() 0 4 1
1
<?php
2
3
/**
4
 * This file is part of the Phalcon Framework.
5
 *
6
 * (c) Phalcon Team <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE.txt
9
 * file that was distributed with this source code.
10
 */
11
12
declare(strict_types=1);
13
14
namespace Phalcon\Storage\Serializer;
15
16
/**
17
 * Class None
18
 *
19
 * @package Phalcon\Storage\Serializer
20
 */
21
class None extends AbstractSerializer
22
{
23
    /**
24
     * Serializes data
25
     *
26
     * @return string
27
     */
28 1
    public function serialize()
29
    {
30 1
        return $this->data;
31
    }
32
33
    /**
34
     * Unserializes data
35
     *
36
     * @param string $data
37
     */
38 1
    public function unserialize($data): void
39
    {
40 1
        $this->data = $data;
41 1
    }
42
}
43