Exponential 5.x Kernel 7.5.40 Exponential New Stack (Symfony-based) Kernel — PHP Class Reference

CriterionVisitorDispatcherContentPass.php
Go to the documentation of this file.
1 <?php
2
7 namespace eZ\Publish\Core\Base\Container\Compiler\Search\Elasticsearch;
8
9 use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
10 use Symfony\Component\DependencyInjection\ContainerBuilder;
11 use Symfony\Component\DependencyInjection\Reference;
12
16 class CriterionVisitorDispatcherContentPass implements CompilerPassInterface
17 {
21 public function process(ContainerBuilder $container)
22 {
23 if (!$container->hasDefinition('ezpublish.search.elasticsearch.content.criterion_visitor_dispatcher')) {
24 return;
25 }
26
27 $aggregateCriterionVisitorDefinition = $container->getDefinition(
28 'ezpublish.search.elasticsearch.content.criterion_visitor_dispatcher'
29 );
30
31 foreach ($container->findTaggedServiceIds('ezpublish.search.elasticsearch.content.criterion_visitor') as $id => $attributes) {
32 $aggregateCriterionVisitorDefinition->addMethodCall(
33 'addVisitor',
34 [
35 new Reference($id),
36 ]
37 );
38 }
39 }
40 }
eZ\Publish\Core\Base\Container\Compiler\Search\Elasticsearch\CriterionVisitorDispatcherContentPass
This compiler pass will register Elasticsearch Search Engine criterion visitors for Content Search.
Definition: CriterionVisitorDispatcherContentPass.php:17
eZ\Publish\Core\Base\Container\Compiler\Search\Elasticsearch\CriterionVisitorDispatcherContentPass\process
process(ContainerBuilder $container)
Definition: CriterionVisitorDispatcherContentPass.php:21
eZ\Publish\Core\Base\Container\Compiler\Search\Elasticsearch
Definition: AggregateFacetBuilderVisitorPass.php:7
Copyright © 1998 – 2026 7x. All rights reserved. Licensed under the GNU GPLv2+.