11
11
/**
12
12
* @author Fabien Potencier <fabien@symfony.com>
13
13
*/
14
- class Kernel extends BaseKernel
14
+ final class Kernel extends BaseKernel
15
15
{
16
16
use MicroKernelTrait;
17
17
18
- const CONFIG_EXTS = '.{php,xml,yaml,yml} ' ;
18
+ private const CONFIG_EXTS = '.{php,xml,yaml,yml} ' ;
19
19
20
- public function getCacheDir ()
20
+ public function getCacheDir (): string
21
21
{
22
22
return dirname (__DIR__ ).'/var/cache/ ' .$ this ->environment ;
23
23
}
24
24
25
- public function getLogDir ()
25
+ public function getLogDir (): string
26
26
{
27
27
return dirname (__DIR__ ).'/var/logs ' ;
28
28
}
29
29
30
- public function registerBundles ()
30
+ public function registerBundles (): iterable
31
31
{
32
32
$ contents = require dirname (__DIR__ ).'/etc/bundles.php ' ;
33
33
foreach ($ contents as $ class => $ envs ) {
@@ -37,7 +37,7 @@ public function registerBundles()
37
37
}
38
38
}
39
39
40
- protected function configureContainer (ContainerBuilder $ container , LoaderInterface $ loader )
40
+ protected function configureContainer (ContainerBuilder $ container , LoaderInterface $ loader ): void
41
41
{
42
42
$ confDir = dirname (__DIR__ ).'/etc ' ;
43
43
$ loader ->import ($ confDir .'/packages/* ' .self ::CONFIG_EXTS , 'glob ' );
@@ -47,7 +47,7 @@ protected function configureContainer(ContainerBuilder $container, LoaderInterfa
47
47
$ loader ->import ($ confDir .'/container ' .self ::CONFIG_EXTS , 'glob ' );
48
48
}
49
49
50
- protected function configureRoutes (RouteCollectionBuilder $ routes )
50
+ protected function configureRoutes (RouteCollectionBuilder $ routes ): void
51
51
{
52
52
$ confDir = dirname (__DIR__ ).'/etc ' ;
53
53
if (is_dir ($ confDir .'/routing/ ' )) {
0 commit comments