param example

use Symfony\Component\Validator\Constraints\NoSuspiciousCharactersValidator;
use Symfony\Component\Validator\Constraints\NotCompromisedPasswordValidator;
use Symfony\Component\Validator\Constraints\WhenValidator;
use Symfony\Component\Validator\ContainerConstraintValidatorFactory;
use Symfony\Component\Validator\Mapping\Loader\PropertyInfoLoader;
use Symfony\Component\Validator\Validation;
use Symfony\Component\Validator\Validator\ValidatorInterface;
use Symfony\Component\Validator\ValidatorBuilder;

return static function DContainerConfigurator $container) {
    $container->parameters()
        ->set('validator.mapping.cache.file', param('kernel.cache_dir').'/validation.php');

    $validatorsDir = \dirname((new \ReflectionClass(EmailValidator::class))->getFileName());

    $container->services()
        ->set('validator', ValidatorInterface::class)
            ->factory([service('validator.builder'), 'getValidator'])
        ->alias(ValidatorInterface::class, 'validator')

        ->set('validator.builder', ValidatorBuilder::class)
            ->factory([Validation::class, 'createValidatorBuilder'])
            ->call('setConstraintValidatorFactory', [
                
->set('annotations.filesystem_cache_adapter', FilesystemAdapter::class)
            ->args([
                '',
                0,
                abstract_arg('Cache-Directory'),
            ])
            ->deprecate('symfony/framework-bundle', '6.4', 'The "%service_id%" service is deprecated without replacement.')

        ->set('annotations.cache_warmer', AnnotationsCacheWarmer::class)
            ->args([
                service('annotations.reader'),
                param('kernel.cache_dir').'/annotations.php',
                '#^Symfony\\\\(?:Component\\\\HttpKernel\\\\|Bundle\\\\FrameworkBundle\\\\Controller\\\\(?!.*Controller$))#',
                param('kernel.debug'),
                false,
            ])
            ->deprecate('symfony/framework-bundle', '6.4', 'The "%service_id%" service is deprecated without replacement.')

        ->set('annotations.cache_adapter', PhpArrayAdapter::class)
            ->factory([PhpArrayAdapter::class, 'create'])
            ->args([
                param('kernel.cache_dir').'/annotations.php',
                service('cache.annotations'),
            ])
->parent('cache.app')
            ->private()
            ->tag('cache.pool')

        ->set('cache.adapter.system', AdapterInterface::class)
            ->abstract()
            ->factory([AbstractAdapter::class, 'createSystemCache'])
            ->args([
                '', // namespace                 0, // default lifetime                 abstract_arg('version'),
                sprintf('%s/pools/system', param('kernel.cache_dir')),
                service('logger')->ignoreOnInvalid(),
            ])
            ->tag('cache.pool', ['clearer' => 'cache.system_clearer', 'reset' => 'reset'])
            ->tag('monolog.logger', ['channel' => 'cache'])

        ->set('cache.adapter.apcu', ApcuAdapter::class)
            ->abstract()
            ->args([
                '', // namespace                 0, // default lifetime                 abstract_arg('version'),
            ])
$container->services()
        ->set('session.factory', SessionFactory::class)
            ->args([
                service('request_stack'),
                service('session.storage.factory'),
                [service('session_listener'), 'onSessionUsage'],
            ])

        ->set('session.storage.factory.native', NativeSessionStorageFactory::class)
            ->args([
                param('session.storage.options'),
                service('session.handler'),
                inline_service(MetadataBag::class)
                    ->args([
                        param('session.metadata.storage_key'),
                        param('session.metadata.update_threshold'),
                    ]),
                false,
            ])
        ->set('session.storage.factory.php_bridge', PhpBridgeSessionStorageFactory::class)
            ->args([
                service('session.handler'),
                
use Symfony\Component\HttpKernel\Profiler\Profiler;

return static function DContainerConfigurator $container) {
    $container->services()
        ->set('profiler', Profiler::class)
            ->public()
            ->args([service('profiler.storage')service('logger')->nullOnInvalid()])
            ->tag('monolog.logger', ['channel' => 'profiler'])
            ->tag('container.private', ['package' => 'symfony/framework-bundle', 'version' => '5.4'])

        ->set('profiler.storage', FileProfilerStorage::class)
            ->args([param('profiler.storage.dsn')])

        ->set('profiler_listener', ProfilerListener::class)
            ->args([
                service('profiler'),
                service('request_stack'),
                null,
                param('profiler_listener.only_exceptions'),
                param('profiler_listener.only_main_requests'),
            ])
            ->tag('kernel.event_subscriber')
    ;
};
->set('data_collector.events', EventDataCollector::class)
            ->args([
                tagged_iterator('event_dispatcher.dispatcher', 'name'),
                service('request_stack')->ignoreOnInvalid(),
            ])
            ->tag('data_collector', ['template' => '@WebProfiler/Collector/events.html.twig', 'id' => 'events', 'priority' => 290])

        ->set('data_collector.logger', LoggerDataCollector::class)
            ->args([
                service('logger')->ignoreOnInvalid(),
                sprintf('%s/%s', param('kernel.build_dir')param('kernel.container_class')),
                service('request_stack')->ignoreOnInvalid(),
            ])
            ->tag('monolog.logger', ['channel' => 'profiler'])
            ->tag('data_collector', ['template' => '@WebProfiler/Collector/logger.html.twig', 'id' => 'logger', 'priority' => 300])

        ->set('data_collector.time', TimeDataCollector::class)
            ->args([
                service('kernel')->ignoreOnInvalid(),
                service('debug.stopwatch')->ignoreOnInvalid(),
            ])
            ->tag('data_collector', ['template' => '@WebProfiler/Collector/time.html.twig', 'id' => 'time', 'priority' => 330])

        

            ->tag('monolog.logger', ['channel' => 'security'])

        ->set('security.exception_listener', ExceptionListener::class)
            ->abstract()
            ->args([
                service('security.token_storage'),
                service('security.authentication.trust_resolver'),
                service('security.http_utils'),
                abstract_arg('Provider-shared Key'),
                service('security.authentication.entry_point')->nullOnInvalid(),
                param('security.access.denied_url'),
                service('security.access.denied_handler')->nullOnInvalid(),
                service('logger')->nullOnInvalid(),
                false, // Stateless             ])
            ->tag('monolog.logger', ['channel' => 'security'])

        ->set('security.authentication.switchuser_listener', SwitchUserListener::class)
            ->abstract()
            ->args([
                service('security.token_storage'),
                abstract_arg('User Provider'),
                
return static function DContainerConfigurator $container) {
    $container->parameters()
        ->set('fragment.renderer.hinclude.global_template', null)
        ->set('fragment.path', '/_fragment')
    ;

    $container->services()
        ->set('fragment.handler', LazyLoadingFragmentHandler::class)
            ->args([
                abstract_arg('fragment renderer locator'),
                service('request_stack'),
                param('kernel.debug'),
            ])

        ->set('fragment.uri_generator', FragmentUriGenerator::class)
            ->args([param('fragment.path')service('uri_signer')service('request_stack')])
        ->alias(FragmentUriGeneratorInterface::class, 'fragment.uri_generator')

        ->set('fragment.renderer.inline', InlineFragmentRenderer::class)
            ->args([service('http_kernel')service('event_dispatcher')])
            ->call('setFragmentPath', [param('fragment.path')])
            ->tag('kernel.fragment_renderer', ['alias' => 'inline'])

        


namespace Symfony\Component\DependencyInjection\Loader\Configurator;

use Symfony\Component\HttpKernel\EventListener\FragmentListener;

return static function DContainerConfigurator $container) {
    $container->services()
        ->set('fragment.listener', FragmentListener::class)
            ->args([service('uri_signer')param('fragment.path')])
            ->tag('kernel.event_subscriber')
    ;
};
->set('http_cache', HttpCache::class)
            ->args([
                service('kernel'),
                service('http_cache.store'),
                service('esi')->nullOnInvalid(),
                abstract_arg('options'),
            ])
            ->tag('container.hot_path')

        ->set('http_cache.store', Store::class)
            ->args([
                param('kernel.cache_dir').'/http_cache',
            ])
        ->alias(StoreInterface::class, 'http_cache.store')

        ->set('url_helper', UrlHelper::class)
            ->args([
                service('request_stack'),
                service('router')->ignoreOnInvalid(),
            ])
        ->alias(UrlHelper::class, 'url_helper')

        ->set('cache_warmer', CacheWarmerAggregate::class)
            
use Symfony\Component\ErrorHandler\ErrorRenderer\HtmlErrorRenderer;

return static function DContainerConfigurator $container) {
    $container->services()
        ->set('error_handler.error_renderer.html', HtmlErrorRenderer::class)
            ->args([
                inline_service()
                    ->factory([HtmlErrorRenderer::class, 'isDebug'])
                    ->args([
                        service('request_stack'),
                        param('kernel.debug'),
                    ]),
                param('kernel.charset'),
                service('debug.file_link_formatter')->nullOnInvalid(),
                param('kernel.project_dir'),
                inline_service()
                    ->factory([HtmlErrorRenderer::class, 'getAndCleanOutputBuffer'])
                    ->args([service('request_stack')]),
                service('logger')->nullOnInvalid(),
            ])

        ->alias('error_renderer.html', 'error_handler.error_renderer.html')
        
tagged_iterator('translation.provider_factory'),
                [], // Enabled locales             ])

        ->set('translation.provider_factory.null', NullProviderFactory::class)
            ->tag('translation.provider_factory')

        ->set('translation.provider_factory.crowdin', CrowdinProviderFactory::class)
            ->args([
                service('http_client'),
                service('logger'),
                param('kernel.default_locale'),
                service('translation.loader.xliff'),
                service('translation.dumper.xliff'),
            ])
            ->tag('translation.provider_factory')

        ->set('translation.provider_factory.loco', LocoProviderFactory::class)
            ->args([
                service('http_client'),
                service('logger'),
                param('kernel.default_locale'),
                service('translation.loader.xliff'),
                
use Symfony\Component\Translation\Writer\TranslationWriter;
use Symfony\Component\Translation\Writer\TranslationWriterInterface;
use Symfony\Contracts\Translation\LocaleAwareInterface;
use Symfony\Contracts\Translation\TranslatorInterface;

return static function DContainerConfigurator $container) {
    $container->services()
        ->set('translator.default', Translator::class)
            ->args([
                abstract_arg('translation loaders locator'),
                service('translator.formatter'),
                param('kernel.default_locale'),
                abstract_arg('translation loaders ids'),
                [
                    'cache_dir' => param('kernel.cache_dir').'/translations',
                    'debug' => param('kernel.debug'),
                ],
                abstract_arg('enabled locales'),
            ])
            ->call('setConfigCacheFactory', [service('config_cache_factory')])
            ->tag('kernel.locale_aware')

        ->alias(TranslatorInterface::class, 'translator')

        


namespace Symfony\Component\DependencyInjection\Loader\Configurator;

use Symfony\Component\Form\Extension\Csrf\Type\FormTypeCsrfExtension;

return static function DContainerConfigurator $container) {
    $container->services()
        ->set('form.type_extension.csrf', FormTypeCsrfExtension::class)
            ->args([
                service('security.csrf.token_manager'),
                param('form.type_extension.csrf.enabled'),
                param('form.type_extension.csrf.field_name'),
                service('translator')->nullOnInvalid(),
                param('validator.translation_domain'),
                service('form.server_params'),
            ])
            ->tag('form.type_extension')
    ;
};
->args([
                service('var_dumper.cloner'),
                service('var_dumper.html_dumper'),
            ])
            ->tag('twig.extension')

        ->set('data_collector.dump', DumpDataCollector::class)
            ->public()
            ->args([
                service('debug.stopwatch')->ignoreOnInvalid(),
                service('debug.file_link_formatter')->ignoreOnInvalid(),
                param('kernel.charset'),
                service('request_stack'),
                null, // var_dumper.cli_dumper or var_dumper.server_connection when debug.dump_destination is set             ])
            ->tag('data_collector', [
                'id' => 'dump',
                'template' => '@Debug/Profiler/dump.html.twig',
                'priority' => 240,
            ])

        ->set('debug.dump_listener', DumpListener::class)
            ->args([
                
Home | Imprint | This part of the site doesn't use cookies.