Volume   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 24
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 7
dl 0
loc 24
rs 10
c 0
b 0
f 0
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getSource() 0 3 1
A getComment() 0 3 1
1
<?php
2
3
namespace TheAentMachine\Service\Volume;
4
5
abstract class Volume implements \JsonSerializable
6
{
7
    /** @var string */
8
    protected $source;
9
    /** @var null|string */
10
    protected $comment;
11
12
    public function __construct(string $source, ?string $comment = null)
13
    {
14
        $this->source = $source;
15
        $this->comment = $comment;
16
    }
17
18
    public function getSource(): string
19
    {
20
        return $this->source;
21
    }
22
23
    public function getComment(): ?string
24
    {
25
        return $this->comment;
26
    }
27
28
    abstract public function getType(): string;
29
}
30