Passed
Push — master ( 74d4a8...9f17d2 )
by
unknown
01:31
created

NullLoggerBuilder   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%

Importance

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

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getLogger() 0 4 1
A getMainCLassName() 0 4 1
A getPackageName() 0 4 1
1
<?php
2
3
namespace vfalies\tmdb\Factory\Builder;
4
5
use vfalies\tmdb\Interfaces\Factory\LoggerBuilderInterface;
6
7
class NullLoggerBuilder implements LoggerBuilderInterface
8
{
9
10
    /**
11
     * This method MUST return a valid PSR3 logger
12
     * @return \Psr\Log\NullLogger
13
     */
14 2
    public function getLogger(): \Psr\Log\LoggerInterface
15
    {
16 2
        return new \Psr\Log\NullLogger;
17
    }
18
19
    /**
20
     * This method MUST return the name of the main class
21
     * @return string
22
     */
23 1
    public function getMainCLassName(): string
24
    {
25 1
        return '\Psr\Log\NullLogger';
26
    }
27
28
    /**
29
     * This method MUST return the name of the package name
30
     * @return string
31
     */
32 1
    public function getPackageName(): string
33
    {
34 1
        return 'psr/log';
35
    }
36
}
37