本文整理汇总了PHP中Symfony\Component\HttpKernel\Bundle\Bundle::build方法的典型用法代码示例。如果您正苦于以下问题:PHP Bundle::build方法的具体用法?PHP Bundle::build怎么用?PHP Bundle::build使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Symfony\Component\HttpKernel\Bundle\Bundle
的用法示例。
在下文中一共展示了Bundle::build方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: build
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new ThemeCompilerPass());
$container->addCompilerPass(new TemplateResourcesPass());
$container->addCompilerPass(new AsseticTwigFormulaPass());
}
示例2: build
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new LoadersCompilerPass());
// Disable create cache directories for now; it's not needed anyway (structure is being created on the run).
// ->addCompilerPass(new CreateCacheDirectoriesCompilerPass(), PassConfig::TYPE_AFTER_REMOVING);
}
示例3: build
/**
* @param ContainerBuilder $container
*/
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new ThemeRepositoryPass());
$container->addCompilerPass(new ThemeAwareSourcesPass());
$container->addCompilerPass(new ThemeAwareLoaderDecoratorPass());
}
示例4: build
public function build(ContainerBuilder $container)
{
parent::build($container);
$passConfig = $container->getCompilerPassConfig();
$passConfig->addPass(new AddAfterInvocationProvidersPass());
$passConfig->addPass(new SecureMethodInvocationsPass($container->getParameter('kernel.cache_dir')), PassConfig::TYPE_BEFORE_REMOVING);
}
示例5: build
/**
* Builds the bundle.
*
* It is only ever called once when the cache is empty.
*
* This method can be overridden to register compilation passes,
* other extensions, ...
*
* @param ContainerBuilder $container A ContainerBuilder instance
*/
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new ThemeCompilerPass());
$container->addCompilerPass(new TemplateResourcesPass());
$container->addCompilerPass(new AddResolversPass());
}
示例6: build
/**
* @inheritdoc
*/
public function build(ContainerBuilder $container)
{
parent::build($container);
// add module pass
$container->addCompilerPass(new ModuleCompilerPass());
$container->addCompilerPass(new ComponentCompilerPass());
}
示例7: build
/**
* {@inheritdoc}
*/
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new AutocompleteCompilerPass());
$container->addCompilerPass(new FormCompilerPass());
$container->addCompilerPass(new FormGuesserCompilerPass());
}
示例8: build
public function build(ContainerBuilder $container)
{
parent::build($container);
$extension = $container->getExtension('security');
$factory = new Factory();
$extension->addSecurityListenerFactory($factory);
}
示例9: build
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new Compiler\AutoRegisterServicesPass());
$container->addCompilerPass(new Compiler\MappingCompilerPass());
$container->addCompilerPass(new Compiler\ConfigureDynamicRoutingPass());
}
示例10: build
public function build(ContainerBuilder $container)
{
parent::build($container);
/** @var $extension DependencyInjection\TestExtension */
$extension = $container->getExtension('test');
$extension->setCustomConfig(new CustomConfig());
}
示例11: build
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new TemplatingPass());
$container->addCompilerPass(new AssetManagerPass());
$container->addCompilerPass(new FilterManagerPass());
}
示例12: build
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new ServicePass());
$container->addCompilerPass(new AdapterPass());
$this->buildPhpcrCompilerPass($container);
}
示例13: build
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new TwigEnvironmentPass());
$container->addCompilerPass(new TwigLoaderPass());
$container->addCompilerPass(new ExceptionListenerPass());
}
示例14: build
public function build(ContainerBuilder $container)
{
parent::build($container);
$container->addCompilerPass(new Compiler\AutoRegisterServicesPass());
$container->addCompilerPass(new Compiler\MappingCompilerPass());
$container->addCompilerPass(new Compiler\LayoutBoxConfiguratorPass());
}
示例15: build
/**
* {@inheritDoc}
*/
public function build(ContainerBuilder $container)
{
parent::build($container);
/** @var $extension \Payum\Bundle\PayumBundle\DependencyInjection\PayumExtension */
$extension = $container->getExtension('payum');
$extension->addGatewayFactory(new RedsysGatewayFactory());
}