PHP Class Sulu\Bundle\MediaBundle\Search\Subscriber\StructureMediaSearchSubscriber

Inheritance: implements Symfony\Component\EventDispatcher\EventSubscriberInterface
Afficher le fichier Open project: sulu/sulu

Protected Properties

Свойство Type Description
$mediaManager Sulu\Bundle\MediaBundle\Media\Manager\MediaManagerInterface
$requestAnalyzer Sulu\Component\Webspace\Analyzer\RequestAnalyzerInterface
$searchImageFormat string The format of the image, which will be returned in the search.

Méthodes publiques

Méthode Description
__construct ( Sulu\Bundle\MediaBundle\Media\Manager\MediaManagerInterface $mediaManager, Sulu\Component\Webspace\Analyzer\RequestAnalyzerInterface $requestAnalyzer = null, $searchImageFormat )
getSubscribedEvents ( ) : array Returns the events this subscriber has subscribed.
handlePreIndex ( Massive\Bundle\SearchBundle\Search\Event\PreIndexEvent $e ) Adds the image to the search document.

Private Methods

Méthode Description
getImageUrl ( $data, $locale ) Returns the url for the image.

Method Details

__construct() public méthode

public __construct ( Sulu\Bundle\MediaBundle\Media\Manager\MediaManagerInterface $mediaManager, Sulu\Component\Webspace\Analyzer\RequestAnalyzerInterface $requestAnalyzer = null, $searchImageFormat )
$mediaManager Sulu\Bundle\MediaBundle\Media\Manager\MediaManagerInterface
$requestAnalyzer Sulu\Component\Webspace\Analyzer\RequestAnalyzerInterface
$searchImageFormat

getSubscribedEvents() public static méthode

Returns the events this subscriber has subscribed.
public static getSubscribedEvents ( ) : array
Résultat array

handlePreIndex() public méthode

Adds the image to the search document.
public handlePreIndex ( Massive\Bundle\SearchBundle\Search\Event\PreIndexEvent $e )
$e Massive\Bundle\SearchBundle\Search\Event\PreIndexEvent

Property Details

$mediaManager protected_oe property

protected MediaManagerInterface,Sulu\Bundle\MediaBundle\Media\Manager $mediaManager
Résultat Sulu\Bundle\MediaBundle\Media\Manager\MediaManagerInterface

$requestAnalyzer protected_oe property

protected RequestAnalyzerInterface,Sulu\Component\Webspace\Analyzer $requestAnalyzer
Résultat Sulu\Component\Webspace\Analyzer\RequestAnalyzerInterface

$searchImageFormat protected_oe property

The format of the image, which will be returned in the search.
protected string $searchImageFormat
Résultat string