PHP Class Sulu\Component\Content\Document\Subscriber\Compat\ContentMapperSubscriber

Deprecation: Here only for BC reasons
Inheritance: implements Symfony\Component\EventDispatcher\EventSubscriberInterface
Datei anzeigen Open project: sulu/sulu

Public Methods

Method Description
__construct ( DocumentInspector $inspector, Symfony\Component\EventDispatcher\EventDispatcherInterface $dispatcher, Sulu\Component\Content\Mapper\ContentMapperInterface $mapper, SuluNodeHelper $nodeHelper, Sulu\Component\Content\Compat\StructureManagerInterface $structureManager )
getSubscribedEvents ( )
handleFlush ( Sulu\Component\DocumentManager\Event\FlushEvent $event ) Dispatches the deprecated post save event for every persisted document.
handlePersist ( Sulu\Component\DocumentManager\Event\PersistEvent $event ) Saves all persisted documents to dispatch the deprecated post save event later when flushed.
handlePostRemove ( Sulu\Component\DocumentManager\Event\RemoveEvent $event ) Dispatches the deprected post remove event.
handlePreRemove ( Sulu\Component\DocumentManager\Event\RemoveEvent $event ) Dispatches the deprecated pre remove event.

Private Methods

Method Description
documentToStructure ( Sulu\Component\Content\Document\Behavior\StructureBehavior $document ) : StructureBridge Return a structure bridge corresponding to the given document.
getDeleteEvent ( $document )
supports ( $document )

Method Details

__construct() public method

public __construct ( DocumentInspector $inspector, Symfony\Component\EventDispatcher\EventDispatcherInterface $dispatcher, Sulu\Component\Content\Mapper\ContentMapperInterface $mapper, SuluNodeHelper $nodeHelper, Sulu\Component\Content\Compat\StructureManagerInterface $structureManager )
$inspector Sulu\Bundle\DocumentManagerBundle\Bridge\DocumentInspector
$dispatcher Symfony\Component\EventDispatcher\EventDispatcherInterface
$mapper Sulu\Component\Content\Mapper\ContentMapperInterface
$nodeHelper Sulu\Component\Util\SuluNodeHelper
$structureManager Sulu\Component\Content\Compat\StructureManagerInterface

getSubscribedEvents() public static method

public static getSubscribedEvents ( )

handleFlush() public method

Dispatches the deprecated post save event for every persisted document.
public handleFlush ( Sulu\Component\DocumentManager\Event\FlushEvent $event )
$event Sulu\Component\DocumentManager\Event\FlushEvent

handlePersist() public method

Saves all persisted documents to dispatch the deprecated post save event later when flushed.
public handlePersist ( Sulu\Component\DocumentManager\Event\PersistEvent $event )
$event Sulu\Component\DocumentManager\Event\PersistEvent

handlePostRemove() public method

Dispatches the deprected post remove event.
public handlePostRemove ( Sulu\Component\DocumentManager\Event\RemoveEvent $event )
$event Sulu\Component\DocumentManager\Event\RemoveEvent

handlePreRemove() public method

Dispatches the deprecated pre remove event.
public handlePreRemove ( Sulu\Component\DocumentManager\Event\RemoveEvent $event )
$event Sulu\Component\DocumentManager\Event\RemoveEvent