-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathDataSourceBundle.php
37 lines (30 loc) · 1.03 KB
/
DataSourceBundle.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?php
/**
* (c) FSi Sp. z o.o. <[email protected]>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);
namespace FSi\Bundle\DataSourceBundle;
use Symfony\Component\HttpKernel\Bundle\Bundle;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use FSi\Bundle\DataSourceBundle\DependencyInjection\Compiler\DataSourcePass;
use FSi\Bundle\DataSourceBundle\DependencyInjection\Compiler\TemplatePathPass;
use FSi\Bundle\DataSourceBundle\DependencyInjection\FSIDataSourceExtension;
class DataSourceBundle extends Bundle
{
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new DataSourcePass());
$container->addCompilerPass(new TemplatePathPass());
}
public function getContainerExtension()
{
if (null === $this->extension) {
$this->extension = new FSIDataSourceExtension();
}
return $this->extension;
}
}