public SVNLocationEntry getPreviousLocation(String path, long[] appearedRevision) throws SVNException { if (appearedRevision != null && appearedRevision.length > 0) { appearedRevision[0] = SVNRepository.INVALID_REVISION; } FSClosestCopy closestCopy = getClosestCopy(path); if (closestCopy == null) { return null; } FSRevisionRoot copyTargetRoot = closestCopy.getRevisionRoot(); String copyTargetPath = closestCopy.getPath(); FSRevisionNode copyFromNode = copyTargetRoot.getRevisionNode(copyTargetPath); String copyFromPath = copyFromNode.getCopyFromPath(); long copyFromRevision = copyFromNode.getCopyFromRevision(); String remainder = ""; if (!path.equals(copyTargetPath)) { remainder = path.substring(copyTargetPath.length()); if (remainder.startsWith("/")) { remainder = remainder.substring(1); } } String previousPath = SVNPathUtil.getAbsolutePath(SVNPathUtil.append(copyFromPath, remainder)); if (appearedRevision != null && appearedRevision.length > 0) { appearedRevision[0] = copyTargetRoot.getRevision(); } return new SVNLocationEntry(copyFromRevision, previousPath); }
public SVNLocationEntry getPreviousLocation(String path, long[] appearedRevision) throws SVNException { if (appearedRevision != null && appearedRevision.length > 0) { appearedRevision[0] = SVNRepository.INVALID_REVISION; } FSClosestCopy closestCopy = getClosestCopy(path); if (closestCopy == null) { return null; } FSRevisionRoot copyTargetRoot = closestCopy.getRevisionRoot(); String copyTargetPath = closestCopy.getPath(); FSRevisionNode copyFromNode = copyTargetRoot.getRevisionNode(copyTargetPath); String copyFromPath = copyFromNode.getCopyFromPath(); long copyFromRevision = copyFromNode.getCopyFromRevision(); String remainder = ""; if (!path.equals(copyTargetPath)) { remainder = path.substring(copyTargetPath.length()); if (remainder.startsWith("/")) { remainder = remainder.substring(1); } } String previousPath = SVNPathUtil.getAbsolutePath(SVNPathUtil.append(copyFromPath, remainder)); if (appearedRevision != null && appearedRevision.length > 0) { appearedRevision[0] = copyTargetRoot.getRevision(); } return new SVNLocationEntry(copyFromRevision, previousPath); }
public SVNLocationEntry getPreviousLocation(String path, long[] appearedRevision) throws SVNException { if (appearedRevision != null && appearedRevision.length > 0) { appearedRevision[0] = SVNRepository.INVALID_REVISION; } FSClosestCopy closestCopy = getClosestCopy(path); if (closestCopy == null) { return null; } FSRevisionRoot copyTargetRoot = closestCopy.getRevisionRoot(); String copyTargetPath = closestCopy.getPath(); FSRevisionNode copyFromNode = copyTargetRoot.getRevisionNode(copyTargetPath); String copyFromPath = copyFromNode.getCopyFromPath(); long copyFromRevision = copyFromNode.getCopyFromRevision(); String remainder = ""; if (!path.equals(copyTargetPath)) { remainder = path.substring(copyTargetPath.length()); if (remainder.startsWith("/")) { remainder = remainder.substring(1); } } String previousPath = SVNPathUtil.getAbsolutePath(SVNPathUtil.append(copyFromPath, remainder)); if (appearedRevision != null && appearedRevision.length > 0) { appearedRevision[0] = copyTargetRoot.getRevision(); } return new SVNLocationEntry(copyFromRevision, previousPath); }
FSClosestCopy closestCopy = root.getClosestCopy(path); if (closestCopy == null) { return null;
public SVNLocationEntry getPreviousLocation(String path, long revision, long[] appearedRevision) throws SVNException { if (appearedRevision != null && appearedRevision.length > 0) { appearedRevision[0] = SVNRepository.INVALID_REVISION; } FSRevisionRoot root = createRevisionRoot(revision); FSClosestCopy closestCopy = root.getClosestCopy(path); if (closestCopy == null) { return null; } FSRevisionRoot copyTargetRoot = closestCopy.getRevisionRoot(); if (copyTargetRoot == null) { return null; } String copyTargetPath = closestCopy.getPath(); FSRevisionNode copyFromNode = copyTargetRoot.getRevisionNode(copyTargetPath); String copyFromPath = copyFromNode.getCopyFromPath(); long copyFromRevision = copyFromNode.getCopyFromRevision(); String remainder = ""; if (!path.equals(copyTargetPath)) { remainder = path.substring(copyTargetPath.length()); if (remainder.startsWith("/")) { remainder = remainder.substring(1); } } String previousPath = SVNPathUtil.getAbsolutePath(SVNPathUtil.append(copyFromPath, remainder)); if (appearedRevision != null && appearedRevision.length > 0) { appearedRevision[0] = copyTargetRoot.getRevision(); } return new SVNLocationEntry(copyFromRevision, previousPath); }
FSClosestCopy closestCopy = root.getClosestCopy(path); if (closestCopy == null) { return null;
private SVNLocationEntry addFileSmartly(String editPath, String originalPath) throws SVNException { String copyFromPath = null; long copyFromRevision = SVNRepository.INVALID_REVISION; if (mySendCopyFromArgs) { FSClosestCopy closestCopy = getTargetRoot().getClosestCopy(originalPath); if (closestCopy != null) { FSRevisionRoot closestCopyRoot = closestCopy.getRevisionRoot(); String closestCopyPath = closestCopy.getPath(); if (originalPath.equals(closestCopyPath)) { FSRevisionNode closestCopyFromNode = closestCopyRoot.getRevisionNode( closestCopyPath); copyFromPath = closestCopyFromNode.getCopyFromPath(); copyFromRevision = closestCopyFromNode.getCopyFromRevision(); } } } myEditor.addFile(editPath, copyFromPath, copyFromRevision); return new SVNLocationEntry(copyFromRevision, copyFromPath); }
private SVNLocationEntry addFileSmartly(String editPath, String originalPath) throws SVNException { String copyFromPath = null; long copyFromRevision = SVNRepository.INVALID_REVISION; if (mySendCopyFromArgs) { FSClosestCopy closestCopy = getTargetRoot().getClosestCopy(originalPath); if (closestCopy != null) { FSRevisionRoot closestCopyRoot = closestCopy.getRevisionRoot(); String closestCopyPath = closestCopy.getPath(); if (originalPath.equals(closestCopyPath)) { FSRevisionNode closestCopyFromNode = closestCopyRoot.getRevisionNode( closestCopyPath); copyFromPath = closestCopyFromNode.getCopyFromPath(); copyFromRevision = closestCopyFromNode.getCopyFromRevision(); } } } myEditor.addFile(editPath, copyFromPath, copyFromRevision); return new SVNLocationEntry(copyFromRevision, copyFromPath); }
private SVNLocationEntry addFileSmartly(String editPath, String originalPath) throws SVNException { String copyFromPath = null; long copyFromRevision = SVNRepository.INVALID_REVISION; if (mySendCopyFromArgs) { if (!isTransactionTarget()) { FSClosestCopy closestCopy = ((FSRevisionRoot) getTargetRoot()).getClosestCopy(originalPath); if (closestCopy != null) { FSRevisionRoot closestCopyRoot = closestCopy.getRevisionRoot(); String closestCopyPath = closestCopy.getPath(); if (originalPath.equals(closestCopyPath)) { FSRevisionNode closestCopyFromNode = closestCopyRoot.getRevisionNode( closestCopyPath); copyFromPath = closestCopyFromNode.getCopyFromPath(); copyFromRevision = closestCopyFromNode.getCopyFromRevision(); } } } else if (isTransactionTarget()) { FSTransactionRoot txn = (FSTransactionRoot) getTargetRoot(); FSPathChange change = (FSPathChange) txn.getChangedPaths().get(originalPath); if (change != null) { copyFromPath = change.getCopyPath(); copyFromRevision = change.getCopyRevision(); } } } myEditor.addFile(editPath, copyFromPath, copyFromRevision); return new SVNLocationEntry(copyFromRevision, copyFromPath); }
FSID endNodeId = endNode.getId(); if (startNodeId.compareTo(endNodeId) != -1) { FSClosestCopy closestCopy = endRoot.getClosestCopy(path); if (closestCopy == null || closestCopy.getRevisionRoot() == null || closestCopy.getRevisionRoot().getRevision() <= startRev) { FSID currentNodeId = node.getId(); int nodeRelationship = startNodeId.compareTo(currentNodeId); FSClosestCopy closestCopy = root.getClosestCopy(path); if (nodeRelationship == -1 || (closestCopy != null && closestCopy.getRevisionRoot() != null &&
FSID endNodeId = endNode.getId(); if (startNodeId.compareTo(endNodeId) != -1) { FSClosestCopy closestCopy = endRoot.getClosestCopy(path); if (closestCopy == null || closestCopy.getRevisionRoot() == null || closestCopy.getRevisionRoot().getRevision() <= startRev) { FSID currentNodeId = node.getId(); int nodeRelationship = startNodeId.compareTo(currentNodeId); FSClosestCopy closestCopy = root.getClosestCopy(path); if (nodeRelationship == -1 || (closestCopy != null && closestCopy.getRevisionRoot() != null &&
FSID endNodeId = endNode.getId(); if (startNodeId.compareTo(endNodeId) != -1) { FSClosestCopy closestCopy = endRoot.getClosestCopy(path); if (closestCopy == null || closestCopy.getRevisionRoot() == null || closestCopy.getRevisionRoot().getRevision() <= startRev) { FSID currentNodeId = node.getId(); int nodeRelationship = startNodeId.compareTo(currentNodeId); FSClosestCopy closestCopy = root.getClosestCopy(path); if (nodeRelationship == -1 || (closestCopy != null && closestCopy.getRevisionRoot() != null &&