Package org.tmatesoft.svn.core.wc2
Class SvnRevert
- java.lang.Object
-
- org.tmatesoft.svn.core.wc2.SvnOperation<java.lang.Void>
-
- org.tmatesoft.svn.core.wc2.SvnRevert
-
- All Implemented Interfaces:
ISvnOperationOptionsProvider
public class SvnRevert extends SvnOperation<java.lang.Void>
Represents revert operation. Restores the pristine version of working copytargets, effectively undoing any local mods. For each path intargets, reverts it if it is a file. Else if it is a directory, reverts according todepth: If depth isSVNDepth.EMPTY, reverts just the properties on the directory; else ifSVNDepth.FILES, reverts the properties and any files immediately under the directory; else ifSVNDepth.IMMEDIATES, reverts all of the preceding plus properties on immediate subdirectories; else ifSVNDepth.INFINITY, reverts path and everything under it fully recursively.changeListsis a collection ofStringchangelist names, used as a restrictive filter on items reverted; that is, doesn't revert any item unless it's a member of one of those changelists. IfchangeListsis empty (ornull), no changelist filtering occurs. If an item specified for reversion is not under version control, then does not fail with an exception, just invokesISVNEventHandlerusing notification codeSVNEventAction.SKIP.- Version:
- 1.7
- Author:
- TMate Software Ltd.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedSvnRevert(SvnOperationFactory factory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidensureArgumentsAreValid()protected intgetMaximumTargetsCount()booleanisChangesWorkingCopy()Gets whether the operation changes working copybooleanisClearChangelists()booleanisMetadataOnly()booleanisPreserveModifiedCopies()booleanisRevertMissingDirectories()voidsetClearChangelists(boolean clearChangelists)voidsetMetadataOnly(boolean metadataOnly)voidsetPreserveModifiedCopies(boolean preserveModifiedCopies)voidsetRevertMissingDirectories(boolean revertMissingDirectories)-
Methods inherited from class org.tmatesoft.svn.core.wc2.SvnOperation
addTarget, cancel, ensureEnoughTargets, ensureHomohenousTargets, getApplicableChangelists, getAuthenticationManager, getCanceller, getDepth, getEventHandler, getFirstTarget, getMinimumTargetsCount, getOperationalWorkingCopy, getOperationFactory, getOptions, getRepositoryPool, getRevision, getSqliteJournalMode, getTargets, hasFileTargets, hasLocalTargets, hasRemoteTargets, initDefaults, isCancelled, isSleepForTimestamp, isUseParentWcFormat, needsHomohenousTargets, run, setApplicalbeChangelists, setDepth, setRevision, setSingleTarget, setSleepForTimestamp, setSqliteJournalMode
-
-
-
-
Constructor Detail
-
SvnRevert
protected SvnRevert(SvnOperationFactory factory)
-
-
Method Detail
-
isRevertMissingDirectories
public boolean isRevertMissingDirectories()
-
setRevertMissingDirectories
public void setRevertMissingDirectories(boolean revertMissingDirectories)
-
isPreserveModifiedCopies
public boolean isPreserveModifiedCopies()
-
setPreserveModifiedCopies
public void setPreserveModifiedCopies(boolean preserveModifiedCopies)
-
isClearChangelists
public boolean isClearChangelists()
-
setClearChangelists
public void setClearChangelists(boolean clearChangelists)
-
isMetadataOnly
public boolean isMetadataOnly()
-
setMetadataOnly
public void setMetadataOnly(boolean metadataOnly)
-
ensureArgumentsAreValid
protected void ensureArgumentsAreValid() throws SVNException- Overrides:
ensureArgumentsAreValidin classSvnOperation<java.lang.Void>- Throws:
SVNException
-
getMaximumTargetsCount
protected int getMaximumTargetsCount()
- Overrides:
getMaximumTargetsCountin classSvnOperation<java.lang.Void>
-
isChangesWorkingCopy
public boolean isChangesWorkingCopy()
Gets whether the operation changes working copy- Overrides:
isChangesWorkingCopyin classSvnOperation<java.lang.Void>- Returns:
trueif the operation changes the working copy, otherwisefalse
-
-