CompanyRegistrationNumber   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 3
eloc 3
c 1
b 0
f 0
dl 0
loc 17
ccs 6
cts 6
cp 1
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A init() 0 3 1
A __construct() 0 3 1
A getCompanyNumber() 0 3 1
1
<?php
2
3
namespace Riesenia\Pohoda\Common;
4
5
final class CompanyRegistrationNumber implements CompanyRegistrationNumberInterface
6
{
7 18
    public static function init(string $companyRegistrationNumber): self
8
    {
9 18
        return new self($companyRegistrationNumber);
10
    }
11
12 18
    public function __construct(
13
        protected readonly string $companyNumber,
14 18
    ) {}
15
16
    /**
17
     * {@inheritDoc}
18
     */
19 8
    public function getCompanyNumber(): string
20
    {
21 8
        return $this->companyNumber;
22
    }
23
}
24