|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.tmatesoft.svn.core.wc2.SvnOperation<V>
org.tmatesoft.svn.core.wc2.AbstractSvnUpdate<java.lang.Long>
org.tmatesoft.svn.core.wc2.SvnSwitch
public class SvnSwitch
Represents switch operation.
Switches working tree of target to switchTarget\
switchTarget's pegRevision at revision.
switchTarget from scratch.
If depth is SVNDepth.INFINITY, switches fully
recursively. Else if it is SVNDepth.IMMEDIATES, switches
target and its file children (if any), and switches
subdirectories but does not update them. Else if SVNDepth.FILES,
switches just file children, ignoring subdirectories completely. Else if
SVNDepth.EMPTY, switches just target and touches
nothing underneath it.
If externals are ignored (ignoreExternals is true), doesn't process
externals definitions as part of this operation.
If allowUnversionedObstructions is true then the switch tolerates existing
unversioned items that obstruct added paths. Only obstructions of the
same type (file or directory) as the added item are tolerated. The text of
obstructing files is left as-is, effectively treating it as a user
modification after the switch. Working properties of obstructing items
are set equal to the base properties. If
allowUnversionedObstructions is false then the switch will abort if there are
any unversioned obstructing items.
If the caller's ISVNEventHandler is non-null, it is invoked for paths affected by the
switch, and also for files restored from text-base. Also
ISVNCanceller.checkCancelled() will be used at various places
during the switch to check whether the caller wants to stop the switch.
This operation requires repository access (in case the repository is not
on the same machine, network connection is established).
SvnOperation.run() method returns value of the revision value to which the working copy was actually
switched.
SvnOperation.run() method returns value of the revision to which the working copy was actually switched.
SVNErrorCode.UNSUPPORTED_FEATURE
error code - if target is not in the repository yet
exception with SVNErrorCode.ENTRY_MISSING_URL error code
- if switchTarget directory has no URL
exception with SVNErrorCode.WC_INVALID_SWITCH error code
- if switchTarget is not the same repository as target's repository
exception with SVNErrorCode.CLIENT_UNRELATED_RESOURCES error code
- if ignoreAncestry is false and
switchTarget shares no common ancestry with target
| Constructor Summary | |
|---|---|
protected |
SvnSwitch(SvnOperationFactory factory)
|
| Method Summary | |
|---|---|
protected void |
ensureArgumentsAreValid()
|
SvnTarget |
getSwitchTarget()
Returns the repository location as a target against which the item will be switched. |
boolean |
isChangesWorkingCopy()
Gets whether the operation changes working copy |
boolean |
isDepthIsSticky()
Returns whether depth is sticky. |
boolean |
isIgnoreAncestry()
Returns whether to ignore ancestry when calculating merges. |
void |
setDepthIsSticky(boolean depthIsSticky)
Sets whether depth is sticky. |
void |
setIgnoreAncestry(boolean ignoreAncestry)
Sets whether to ignore ancestry when calculating merges. |
void |
setSwitchTarget(SvnTarget switchTarget)
Sets the repository location as a target against which the item will be switched. |
| Methods inherited from class org.tmatesoft.svn.core.wc2.AbstractSvnUpdate |
|---|
getExternalsHandler, isAllowUnversionedObstructions, isIgnoreExternals, isUpdateLocksOnDemand, setAllowUnversionedObstructions, setExternalsHandler, setIgnoreExternals, setUpdateLocksOnDemand |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected SvnSwitch(SvnOperationFactory factory)
| Method Detail |
|---|
public boolean isDepthIsSticky()
depthIsSticky is set the operation will use depth as status scope, otherwise
SVNDepth.UNKNOWN will be used.
true if the depth is sticky, otherwise falsepublic boolean isIgnoreAncestry()
true if ancestry should be ignored, otherwise falsepublic SvnTarget getSwitchTarget()
public void setDepthIsSticky(boolean depthIsSticky)
depthIsSticky is set the operation will use depth as status scope, otherwise
SVNDepth.UNKNOWN will be used.
depthIsSticky - true if the depth is sticky, otherwise falsepublic void setIgnoreAncestry(boolean ignoreAncestry)
ignoreAncestry - true if ancestry should be ignored, otherwise falsepublic void setSwitchTarget(SvnTarget switchTarget)
switchTarget - switch target
protected void ensureArgumentsAreValid()
throws SVNException
ensureArgumentsAreValid in class SvnOperation<java.lang.Long>SVNExceptionpublic boolean isChangesWorkingCopy()
isChangesWorkingCopy in class SvnOperation<java.lang.Long>true if the operation changes the working copy, otherwise false
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||