CreatePastePayload   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 40
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 3
c 0
b 0
f 0
lcom 0
cbo 0
dl 0
loc 40
ccs 8
cts 8
cp 1
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getPaste() 0 4 1
A getEncryptionKey() 0 4 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Nastoletni\Code\Application\Service;
6
7
use Nastoletni\Code\Domain\Paste;
8
9
class CreatePastePayload
10
{
11
    /**
12
     * @var Paste
13
     */
14
    private $paste;
15
16
    /**
17
     * @var string
18
     */
19
    private $encryptionKey;
20
21
    /**
22
     * CreatePastePayload constructor.
23
     *
24
     * @param Paste  $paste
25
     * @param string $encryptionKey
26
     */
27 4
    public function __construct(Paste $paste, string $encryptionKey)
28
    {
29 4
        $this->paste = $paste;
30 4
        $this->encryptionKey = $encryptionKey;
31 4
    }
32
33
    /**
34
     * @return Paste
35
     */
36 1
    public function getPaste(): Paste
37
    {
38 1
        return $this->paste;
39
    }
40
41
    /**
42
     * @return string
43
     */
44 1
    public function getEncryptionKey(): string
45
    {
46 1
        return $this->encryptionKey;
47
    }
48
}
49