Neos\ContentRepository\Domain\Repository\NodeDataRepository::flushNodeRegistry PHP Метод

flushNodeRegistry() публичный Метод

This method is (and should only be) used as a slot to the allObjectsPersisted signal.
public flushNodeRegistry ( ) : void
Результат void
    public function flushNodeRegistry()
    {
        $this->highestIndexCache = [];
        $this->addedNodes = new \SplObjectStorage();
        $this->removedNodes = new \SplObjectStorage();
    }

Usage Example

 protected function saveNodesAndTearDownRootNodeAndRepository()
 {
     if ($this->nodeDataRepository !== null) {
         $this->nodeDataRepository->flushNodeRegistry();
     }
     /** @var NodeFactory $nodeFactory */
     $nodeFactory = $this->objectManager->get(NodeFactory::class);
     $nodeFactory->reset();
     $this->contextFactory->reset();
     $this->persistenceManager->persistAll();
     $this->persistenceManager->clearState();
     $this->nodeDataRepository = null;
     $this->rootNode = null;
 }