Files
kupshop/bundles/KupShop/CatalogElasticBundle/Contracts/ElasticSectionEventDispatcher.php
2025-08-02 16:30:27 +02:00

32 lines
942 B
PHP

<?php
declare(strict_types=1);
namespace KupShop\CatalogElasticBundle\Contracts;
use Elastica\Multi\Search as MultiSearch;
use KupShop\CatalogElasticBundle\Dto\PreparedSectionQueryInnerState;
use KupShop\CatalogElasticBundle\SectionRequest;
interface ElasticSectionEventDispatcher
{
public const EVENT_BEFORE_COMPILE = 'before-compile';
public const EVENT_BEFORE_EXECUTE = 'before-execute';
public const EVENT_AFTER_EXECUTE = 'after-execute';
/**
* @param callable(SectionRequest, PreparedSectionQueryInnerState): void $listener
*/
public function onBeforeCompile(callable $listener): void;
/**
* @param callable(MultiSearch, PreparedSectionQueryInnerState): void $listener
*/
public function onBeforeExecute(callable $listener): void;
/**
* @param callable(PreparedSectionQueryInnerState): void $listener
*/
public function onAfterExecute(callable $listener): void;
}