private SVNURL getCommonCopyAncestor(Collection<SvnCopyPair> copyPairs) { SVNURL ancestor = null; for (SvnCopyPair svnCopyPair : copyPairs) { if (ancestor == null) { ancestor = svnCopyPair.source; continue; } ancestor = SVNURLUtil.getCommonURLAncestor(ancestor, svnCopyPair.source); } return ancestor; }
rootURL = getCommonURLAncestor(rootURL, urls[i]); continue; SVNURL common = getCommonURLAncestor(url1, url2); if (common == null) { continue;
rootURL = getCommonURLAncestor(rootURL, urls[i]); continue; SVNURL common = getCommonURLAncestor(url1, url2); if (common == null) { continue;
rootURL = getCommonURLAncestor(rootURL, urls[i]); continue; SVNURL common = getCommonURLAncestor(url1, url2); if (common == null) { continue;
rootURL = getCommonURLAncestor(rootURL, urls[i]); continue; SVNURL common = getCommonURLAncestor(url1, url2); if (common == null) { continue;
public void linkPath(SVNURL url, String path, String lockToken, long revision, SVNDepth depth, boolean startEmpty) throws SVNException { SVNURL rootURL = SVNURLUtil.getCommonURLAncestor(url, myRepositoryLocation); if (SVNPathUtil.getPathAsChild(rootURL.getPath(), myRepositoryLocation.getPath()) != null) { myRepositoryLocation = rootURL; } myReporter.linkPath(url, path, lockToken, revision, depth, startEmpty); }
public void linkPath(SVNURL url, String path, String lockToken, long revision, SVNDepth depth, boolean startEmpty) throws SVNException { SVNURL ancestor = SVNURLUtil.getCommonURLAncestor(url, repositoryLocation); /* If we got a shorter ancestor, truncate our current ancestor. Note that svn_dirent_get_longest_ancestor will allocate its return value even if it identical to one of its arguments. */ if (SVNPathUtil.getPathAsChild(ancestor.getPath(), repositoryLocation.getPath()) != null) { repositoryLocation = ancestor; // TODO set depth infinity to reportBaton: // This depth is only used to report locks in finishReport() method // Currently SVNRepository#getLocks doesn't support depth, so the assignment is useless // But when it will, the depth should be kept and passed to SVNRepository#getLocks // rb->depth = svn_depth_infinity; } reporter.linkPath(url, path, lockToken, revision, depth, startEmpty); }
while (urls.hasNext()) { SVNURL url = (SVNURL) urls.next(); baseURL = SVNURLUtil.getCommonURLAncestor(baseURL, url);
while (urls.hasNext()) { SVNURL url = (SVNURL) urls.next(); baseURL = SVNURLUtil.getCommonURLAncestor(baseURL, url);
while (urls.hasNext()) { SVNURL url = (SVNURL) urls.next(); baseURL = SVNURLUtil.getCommonURLAncestor(baseURL, url);
while (urls.hasNext()) { SVNURL url = (SVNURL) urls.next(); baseURL = SVNURLUtil.getCommonURLAncestor(baseURL, url);
public void linkPath(SVNURL url, String path, String lockToken, long revision, SVNDepth depth, boolean startEmpty) throws SVNException { SVNURL rootURL = SVNURLUtil.getCommonURLAncestor(url, myCommonAncestorLocation); if (rootURL == null) { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.BAD_URL, "Can not determine common ancestor of ''{0}'' and ''{1}'';\nprobably these entries belong to different repositories.", new Object[] {url, myCommonAncestorLocation}); SVNErrorManager.error(err, SVNLogType.WC); } if (SVNPathUtil.getPathAsChild(rootURL.getPath(), myCommonAncestorLocation.getPath()) != null) { myCommonAncestorLocation = rootURL; } myReporter.linkPath(url, path, lockToken, revision, depth, startEmpty); }
public void linkPath(SVNURL url, String path, String lockToken, long revision, SVNDepth depth, boolean startEmpty) throws SVNException { SVNURL rootURL = SVNURLUtil.getCommonURLAncestor(url, myRepositoryLocation); if (rootURL == null) { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.BAD_URL, "Can not determine common ancestor of ''{0}'' and ''{1}'';\nprobably these entries belong to different repositories.", new Object[] {url, myRepositoryLocation}); SVNErrorManager.error(err, SVNLogType.WC); } if (SVNPathUtil.getPathAsChild(rootURL.getPath(), myRepositoryLocation.getPath()) != null) { myRepositoryLocation = rootURL; } myReporter.linkPath(url, path, lockToken, revision, depth, startEmpty); }
for(int i = 1; i < paths.size(); i++) { String url = (String) paths.get(i); topURL = SVNURLUtil.getCommonURLAncestor(topURL, SVNURL.parseURIEncoded(url));
for(int i = 1; i < paths.size(); i++) { String url = (String) paths.get(i); topURL = SVNURLUtil.getCommonURLAncestor(topURL, SVNURL.parseURIEncoded(url));
rootUrl = svnurl; } else { rootUrl = SVNURLUtil.getCommonURLAncestor(rootUrl, svnurl);
String sourceReposRelPath = SVNURLUtil.getCommonURLAncestor(wcReposRoot, url2).toString(); sourceReposRelPath = url2.toString().substring(sourceReposRelPath.length()); if (sourceReposRelPath.startsWith("/")) {
SVNURL topURL = SVNURLUtil.getCommonURLAncestor(srcURL, dstURL); if (topURL == null) { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.UNSUPPORTED_FEATURE, "Source and dest appear not to be in the same repository (src: ''{0}''; dst: ''{1}'')", new Object[] {srcURL, dstURL});
SVNURL topDstUrl = firstPair.dst.removePathTail(); for (SvnCopyPair pair : copyPairs) { topDstUrl = SVNURLUtil.getCommonURLAncestor(topDstUrl, pair.dst);