public void deleteEntry(String path, long revision) throws SVNException { File localAbspath = getLocalAbspath(path); String name = SVNPathUtil.tail(path); Entry pb = currentEntry; if (pb.deletes == null) { pb.deletes = new HashSet<String>(); } pb.deletes.add(name); }
public void addFile(String path, String copyFromPath, long copyFromRevision) throws SVNException { String name = SVNPathUtil.tail(path); currentFile = createFileInfo(currentDirectory, path, true); currentDirectory.comparedEntries.add(name); }
public void openFile(String path, long revision) throws SVNException { String name = SVNPathUtil.tail(path); currentFile = createFileInfo(currentDirectory, path, false); currentDirectory.comparedEntries.add(name); }
public void addFile(String path, String copyFromPath, long copyFromRevision) throws SVNException { String name = SVNPathUtil.tail(path); myCurrentFile = createFileInfo(myCurrentDirectory, path, true); myCurrentDirectory.myComparedEntries.add(name); }
public void openFile(String path, long revision) throws SVNException { String name = SVNPathUtil.tail(path); myCurrentFile = createFileInfo(myCurrentDirectory, path, false); myCurrentDirectory.myComparedEntries.add(name); }
public void openFile(String path, long revision) throws SVNException { String name = SVNPathUtil.tail(path); myCurrentFile = createFileInfo(myCurrentDirectory, path, false); myCurrentDirectory.myComparedEntries.add(name); }
public void addFile(String path, String copyFromPath, long copyFromRevision) throws SVNException { String name = SVNPathUtil.tail(path); if (!name.equals(this.name)) { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.WC_PATH_NOT_FOUND, "This editor can only update ''{0}''", localAbsPath); SVNErrorManager.error(err, SVNLogType.WC); } originalRevision = SVNWCContext.INVALID_REVNUM; this.added = true; }
public void absentDir(String path) throws SVNException { if (myCurrentDirectory.myWCFile != null) { File dir = new File(myCurrentDirectory.myWCFile, SVNPathUtil.tail(path)); SVNEvent event = SVNEventFactory.createSVNEvent(dir, SVNNodeKind.DIR, null, SVNRepository.INVALID_REVISION, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNEventAction.SKIP, null, null, null); myEventHandler.handleEvent(event, ISVNEventHandler.UNKNOWN); } }
private byte[] getName() throws UnsupportedEncodingException { if (name == null) { if (locationUrl != null) { name = SVNEncodingUtil.uriDecode(SVNPathUtil.tail(locationUrl.toDecodedString())).getBytes("UTF-8"); } } return name; }
public void absentDir(String path) throws SVNException { if (myCurrentDirectory.myWCFile != null) { File dir = new File(myCurrentDirectory.myWCFile, SVNPathUtil.tail(path)); SVNEvent event = SVNEventFactory.createSVNEvent(dir, SVNNodeKind.DIR, null, SVNRepository.INVALID_REVISION, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNEventAction.SKIP, SVNEventAction.SKIP, null, null); myEventHandler.handleEvent(event, ISVNEventHandler.UNKNOWN); } }
public void absentDir(String path) throws SVNException { if (myCurrentDirectory.myWCFile != null) { File dir = new File(myCurrentDirectory.myWCFile, SVNPathUtil.tail(path)); SVNEvent event = SVNEventFactory.createSVNEvent(dir, SVNNodeKind.DIR, null, SVNRepository.INVALID_REVISION, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNEventAction.SKIP, SVNEventAction.SKIP, null, null); myEventHandler.handleEvent(event, ISVNEventHandler.UNKNOWN); } }
/** * Returns the name of this copy source. * @return copy source name */ public String getName() { if (isURL()) { return SVNPathUtil.tail(myURL.getPath()); } return myPath.getName(); }
public void applyTextDelta(String commitPath, String baseChecksum) throws SVNException { String name = SVNPathUtil.tail(commitPath); myCurrentTmpFile = SVNFileUtil.createUniqueFile(myCurrentDirectory, name, ".tmp", false); myDeltaProcessor.applyTextDelta((File)null, myCurrentTmpFile, true); }
public static SVNEvent createMergeEvent(SVNAdminAreaInfo info, SVNAdminArea dir, String path, SVNEventAction action, SVNStatusType cType, SVNStatusType pType, SVNNodeKind kind) { SVNEvent event = new SVNEvent(info, dir, SVNPathUtil.tail(path), action, kind, -1, null, cType, pType, null, null, null); event.setPath(path); return event; }
public void absentDir(String path) throws SVNException { File file = SVNFileUtil.createFilePath(currentDir.wcPath, SVNPathUtil.tail(path)); SVNEvent event = SVNEventFactory.createSVNEvent(file, SVNNodeKind.DIR, null, -1, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNStatusType.LOCK_INAPPLICABLE, SVNEventAction.SKIP, null, null, null, null); handleEvent(event); }
public void applyTextDelta(String commitPath, String baseChecksum) throws SVNException { SVNAdminArea dir = null; try { dir = retrieveParent(myCurrentFile.myWCFile, true); } catch (SVNException e) { dir = null; } myCurrentFile.myFile = createTempFile(dir, SVNPathUtil.tail(commitPath)); myDeltaProcessor.applyTextDelta(myCurrentFile.myBaseFile, myCurrentFile.myFile, false); }
public void openFile(String path, long revision) throws SVNException { String cmpPath = null; long cmpRev = -1; if (myCurrentDirInfo != null && myCurrentDirInfo.myComparePath != null && SVNRevision.isValidRevisionNumber(myCurrentDirInfo.myCompareRevision)) { cmpPath = SVNPathUtil.append(myCurrentDirInfo.myComparePath, SVNPathUtil.tail(path)); cmpRev = myCurrentDirInfo.myCompareRevision; } dumpNode(path, SVNNodeKind.FILE, SVNAdminHelper.NODE_ACTION_CHANGE, false, cmpPath, cmpRev); }
public long fetchFile(String path, long revision, OutputStream os, SVNProperties properties) throws SVNException { SVNURL url = reposRoot.appendPath(SVNPathUtil.removeTail(path), false); if (repos2[0] == null) { repos2[0] = createRepository(url, null, null, false); } else { repos2[0].setLocation(url, false); } return repos2[0].getFile(SVNPathUtil.tail(path), revision, properties, os); } };
public void deleteEntry(String path, long revision) throws SVNException { checkIfPathIsUnderRoot(path); String name = SVNPathUtil.tail(path); SVNURL url = SVNURL.parseURIEncoded(myCurrentDirectory.URL); SVNURL theirURL = url.appendPath(name, false); checkIfPathIsUnderRoot(path); doDeleteEntry(path, myCurrentDirectory.getAdminArea(), myCurrentDirectory, theirURL); }
private FSEntry fakeDirEntry(String reposPath, FSRoot root) throws SVNException { if (root.checkNodeKind(reposPath) == SVNNodeKind.NONE) { return null; } FSRevisionNode node = root.getRevisionNode(reposPath); FSEntry dirEntry = new FSEntry(node.getId(), node.getType(), SVNPathUtil.tail(node.getCreatedPath())); return dirEntry; }