RouterModule   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 6
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A configure() 0 4 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace BEAR\Sunday\Provide\Router;
6
7
use BEAR\Sunday\Annotation\DefaultSchemeHost;
8
use BEAR\Sunday\Extension\Router\RouterInterface;
9
use Ray\Di\AbstractModule;
10
11
/**
12
 * Provides RouterInterface and derived bindings
13
 *
14
 * The following bindings are provided:
15
 *
16 2
 *  RouterInterface
17
 *  -DefaultSchemeHost
18 2
 */
19 2
class RouterModule extends AbstractModule
20 2
{
21
    protected function configure(): void
22
    {
23
        $this->bind(RouterInterface::class)->to(WebRouter::class);
24
        $this->bind()->annotatedWith(DefaultSchemeHost::class)->toInstance('page://self');
25
    }
26
}
27