protected function createRedirectFrom(string $oldUri, string $nodeIdentifer, string $workspaceName, array $dimensionCombination): bool
    {
        $node = $this->getNodeInWorkspaceAndDimensions($nodeIdentifer, $workspaceName, $dimensionCombination);
        if ($node === null) {
            return false;
        }

        if ($this->isRestrictedByNodeType($node) || $this->isRestrictedByPath($node)) {
            return false;
        }

        $newUri = $this->buildUriPathForNode($node);

        if ($node->isRemoved()) {
            return $this->removeNodeRedirectIfNeeded($node, $newUri);
        }

        if ($oldUri === $newUri) {
            return false;
        }

        $hosts = $this->getHostnames($node->getContext());
        $this->flushRoutingCacheForNode($node);
        $statusCode = (integer)$this->defaultStatusCode['redirect'];

        $this->redirectStorage->addRedirect($oldUri, $newUri, $statusCode, $hosts);

        return true;
    }
protected function createRedirectFrom(string $oldUri, string $nodeIdentifer, string $workspaceName, array $dimensionCombination): bool
    {
        $node = $this->getNodeInWorkspaceAndDimensions($nodeIdentifer, $workspaceName, $dimensionCombination);
        if ($node === null) {
            return false;
        }

        if ($this->isRestrictedByNodeType($node) || $this->isRestrictedByPath($node)) {
            return false;
        }

        $newUri = $this->buildUriPathForNode($node);

        if ($node->isRemoved()) {
            return $this->removeNodeRedirectIfNeeded($node, $newUri);
        }

        if ($oldUri === $newUri) {
            return false;
        }

        $hosts = $this->getHostnames($node->getContext());
        $this->flushRoutingCacheForNode($node);
        $statusCode = (integer)$this->defaultStatusCode['redirect'];

        $this->redirectStorage->addRedirect($oldUri, $newUri, $statusCode, $hosts);

        return true;
    }
protected function createRedirectFrom ( string $ oldUri , string $ nodeIdentifer , string $ workspaceName , array $ dimensionCombination ) : bool { $ node = $ this -> getNodeInWorkspaceAndDimensions ( $ nodeIdentifer , $ workspaceName , $ dimensionCombination ) ; if ( $ node === null ) { return false ; } if ( $ this -> isRestrictedByNodeType ( $ node ) || $ this -> isRestrictedByPath ( $ node ) ) { return false ; } $ newUri = $ this -> buildUriPathForNode ( $ node ) ; if ( $ node -> isRemoved ( ) ) { return $ this -> removeNodeRedirectIfNeeded ( $ node , $ newUri ) ; } if ( $ oldUri === $ newUri ) { return false ; } $ hosts = $ this -> getHostnames ( $ node -> getContext ( ) ) ; $ this -> flushRoutingCacheForNode ( $ node ) ; $ statusCode = ( integer ) $ this -> defaultStatusCode [ 'redirect' ] ; $ this -> redirectStorage -> addRedirect ( $ oldUri , $ newUri , $ statusCode , $ hosts ) ; return true ; }
Gets the node in the given dimensions and workspace and redirects the oldUri to the new one.

@param string $oldUri
@param string $nodeIdentifer
@param string $workspaceName
@param array $dimensionCombination
@return bool
@throws \Neos\Flow\Mvc\Routing\Exception\MissingActionNameException
Gets the node in the given dimensions and workspace and redirects the oldUri to the new one .