Note that this is called during the request therefore the task of this
interfaces method should normally be to record references to the structures
which should later be invalidated in the flush interface.
/** * @param ContentNodeDeleteEvent */ public function onContentNodePostDelete(ContentNodeDeleteEvent $event) { foreach ($this->structureInvalidationStack as $structure) { $this->handler->invalidateStructure($structure); } }
/** * Invalidates the structure of the given document. * * @param $document */ private function invalidateDocumentStructure($document) { $structureBridge = $this->structureManager->wrapStructure($this->documentInspector->getMetadata($document)->getAlias(), $this->documentInspector->getStructureMetadata($document)); $structureBridge->setDocument($document); $this->structureHandler->invalidateStructure($structureBridge); }