Passed
Push — master ( 3f4221...33ba2d )
by Maks
03:05
created

Logs::getJsonLogFilePath()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
c 0
b 0
f 0
nc 1
nop 0
dl 0
loc 3
rs 10
1
<?php
2
/**
3
 * This code is licensed under the BSD 3-Clause License.
4
 *
5
 * Copyright (c) 2017, Maks Rafalko
6
 * All rights reserved.
7
 *
8
 * Redistribution and use in source and binary forms, with or without
9
 * modification, are permitted provided that the following conditions are met:
10
 *
11
 * * Redistributions of source code must retain the above copyright notice, this
12
 *   list of conditions and the following disclaimer.
13
 *
14
 * * Redistributions in binary form must reproduce the above copyright notice,
15
 *   this list of conditions and the following disclaimer in the documentation
16
 *   and/or other materials provided with the distribution.
17
 *
18
 * * Neither the name of the copyright holder nor the names of its
19
 *   contributors may be used to endorse or promote products derived from
20
 *   this software without specific prior written permission.
21
 *
22
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
23
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
24
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
25
 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
26
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
27
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
28
 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
29
 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
30
 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31
 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32
 */
33
34
declare(strict_types=1);
35
36
namespace Infection\Configuration\Entry;
37
38
/**
39
 * @internal
40
 */
41
final class Logs
42
{
43
    private $textLogFilePath;
44
    private $summaryLogFilePath;
45
    private $jsonLogFilePath;
46
    private $debugLogFilePath;
47
    private $perMutatorFilePath;
48
    private $badge;
49
50
    public function __construct(
51
        ?string $textLogFilePath,
52
        ?string $summaryLogFilePath,
53
        ?string $jsonLogFilePath,
54
        ?string $debugLogFilePath,
55
        ?string $perMutatorFilePath,
56
        ?Badge $badge
57
    ) {
58
        $this->textLogFilePath = $textLogFilePath;
59
        $this->summaryLogFilePath = $summaryLogFilePath;
60
        $this->jsonLogFilePath = $jsonLogFilePath;
61
        $this->debugLogFilePath = $debugLogFilePath;
62
        $this->perMutatorFilePath = $perMutatorFilePath;
63
        $this->badge = $badge;
64
    }
65
66
    public static function createEmpty(): self
67
    {
68
        return new self(
69
            null,
70
            null,
71
            null,
72
            null,
73
            null,
74
            null
75
        );
76
    }
77
78
    public function getTextLogFilePath(): ?string
79
    {
80
        return $this->textLogFilePath;
81
    }
82
83
    public function getSummaryLogFilePath(): ?string
84
    {
85
        return $this->summaryLogFilePath;
86
    }
87
88
    public function getJsonLogFilePath(): ?string
89
    {
90
        return $this->jsonLogFilePath;
91
    }
92
93
    public function getDebugLogFilePath(): ?string
94
    {
95
        return $this->debugLogFilePath;
96
    }
97
98
    public function getPerMutatorFilePath(): ?string
99
    {
100
        return $this->perMutatorFilePath;
101
    }
102
103
    public function getBadge(): ?Badge
104
    {
105
        return $this->badge;
106
    }
107
}
108