/** * Opens a corresponding <code>path</code> in the target repository. * * @param path target directory path relative to the root of the edit * @param revision target directory revision * @throws SVNException */ public void openDir(String path, long revision) throws SVNException { EntryBaton baton = new EntryBaton(getSourceRepository().getRepositoryPath(path)); baton.myPropsAct = ACCEPT; myDirsStack.push(baton); myCommitEditor.openDir(path, myPreviousRevision); }
public void openDir(String path, long revision) throws SVNException { EntryBaton baton = new EntryBaton(getSourceRepository().getRepositoryPath(path)); baton.myPropsAct = ACCEPT; myDirsStack.push(baton); myCommitEditor.openDir(path, myPreviousRevision); }
public void openFile(String path, long revision) throws SVNException { EntryBaton baton = new EntryBaton(getSourceRepository().getRepositoryPath(path)); baton.myPropsAct = ACCEPT; baton.myTextAct = ACCEPT; myPathsToFileBatons.put(path, baton); myCommitEditor.openFile(path, myPreviousRevision); }
/** * Opens a file. * * @param path * @param revision * @throws SVNException */ public void openFile(String path, long revision) throws SVNException { EntryBaton baton = new EntryBaton(getSourceRepository().getRepositoryPath(path)); baton.myPropsAct = ACCEPT; baton.myTextAct = ACCEPT; myPathsToFileBatons.put(path, baton); myCommitEditor.openFile(path, myPreviousRevision); }
/** * Opens a corresponding <code>path</code> in the target repository. * * @param path target directory path relative to the root of the edit * @param revision target directory revision * @throws SVNException */ public void openDir(String path, long revision) throws SVNException { EntryBaton baton = new EntryBaton(getSourceRepository().getRepositoryPath(path)); baton.myPropsAct = ACCEPT; myDirsStack.push(baton); myCommitEditor.openDir(path, myPreviousRevision); }
/** * Opens a corresponding <code>path</code> in the target repository. * * @param path target directory path relative to the root of the edit * @param revision target directory revision * @throws SVNException */ public void openDir(String path, long revision) throws SVNException { EntryBaton baton = new EntryBaton(getSourceRepository().getRepositoryPath(path)); baton.myPropsAct = ACCEPT; myDirsStack.push(baton); myCommitEditor.openDir(path, myPreviousRevision); }
/** * Opens a file. * * @param path * @param revision * @throws SVNException */ public void openFile(String path, long revision) throws SVNException { EntryBaton baton = new EntryBaton(getSourceRepository().getRepositoryPath(path)); baton.myPropsAct = ACCEPT; baton.myTextAct = ACCEPT; myPathsToFileBatons.put(path, baton); myCommitEditor.openFile(path, myPreviousRevision); }
/** * Opens a file. * * @param path * @param revision * @throws SVNException */ public void openFile(String path, long revision) throws SVNException { EntryBaton baton = new EntryBaton(getSourceRepository().getRepositoryPath(path)); baton.myPropsAct = ACCEPT; baton.myTextAct = ACCEPT; myPathsToFileBatons.put(path, baton); myCommitEditor.openFile(path, myPreviousRevision); }
private Map getLocations10(SVNRepository repos, final long pegRevision, final long startRevision, final long endRevision) throws SVNException { final String path = repos.getRepositoryPath(""); final SVNNodeKind kind = repos.checkPath("", pegRevision); if (kind == SVNNodeKind.NONE) {
public void deleteEntry(String path, long revision) throws SVNException { String absPath = getSourceRepository().getRepositoryPath(path); SVNLogEntryPath deletedPath = (SVNLogEntryPath) myChangedPaths.get(absPath); if (deletedPath != null && (deletedPath.getType() == SVNLogEntryPath.TYPE_DELETED || deletedPath.getType() == SVNLogEntryPath.TYPE_REPLACED)) { if (deletedPath.getType() == SVNLogEntryPath.TYPE_DELETED) { myChangedPaths.remove(absPath); } } else { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.UNKNOWN, "Expected that path ''{0}'' is deleted in revision {1,number,integer}", new Object[]{absPath, new Long(myPreviousRevision)}); SVNErrorManager.error(err); } myCommitEditor.deleteEntry(path, myPreviousRevision); }
private Map getLocations10(SVNRepository repos, final long pegRevision, final long startRevision, final long endRevision) throws SVNException { final String path = repos.getRepositoryPath(""); final SVNNodeKind kind = repos.checkPath("", pegRevision); if (kind == SVNNodeKind.NONE) {
private Map getLocations10(SVNRepository repos, final long pegRevision, final long startRevision, final long endRevision) throws SVNException { final String path = repos.getRepositoryPath(""); final SVNNodeKind kind = repos.checkPath("", pegRevision); if (kind == SVNNodeKind.NONE) {
private Map getLocations10(SVNRepository repos, final long pegRevision, final long startRevision, final long endRevision) throws SVNException { final String path = repos.getRepositoryPath(""); final SVNNodeKind kind = repos.checkPath("", pegRevision); if (kind == SVNNodeKind.NONE) {
/** * Removes <code>path</code> from the paths to be committed. * * @param path * @param revision * @throws SVNException exception with {@link SVNErrorCode#UNKNOWN} error code - if somehow * chanded paths fetched from the log of the resource repository did not * reflect <code>path</code> deletion in <code>revision</code> * */ public void deleteEntry(String path, long revision) throws SVNException { String absPath = getSourceRepository().getRepositoryPath(path); SVNLogEntryPath deletedPath = (SVNLogEntryPath) myChangedPaths.get(absPath); if (deletedPath != null && (deletedPath.getType() == SVNLogEntryPath.TYPE_DELETED || deletedPath.getType() == SVNLogEntryPath.TYPE_REPLACED)) { if (deletedPath.getType() == SVNLogEntryPath.TYPE_DELETED) { myChangedPaths.remove(absPath); } } else { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.UNKNOWN, "Expected that path ''{0}'' is deleted in revision {1}", new Object[]{absPath, new Long(myPreviousRevision)}); SVNErrorManager.error(err, SVNLogType.FSFS); } if (!myDeletedPaths.contains(path)) { myCommitEditor.deleteEntry(path, myPreviousRevision); myDeletedPaths.add(path); } }
/** * Removes <code>path</code> from the paths to be committed. * * @param path * @param revision * @throws SVNException exception with {@link SVNErrorCode#UNKNOWN} error code - if somehow * chanded paths fetched from the log of the resource repository did not * reflect <code>path</code> deletion in <code>revision</code> * */ public void deleteEntry(String path, long revision) throws SVNException { String absPath = getSourceRepository().getRepositoryPath(path); SVNLogEntryPath deletedPath = (SVNLogEntryPath) myChangedPaths.get(absPath); if (deletedPath != null && (deletedPath.getType() == SVNLogEntryPath.TYPE_DELETED || deletedPath.getType() == SVNLogEntryPath.TYPE_REPLACED)) { if (deletedPath.getType() == SVNLogEntryPath.TYPE_DELETED) { myChangedPaths.remove(absPath); } } else { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.UNKNOWN, "Expected that path ''{0}'' is deleted in revision {1}", new Object[]{absPath, new Long(myPreviousRevision)}); SVNErrorManager.error(err, SVNLogType.FSFS); } myCommitEditor.deleteEntry(path, myPreviousRevision); }
/** * Removes <code>path</code> from the paths to be committed. * * @param path * @param revision * @throws SVNException exception with {@link SVNErrorCode#UNKNOWN} error code - if somehow * chanded paths fetched from the log of the resource repository did not * reflect <code>path</code> deletion in <code>revision</code> * */ public void deleteEntry(String path, long revision) throws SVNException { String absPath = getSourceRepository().getRepositoryPath(path); SVNLogEntryPath deletedPath = (SVNLogEntryPath) myChangedPaths.get(absPath); if (deletedPath != null && (deletedPath.getType() == SVNLogEntryPath.TYPE_DELETED || deletedPath.getType() == SVNLogEntryPath.TYPE_REPLACED)) { if (deletedPath.getType() == SVNLogEntryPath.TYPE_DELETED) { myChangedPaths.remove(absPath); } } else { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.UNKNOWN, "Expected that path ''{0}'' is deleted in revision {1}", new Object[]{absPath, new Long(myPreviousRevision)}); SVNErrorManager.error(err, SVNLogType.FSFS); } myCommitEditor.deleteEntry(path, myPreviousRevision); }
private long getLocationSegmentsFromLog(String path, long pegRevision, long startRevision, long endRevision, ISVNLocationSegmentHandler handler) throws SVNException { String reposAbsPath = getRepositoryPath(path); long youngestRevision = INVALID_REVISION; if (isInvalidRevision(pegRevision)) {
String absPath = getSourceRepository().getRepositoryPath(path); EntryBaton baton = new EntryBaton(absPath); myDirsStack.push(baton);
public void addDir(String path, String copyFromPath, long copyFromRevision) throws SVNException { String absPath = getSourceRepository().getRepositoryPath(path); EntryBaton baton = new EntryBaton(absPath); myDirsStack.push(baton); SVNLogEntryPath changedPath = (SVNLogEntryPath) myChangedPaths.get(absPath); if (changedPath != null && (changedPath.getType() == SVNLogEntryPath.TYPE_ADDED || changedPath.getType() == SVNLogEntryPath.TYPE_REPLACED) && changedPath.getCopyPath() != null && changedPath.getCopyRevision() >= 0) { baton.myPropsAct = DECIDE; HashMap props = new HashMap(); getSourceRepository().getDir(changedPath.getCopyPath(), changedPath.getCopyRevision(), props, (ISVNDirEntryHandler) null); baton.myProps = props; if (changedPath.getType() == SVNLogEntryPath.TYPE_REPLACED) { myCommitEditor.deleteEntry(path, myPreviousRevision); myChangedPaths.remove(absPath); } myCommitEditor.addDir(path, changedPath.getCopyPath(), changedPath.getCopyRevision()); } else if (changedPath != null && (changedPath.getType() == SVNLogEntryPath.TYPE_ADDED || changedPath.getType() == SVNLogEntryPath.TYPE_REPLACED)) { baton.myPropsAct = ACCEPT; myCommitEditor.addDir(path, null, -1); } else if (changedPath != null && changedPath.getType() == SVNLogEntryPath.TYPE_MODIFIED) { baton.myPropsAct = ACCEPT; myCommitEditor.openDir(path, myPreviousRevision); } else if (changedPath == null) { baton.myPropsAct = IGNORE; myCommitEditor.openDir(path, myPreviousRevision); } else { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.UNKNOWN, "Unknown bug in addDir()"); SVNErrorManager.error(err); } }
private long getLocationSegmentsFromLog(String path, long pegRevision, long startRevision, long endRevision, ISVNLocationSegmentHandler handler) throws SVNException { String reposAbsPath = getRepositoryPath(path); long youngestRevision = INVALID_REVISION; if (isInvalidRevision(pegRevision)) {