Completed
Pull Request — master (#77)
by Thomas
06:31
created

DefaultsConfiguration::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 1
Metric Value
cc 1
eloc 2
c 1
b 0
f 1
nc 1
nop 1
dl 0
loc 5
ccs 3
cts 3
cp 1
crap 1
rs 10
1
<?php
2
3
declare(strict_types=1);
4
5
/*
6
 * This file is part of the ekino Drupal Debug project.
7
 *
8
 * (c) ekino
9
 *
10
 * For the full copyright and license information, please view the LICENSE
11
 * file that was distributed with this source code.
12
 */
13
14
namespace Ekino\Drupal\Debug\Configuration\Model;
15
16
class DefaultsConfiguration extends AbstractConfiguration
17
{
18
    /**
19
     * @return string
20
     */
21 20
    public function getCacheDirectoryPath(): string
22
    {
23 20
        return $this->processedConfiguration['cache_directory_path'];
24
    }
25
26 20
    public function getLogger(): array
27
    {
28 20
        return $this->processedConfiguration['logger'];
29
    }
30
31
    /**
32
     * @return string|null
33
     */
34 21
    public function getCharset(): ?string
35
    {
36 21
        return $this->processedConfiguration['charset'];
37
    }
38
39
    /**
40
     * @return string|null
41
     */
42 21
    public function getFileLinkFormat(): ?string
43
    {
44 21
        return $this->processedConfiguration['file_link_format'];
45
    }
46
47
    /**
48
     * {@inheritdoc}
49
     */
50 20
    public function serialize(): ?string
51
    {
52 20
        return \serialize(array(
53 20
            $this->processedConfiguration,
54
        ));
55
    }
56
57
    /**
58
     * {@inheritdoc}
59
     */
60 17
    public function unserialize($serialized): void
61
    {
62 17
        list($this->processedConfiguration) = \unserialize($serialized);
63 17
    }
64
}
65