Passed
Push — master ( 54c9d7...129e56 )
by Chema
01:29 queued 13s
created

DocBlockResolvable   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

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

3 Methods

Rating   Name   Duplication   Size   Complexity  
A className() 0 3 1
A __construct() 0 4 1
A resolvableType() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Gacela\Framework\DocBlockResolver;
6
7
final class DocBlockResolvable
8
{
9
    /** @var class-string */
1 ignored issue
show
Documentation Bug introduced by
The doc comment class-string at position 0 could not be parsed: Unknown type name 'class-string' at position 0 in class-string.
Loading history...
10
    private string $className;
11
12
    private string $resolvableType;
13
14
    /**
15
     * @param class-string $className
1 ignored issue
show
Documentation Bug introduced by
The doc comment class-string at position 0 could not be parsed: Unknown type name 'class-string' at position 0 in class-string.
Loading history...
16
     */
17 11
    public function __construct(string $className, string $resolvableType)
18
    {
19 11
        $this->resolvableType = $resolvableType;
20 11
        $this->className = $className;
21
    }
22
23
    /**
24
     * @return class-string
1 ignored issue
show
Documentation Bug introduced by
The doc comment class-string at position 0 could not be parsed: Unknown type name 'class-string' at position 0 in class-string.
Loading history...
25
     */
26 11
    public function className(): string
27
    {
28 11
        return $this->className;
29
    }
30
31 11
    public function resolvableType(): string
32
    {
33 11
        return $this->resolvableType;
34
    }
35
}
36