/** * Updates the Working Copy item to mirror a new URL. * * <p> * As a revision <b>SVNRevision</b>'s pre-defined constant fields can be used. For example, * to update the Working Copy to the latest revision of the repository use * {@link SVNRevision#HEAD HEAD}. * * <p> * Calling this method is equivalent to * <code>doSwitch(file, url, SVNRevision.UNDEFINED, revision, recursive)</code>. * * @param file the Working copy item to be switched * @param url the repository location as a target against which the item will * be switched * @param revision the desired revision of the repository target * @param recursive if <span class="javakeyword">true</span> and <code>file</code> is * a directory then the entire tree will be updated, otherwise if * <span class="javakeyword">false</span> - only items located immediately * in the directory itself * @return the revision number to which <code>file</code> was updated to * @throws SVNException */ public long doSwitch(File file, SVNURL url, SVNRevision revision, boolean recursive) throws SVNException { return doSwitch(file, url, SVNRevision.UNDEFINED, revision, recursive); }
/** * @param file * @param url * @param pegRevision * @param revision * @param recursive * @param force * @return actual revision number * @throws SVNException * @deprecated use {@link #doSwitch(File, SVNURL, SVNRevision, SVNRevision, SVNDepth, boolean, boolean)} instead */ public long doSwitch(File file, SVNURL url, SVNRevision pegRevision, SVNRevision revision, boolean recursive, boolean force) throws SVNException { return doSwitch(file, url, pegRevision, revision, SVNDepth.getInfinityOrFilesDepth(recursive), force, false); }
/** * @param file * @param url * @param pegRevision * @param revision * @param recursive * @param force * @return actual revision number * @throws SVNException * @deprecated use {@link #doSwitch(File, SVNURL, SVNRevision, SVNRevision, SVNDepth, boolean, boolean)} instead */ public long doSwitch(File file, SVNURL url, SVNRevision pegRevision, SVNRevision revision, boolean recursive, boolean force) throws SVNException { return doSwitch(file, url, pegRevision, revision, SVNDepth.getInfinityOrFilesDepth(recursive), force, false); }
/** * @param file * @param url * @param pegRevision * @param revision * @param recursive * @param force * @return actual revision number * @throws SVNException * @deprecated use * {@link #doSwitch(File, SVNURL, SVNRevision, SVNRevision, SVNDepth, boolean, boolean)} * instead */ public long doSwitch(File file, SVNURL url, SVNRevision pegRevision, SVNRevision revision, boolean recursive, boolean force) throws SVNException { return doSwitch(file, url, pegRevision, revision, SVNDepth.getInfinityOrFilesDepth(recursive), force, false); }
public static void switchToBranch(final String branchUrl, final File basedir, final ISVNDebugLog log) throws SVNException, IOException{ final SVNUpdateClient updateClient = SVNClientManager .newInstance().getUpdateClient(); if(log != null) updateClient.setDebugLog(log); updateClient.doSwitch(basedir, SVNURL.parseURIEncoded(branchUrl), SVNRevision.HEAD, SVNRevision.HEAD, SVNDepth.INFINITY, false, false); }
return doSwitch(file, url, pegRevision, revision, SVNDepth.getInfinityOrFilesDepth(recursive), false, false);
/** * Updates the Working Copy item to mirror a new URL. * * <p> * As a revision <b>SVNRevision</b>'s pre-defined constant fields can be used. For example, * to update the Working Copy to the latest revision of the repository use * {@link SVNRevision#HEAD HEAD}. * * <p> * Calling this method is equivalent to * <code>doSwitch(file, url, SVNRevision.UNDEFINED, revision, recursive)</code>. * * @param file the Working copy item to be switched * @param url the repository location as a target against which the item will * be switched * @param revision the desired revision of the repository target * @param recursive if <span class="javakeyword">true</span> and <code>file</code> is * a directory then the entire tree will be updated, otherwise if * <span class="javakeyword">false</span> - only items located immediately * in the directory itself * @return the revision number to which <code>file</code> was updated to * @throws SVNException * @deprecated use {@link #doSwitch(File, SVNURL, SVNRevision, SVNRevision, SVNDepth, boolean, boolean)} instead */ public long doSwitch(File file, SVNURL url, SVNRevision revision, boolean recursive) throws SVNException { return doSwitch(file, url, SVNRevision.UNDEFINED, revision, SVNDepth.getInfinityOrFilesDepth(recursive), false, false); }
/** * Updates the Working Copy item to mirror a new URL. * * <p> * As a revision <b>SVNRevision</b>'s pre-defined constant fields can be used. For example, * to update the Working Copy to the latest revision of the repository use * {@link SVNRevision#HEAD HEAD}. * * @param file the Working copy item to be switched * @param url the repository location as a target against which the item will * be switched * @param pegRevision a revision in which <code>file</code> is first looked up * in the repository * @param revision the desired revision of the repository target * @param recursive if <span class="javakeyword">true</span> and <code>file</code> is * a directory then the entire tree will be updated, otherwise if * <span class="javakeyword">false</span> - only items located immediately * in the directory itself * @return the revision number to which <code>file</code> was updated to * @throws SVNException * @deprecated use {@link #doSwitch(File, SVNURL, SVNRevision, SVNRevision, SVNDepth, boolean, boolean)} instead */ public long doSwitch(File file, SVNURL url, SVNRevision pegRevision, SVNRevision revision, boolean recursive) throws SVNException { return doSwitch(file, url, pegRevision, revision, SVNDepth.getInfinityOrFilesDepth(recursive), false, false); }
/** * Updates the Working Copy item to mirror a new URL. * * <p> * As a revision <b>SVNRevision</b>'s pre-defined constant fields can be used. For example, * to update the Working Copy to the latest revision of the repository use * {@link SVNRevision#HEAD HEAD}. * * @param file the Working copy item to be switched * @param url the repository location as a target against which the item will * be switched * @param pegRevision a revision in which <code>file</code> is first looked up * in the repository * @param revision the desired revision of the repository target * @param recursive if <span class="javakeyword">true</span> and <code>file</code> is * a directory then the entire tree will be updated, otherwise if * <span class="javakeyword">false</span> - only items located immediately * in the directory itself * @return the revision number to which <code>file</code> was updated to * @throws SVNException * @deprecated use {@link #doSwitch(File, SVNURL, SVNRevision, SVNRevision, SVNDepth, boolean, boolean)} instead */ public long doSwitch(File file, SVNURL url, SVNRevision pegRevision, SVNRevision revision, boolean recursive) throws SVNException { return doSwitch(file, url, pegRevision, revision, SVNDepth.getInfinityOrFilesDepth(recursive), false, false); }
return doSwitch(file, url, SVNRevision.UNDEFINED, revision, SVNDepth.getInfinityOrFilesDepth(recursive), false, false);
/** * Updates the Working Copy item to mirror a new URL. * * <p> * As a revision <b>SVNRevision</b>'s pre-defined constant fields can be used. For example, * to update the Working Copy to the latest revision of the repository use * {@link SVNRevision#HEAD HEAD}. * * <p> * Calling this method is equivalent to * <code>doSwitch(file, url, SVNRevision.UNDEFINED, revision, recursive)</code>. * * @param file the Working copy item to be switched * @param url the repository location as a target against which the item will * be switched * @param revision the desired revision of the repository target * @param recursive if <span class="javakeyword">true</span> and <code>file</code> is * a directory then the entire tree will be updated, otherwise if * <span class="javakeyword">false</span> - only items located immediately * in the directory itself * @return the revision number to which <code>file</code> was updated to * @throws SVNException * @deprecated use {@link #doSwitch(File, SVNURL, SVNRevision, SVNRevision, SVNDepth, boolean, boolean)} instead */ public long doSwitch(File file, SVNURL url, SVNRevision revision, boolean recursive) throws SVNException { return doSwitch(file, url, SVNRevision.UNDEFINED, revision, SVNDepth.getInfinityOrFilesDepth(recursive), false, false); }
public long doSwitch(String path, String url, Revision revision, boolean recurse) throws ClientException { SVNUpdateClient updater = getSVNUpdateClient(); try { return updater.doSwitch(new File(path).getAbsoluteFile(), SVNURL.parseURIEncoded(url), JavaHLObjectFactory.getSVNRevision(revision), recurse); } catch (SVNException e) { throwException(e); } return -1; }
return updateClient.doSwitch( wcPath, url, updateToRevision, isRecursive );
public long doSwitch(String path, String url, Revision revision, Revision pegRevision, int depth, boolean depthIsSticky, boolean ignoreExternals, boolean allowUnverObstructions) throws ClientException { SVNUpdateClient updater = getSVNUpdateClient(); try { return updater.doSwitch(new File(path).getAbsoluteFile(), SVNURL.parseURIEncoded(url), JavaHLObjectFactory.getSVNRevision(pegRevision), JavaHLObjectFactory.getSVNRevision(revision), JavaHLObjectFactory.getSVNDepth(depth), allowUnverObstructions, depthIsSticky); } catch (SVNException e) { throwException(e); } finally { resetLog(); } return -1; }
public long doSwitch(String path, String url, Revision revision, Revision pegRevision, int depth, boolean depthIsSticky, boolean ignoreExternals, boolean allowUnverObstructions) throws ClientException { SVNUpdateClient updater = getSVNUpdateClient(); try { return updater.doSwitch(new File(path).getAbsoluteFile(), SVNURL.parseURIEncoded(url), JavaHLObjectFactory.getSVNRevision(pegRevision), JavaHLObjectFactory.getSVNRevision(revision), JavaHLObjectFactory.getSVNDepth(depth), allowUnverObstructions, depthIsSticky); } catch (SVNException e) { throwException(e); } finally { resetLog(); } return -1; }
public long doSwitch(String path, String url, Revision revision, Revision pegRevision, int depth, boolean depthIsSticky, boolean ignoreExternals, boolean allowUnverObstructions) throws ClientException { SVNUpdateClient updater = getSVNUpdateClient(); try { return updater.doSwitch(new File(path).getAbsoluteFile(), SVNURL.parseURIEncoded(url), JavaHLObjectFactory.getSVNRevision(pegRevision), JavaHLObjectFactory.getSVNRevision(revision), JavaHLObjectFactory.getSVNDepth(depth), allowUnverObstructions, depthIsSticky); } catch (SVNException e) { throwException(e); } finally { resetLog(); } return -1; }
long newRevision = updateClient.doSwitch(localRoot, // File path
(revision != null ? revision.toString() : "null") + " depth:" + svnDepth + " ignoreExternals: " + l.isIgnoreExternalsOption()); svnuc.doSwitch(local.getCanonicalFile(), l.getSVNURL(), SVNRevision.HEAD, revision, svnDepth, true, false); } catch (final SVNException e) {
client.doSwitch(target.getFile(), switchURL.getURL(), switchURL.getPegRevision(), getSVNEnvironment().getStartRevision(), depth, getSVNEnvironment().isForce(), depthIsSticky, ignoreAncestry);
client.doSwitch(target.getFile(), switchURL.getURL(), switchURL.getPegRevision(), getSVNEnvironment().getStartRevision(), depth, getSVNEnvironment().isForce(), depthIsSticky, ignoreAncestry);