Completed
Push — master ( be53ba...d8ac27 )
by Jan Philipp
11s
created

LogMessage   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 38
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

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

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getMessage() 0 4 1
A isError() 0 4 1
1
<?php declare(strict_types=1);
2
3
namespace Shopware\Psh\ScriptRuntime;
4
5
class LogMessage
6
{
7
    /**
8
     * @var string
9
     */
10
    private $message;
11
12
    /**
13
     * @var bool
14
     */
15
    private $error;
16
17
    /**
18
     * @param string $message
19
     * @param bool $error
20
     */
21
    public function __construct(string $message, bool $error)
22
    {
23
        $this->message = $message;
24
        $this->error = $error;
25
    }
26
27
    /**
28
     * @return string
29
     */
30
    public function getMessage(): string
31
    {
32
        return $this->message;
33
    }
34
35
    /**
36
     * @return bool
37
     */
38
    public function isError(): bool
39
    {
40
        return $this->error;
41
    }
42
}
43