11
11
12
12
namespace Symfony \Bundle \FrameworkBundle \Routing ;
13
13
14
+ use Psr \Log \LoggerInterface ;
14
15
use Symfony \Component \Config \Loader \LoaderInterface ;
15
16
use Symfony \Component \DependencyInjection \Config \ContainerParametersResource ;
16
17
use Symfony \Component \DependencyInjection \ServiceSubscriberInterface ;
@@ -33,17 +34,19 @@ class Router extends BaseRouter implements WarmableInterface, ServiceSubscriberI
33
34
private $ collectedParameters = array ();
34
35
35
36
/**
36
- * @param ContainerInterface $container A ContainerInterface instance
37
- * @param mixed $resource The main resource to load
38
- * @param array $options An array of options
39
- * @param RequestContext $context The context
37
+ * @param ContainerInterface $container A ContainerInterface instance
38
+ * @param mixed $resource The main resource to load
39
+ * @param array $options An array of options
40
+ * @param RequestContext $context The context
41
+ * @param LoggerInterface|null $logger
40
42
*/
41
- public function __construct (ContainerInterface $ container , $ resource , array $ options = array (), RequestContext $ context = null )
43
+ public function __construct (ContainerInterface $ container , $ resource , array $ options = array (), RequestContext $ context = null , LoggerInterface $ logger = null )
42
44
{
43
45
$ this ->container = $ container ;
44
46
45
47
$ this ->resource = $ resource ;
46
48
$ this ->context = $ context ?: new RequestContext ();
49
+ $ this ->logger = $ logger ;
47
50
$ this ->setOptions ($ options );
48
51
}
49
52
0 commit comments