Information   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 11
dl 0
loc 21
ccs 9
cts 9
cp 1
rs 10
c 1
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getAsArray() 0 6 1
A __construct() 0 5 1
1
<?php declare(strict_types=1);
2
3
namespace ekinhbayar\GitAmp\Presentation;
4
5
class Information
6
{
7
    private string $url;
8
9
    private string $payload;
10
11
    private string $message;
12
13 23
    public function __construct(string $url, string $payload, string $message)
14
    {
15 23
        $this->url     = $url;
16 23
        $this->payload = $payload;
17 23
        $this->message = \ucfirst($message);
18 23
    }
19
20 21
    public function getAsArray(): array
21
    {
22
        return [
23 21
            'url'     => $this->url,
24 21
            'payload' => $this->payload,
25 21
            'message' => $this->message,
26
        ];
27
    }
28
}
29