Neos.ContentRepository/Classes/Domain/Model/Workspace.php
protected function verifyPublishingTargetWorkspace(Workspace $targetWorkspace)
    {
        $baseWorkspace = $this;
        while ($baseWorkspace === null || $targetWorkspace->getName() !== $baseWorkspace->getName()) {
            if ($baseWorkspace === null) {
                throw new WorkspaceException(sprintf('The specified workspace "%s" is not a base workspace of "%s".', $targetWorkspace->getName(), $this->getName()), 1289499117);
            }
            $baseWorkspace = $baseWorkspace->getBaseWorkspace();
        }
    }
protected function verifyPublishingTargetWorkspace(Workspace $targetWorkspace)
    {
        $baseWorkspace = $this;
        while ($baseWorkspace === null || $targetWorkspace->getName() !== $baseWorkspace->getName()) {
            if ($baseWorkspace === null) {
                throw new WorkspaceException(sprintf('The specified workspace "%s" is not a base workspace of "%s".', $targetWorkspace->getName(), $this->getName()), 1289499117);
            }
            $baseWorkspace = $baseWorkspace->getBaseWorkspace();
        }
    }
protected function verifyPublishingTargetWorkspace ( Workspace $ targetWorkspace ) { $ baseWorkspace = $ this ; while ( $ baseWorkspace === null || $ targetWorkspace -> getName ( ) !== $ baseWorkspace -> getName ( ) ) { if ( $ baseWorkspace === null ) { throw new WorkspaceException ( sprintf ( 'The specified workspace "%s" is not a base workspace of "%s".' , $ targetWorkspace -> getName ( ) , $ this -> getName ( ) ) , 1289499117 ) ; } $ baseWorkspace = $ baseWorkspace -> getBaseWorkspace ( ) ; } }
Checks if the specified workspace is a base workspace of this workspace
and if not, throws an exception

@param Workspace $targetWorkspace The publishing target workspace
@return void
@throws WorkspaceException if the specified workspace is not a base workspace of this workspace
Checks if the specified workspace is a base workspace of this workspace and if not throws an exception