Class SVNWCClient
| SVNKit | Subversion |
| doAdd() | 'svn add' |
| doGetFileContents() | 'svn cat' |
| doDelete() | 'svn delete' |
| doCleanup() | 'svn cleanup' |
| doInfo() | 'svn info' |
| doLock() | 'svn lock' |
| doUnlock() | 'svn unlock' |
| doSetProperty() |
'svn propset PROPNAME PROPVAL PATH' 'svn propdel PROPNAME PATH' 'svn propedit PROPNAME PATH' |
| doSetRevisionProperty() |
'svn propset PROPNAME --revprop -r REV PROPVAL [URL]' 'svn propdel PROPNAME --revprop -r REV [URL]' 'svn propedit PROPNAME --revprop -r REV [URL]' |
| doGetProperty() |
'svn propget PROPNAME PATH' 'svn proplist PATH' |
| doGetRevisionProperty() |
'svn propget PROPNAME --revprop -r REV [URL]' 'svn proplist --revprop -r REV [URL]' |
| doResolve() | 'svn resolved' |
| doRevert() | 'svn revert' |
- Since:
- 1.2
- Version:
- 1.3
- Author:
- TMate Software Ltd.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic ISVNAddParametersDefault implementation ofISVNAddParameterswhichonInconsistentEOLs(File file)always returns theISVNAddParameters.REPORT_ERRORaction. -
Constructor Summary
ConstructorsConstructorDescriptionSVNWCClient(ISVNAuthenticationManager authManager, ISVNOptions options) Constructs and initializes an SVNWCClient object with the specified run-time configuration and authentication drivers.SVNWCClient(ISVNRepositoryPool repositoryPool, ISVNOptions options) Constructs and initializes an SVNWCClient object with the specified run-time configuration and repository pool object. -
Method Summary
Modifier and TypeMethodDescriptionvoiddoAdd(File[] paths, boolean force, boolean mkdir, boolean climbUnversionedParents, SVNDepth depth, boolean depthIsSticky, boolean includeIgnored, boolean makeParents) Schedules working copypathsfor addition to the repository.voiddoAdd(File[] paths, boolean force, boolean mkdir, boolean climbUnversionedParents, SVNDepth depth, boolean depthIsSticky, boolean includeIgnored, boolean makeParents, boolean applyAutoProperties) Schedules working copypathsfor addition to the repository.voidDeprecated.voiddoAdd(File path, boolean force, boolean mkdir, boolean climbUnversionedParents, boolean recursive, boolean includeIgnored) Deprecated.voiddoAdd(File path, boolean force, boolean mkdir, boolean climbUnversionedParents, SVNDepth depth, boolean includeIgnored, boolean makeParents) Schedules a working copypathfor addition to the repository.voiddoAdd(File path, boolean force, boolean mkdir, boolean climbUnversionedParents, SVNDepth depth, boolean depthIsSticky, boolean includeIgnored, boolean makeParents) Schedules a working copypathfor addition to the repository.voidCleans up a working copy.voidRecursively cleans up the working copy, removing locks and resuming unfinished operations.voiddoCleanup(File path, boolean deleteWCProperties, boolean breakLocks, boolean vacuumPristines, boolean removeUnversionedItems, boolean removeIgnoredItems, boolean includeExternals) voiddoCleanupWCProperties(File directory) Recursively removes all DAV-specific "svn:wc:" properties from thedirectoryand beneath.voidSchedules a Working Copy item for deletion.voidSchedules a Working Copy item for deletion.voiddoGetFileContents(File path, SVNRevision pegRevision, SVNRevision revision, boolean expandKeywords, OutputStream dst) Outputs the content of file identified bypathandrevisionto the streamdst.voiddoGetFileContents(SVNURL url, SVNRevision pegRevision, SVNRevision revision, boolean expandKeywords, OutputStream dst) Outputs the content of file identified byurlandrevisionto the streamdst.doGetProperty(File path, String propName, SVNRevision pegRevision, SVNRevision revision) Gets the value of the propertypropNameforpath.voiddoGetProperty(File path, String propName, SVNRevision pegRevision, SVNRevision revision, boolean recursive, ISVNPropertyHandler handler) Deprecated.voiddoGetProperty(File path, String propName, SVNRevision pegRevision, SVNRevision revision, SVNDepth depth, ISVNPropertyHandler handler, Collection<String> changeLists) Invokeshandleron paths covered bydepthstarting with the specifiedpath.doGetProperty(SVNURL url, String propName, SVNRevision pegRevision, SVNRevision revision) Gets the value of the propertypropNameforurl.voiddoGetProperty(SVNURL url, String propName, SVNRevision pegRevision, SVNRevision revision, boolean recursive, ISVNPropertyHandler handler) Deprecated.voiddoGetProperty(SVNURL url, String propName, SVNRevision pegRevision, SVNRevision revision, SVNDepth depth, ISVNPropertyHandler handler) Invokeshandleron paths covered bydepthstarting with the specifiedpath.longdoGetRevisionProperty(File path, String propName, SVNRevision revision, ISVNPropertyHandler handler) Gets an unversioned revision property from a repository (getting a repository URL from a Working Copy) and passes it to a provided property handler.longdoGetRevisionProperty(SVNURL url, String propName, SVNRevision revision, ISVNPropertyHandler handler) Gets an unversioned revision property from a repository and passes it to a provided property handler.doGetWorkingCopyID(File path, String trailURL) Returns the current Working Copy min- and max- revisions as well as changes and switch status within a single string.doGetWorkingCopyID(File path, String trailURL, boolean committed) Returns the current Working Copy min- and max- revisions as well as changes and switch status within a single string.doInfo(File path, SVNRevision revision) Collects and returns information on a single Working Copy item.voiddoInfo(File path, SVNRevision revision, boolean recursive, ISVNInfoHandler handler) Deprecated.voiddoInfo(File path, SVNRevision pegRevision, SVNRevision revision, boolean recursive, ISVNInfoHandler handler) Deprecated.voiddoInfo(File path, SVNRevision pegRevision, SVNRevision revision, SVNDepth depth, Collection<String> changeLists, ISVNInfoHandler handler) Invokeshandlerto return information aboutpathinrevision.doInfo(SVNURL url, SVNRevision pegRevision, SVNRevision revision) Collects and returns information on a single item in a repository.voiddoInfo(SVNURL url, SVNRevision pegRevision, SVNRevision revision, boolean recursive, ISVNInfoHandler handler) Deprecated.voiddoInfo(SVNURL url, SVNRevision pegRevision, SVNRevision revision, SVNDepth depth, ISVNInfoHandler handler) Invokeshandlerto return information abouturlinrevision.voidLocks file items in a Working Copy as well as in a repository so that no other user can commit changes to them.voidLocks file items in a repository so that no other user can commit changes to them.voiddoMarkReplaced(File path) Schedulespathas being replaced.voidDeprecated.usedoResolve(File, SVNDepth, SVNConflictChoice)insteadvoiddoResolve(File path, SVNDepth depth, boolean resolveContents, boolean resolveProperties, boolean resolveTree, SVNConflictChoice conflictChoice) Performs automatic conflict resolution on a working copypath.voiddoResolve(File path, SVNDepth depth, boolean resolveContents, boolean resolveProperties, SVNConflictChoice conflictChoice) Performs automatic conflict resolution on a working copypath.voiddoResolve(File path, SVNDepth depth, SVNConflictChoice conflictChoice) Performs automatic conflict resolution on a working copypath.voidDeprecated.usedoRevert(File[], SVNDepth, Collection)insteadvoiddoRevert(File[] paths, SVNDepth depth, Collection<String> changeLists) Restores the pristine version of working copypaths, effectively undoing any local mods.voidDeprecated.voiddoSetProperty(File path, String propName, SVNPropertyValue propValue, boolean force, boolean recursive, ISVNPropertyHandler handler) voiddoSetProperty(File path, String propName, SVNPropertyValue propValue, boolean skipChecks, SVNDepth depth, ISVNPropertyHandler handler, Collection<String> changeLists) SetspropNametopropValueonpath.voiddoSetProperty(File path, ISVNPropertyValueProvider propertyValueProvider, boolean skipChecks, SVNDepth depth, ISVNPropertyHandler handler, Collection<String> changeLists) Crawls the working copy atpathand callsISVNPropertyValueProvider.providePropertyValues(java.io.File, org.tmatesoft.svn.core.SVNProperties)to get properties to be change on each path being traverseddoSetProperty(SVNURL url, String propName, SVNPropertyValue propValue, SVNRevision baseRevision, String commitMessage, SVNProperties revisionProperties, boolean skipChecks, ISVNPropertyHandler handler) SetspropNametopropValueonpath.voiddoSetRevisionProperty(File path, SVNRevision revision, String propName, SVNPropertyValue propValue, boolean force, ISVNPropertyHandler handler) SetpropNametopropValueon revisionrevisionin the repository represented bypath.voiddoSetRevisionProperty(SVNURL url, SVNRevision revision, String propName, SVNPropertyValue propValue, boolean force, ISVNPropertyHandler handler) SetpropNametopropValueon revisionrevisionin the repository represented bypath.voiddoSetWCFormat(File directory, int format) Changes working copy format.voidUnlocks file items in a Working Copy as well as in a repository.voidUnlocks file items in a repository.Returns the specified commit handler (if set) being in use or a default one (DefaultSVNCommitHandler) if no special implementations of ISVNCommitHandler were previousely provided.protected voidbooleanvoidsetAddParameters(ISVNAddParameters addParameters) Sets custom add parameters to this client object.voidsetCommitHandler(ISVNCommitHandler handler) Sets an implementation of ISVNCommitHandler to the commit handler that will be used during commit operations to handle commit log messages.voidsetRevertMissingDirectories(boolean revertMissing) Methods inherited from class org.tmatesoft.svn.core.wc.SVNBasicClient
dontWC17Support, getDebugLog, getOperationsFactory, getOptions, getPathListHandler, getReposRoot, getReposRoot, isIgnoreExternals, isLeaveConflictsUnresolved, isWC17Supported, setDebugLog, setEventHandler, setEventPathPrefix, setIgnoreExternals, setLeaveConflictsUnresolved, setOptions, setPathListHandler
-
Field Details
-
DEFAULT_ADD_PARAMETERS
Default implementation ofISVNAddParameterswhichonInconsistentEOLs(File file)always returns theISVNAddParameters.REPORT_ERRORaction.- Since:
- 1.2
-
-
Constructor Details
-
SVNWCClient
Constructs and initializes an SVNWCClient object with the specified run-time configuration and authentication drivers. Ifoptionsis null, then this SVNWCClient will be using a default run-time configuration driver which takes client-side settings from the default SVN's run-time configuration area but is not able to change those settings (read more onISVNOptionsandSVNWCUtil). IfauthManageris null, then this SVNWCClient will be using a default authentication and network layers driver (seeSVNWCUtil.createDefaultAuthenticationManager()) which uses server-side settings and auth storage from the default SVN's run-time configuration area (or system properties if that area is not found).- Parameters:
authManager- an authentication and network layers driveroptions- a run-time configuration options driver
-
SVNWCClient
Constructs and initializes an SVNWCClient object with the specified run-time configuration and repository pool object. Ifoptionsis null, then this SVNWCClient will be using a default run-time configuration driver which takes client-side settings from the default SVN's run-time configuration area but is not able to change those settings (read more onISVNOptionsandSVNWCUtil). IfrepositoryPoolis null, thenSVNRepositoryFactorywill be used to createrepository access objects.- Parameters:
repositoryPool- a repository pool objectoptions- a run-time configuration options driver
-
SVNWCClient
-
-
Method Details
-
initDefaults
protected void initDefaults()- Overrides:
initDefaultsin classSVNBasicClient
-
setAddParameters
Sets custom add parameters to this client object.- Parameters:
addParameters- extra parameters for add operations- Since:
- 1.2
-
getCommitHandler
Returns the specified commit handler (if set) being in use or a default one (DefaultSVNCommitHandler) if no special implementations of ISVNCommitHandler were previousely provided.- Returns:
- the commit handler being in use or a default one
- See Also:
-
setCommitHandler
Sets an implementation of ISVNCommitHandler to the commit handler that will be used during commit operations to handle commit log messages. The handler will receive a clien's log message and items (represented as SVNCommitItem objects) that will be committed. Depending on implementor's aims the initial log message can be modified (or something else) and returned back. If using SVNWCClient without specifying any commit handler then a default one will be used -DefaultSVNCommitHandler.- Parameters:
handler- an implementor's handler that will be used to handle commit log messages- See Also:
-
setRevertMissingDirectories
public void setRevertMissingDirectories(boolean revertMissing) -
isRevertMissingDirectories
public boolean isRevertMissingDirectories() -
doGetFileContents
public void doGetFileContents(File path, SVNRevision pegRevision, SVNRevision revision, boolean expandKeywords, OutputStream dst) throws SVNException Outputs the content of file identified bypathandrevisionto the streamdst. The actual node revision selected is determined by the path as it exists inpegRevision. IfpegRevisionisSVNRevision.UNDEFINED, then it defaults toSVNRevision.WORKING. Ifrevision is one of: then the file contents are taken from the working copy file item (no network connection is needed). Otherwise the file item's contents are taken from the repository at a particular revision. - Parameters:
path- working copy pathpegRevision- revision in which the file item is first looked uprevision- target revisionexpandKeywords- if true then all keywords presenting in the file and listed in the file'sSVNProperty.KEYWORDSproperty (if set) will be substituted, otherwise notdst- the destination where the file contents will be written to- Throws:
SVNException- if one of the following is true:pathrefers to a directorypathdoes not existpathis not under version control
- See Also:
-
doGetFileContents
public void doGetFileContents(SVNURL url, SVNRevision pegRevision, SVNRevision revision, boolean expandKeywords, OutputStream dst) throws SVNException Outputs the content of file identified byurlandrevisionto the streamdst. The actual node revision selected is determined by the path as it exists inpegRevision. IfpegRevisionisSVNRevision.UNDEFINED, then it defaults toSVNRevision.HEAD.- Parameters:
url- a file item's repository locationpegRevision- a revision in which the file item is first looked uprevision- a target revisionexpandKeywords- if true then all keywords presenting in the file and listed in the file'sSVNProperty.KEYWORDSproperty (if set) will be substituted, otherwise notdst- the destination where the file contents will be written to- Throws:
SVNException- if one of the following is true:urlrefers to a directory- it's impossible to create temporary files (
createTempFile()fails) necessary for file translating
- See Also:
-
doCleanup
Cleans up a working copy. This method is equivalent to a call todoCleanup(path, false).- Parameters:
path- a WC path to start a cleanup from- Throws:
SVNException- if one of the following is true:pathdoes not existpath's parent directory is not under version control
- See Also:
-
doCleanup
Recursively cleans up the working copy, removing locks and resuming unfinished operations. If you ever get a "working copy locked" error, use this method to remove stale locks and get your working copy into a usable state again.This method operates only on working copies and does not open any network connection.
- Parameters:
path- a WC path to start a cleanup fromdeleteWCProperties- if true, removes DAV specific "svn:wc:" properties from the working copy- Throws:
SVNException- if one of the following is true:pathdoes not existpath's parent directory is not under version control
-
doCleanup
public void doCleanup(File path, boolean deleteWCProperties, boolean breakLocks, boolean vacuumPristines, boolean removeUnversionedItems, boolean removeIgnoredItems, boolean includeExternals) throws SVNException - Throws:
SVNException
-
doSetProperty
public void doSetProperty(File path, String propName, SVNPropertyValue propValue, boolean skipChecks, SVNDepth depth, ISVNPropertyHandler handler, Collection<String> changeLists) throws SVNException SetspropNametopropValueonpath. ApropValueof null will delete the property. IfdepthisSVNDepth.EMPTY, set the property onpathonly; ifSVNDepth.FILES, set it onpathand its file children (if any); ifSVNDepth.IMMEDIATES, onpathand all of its immediate children (both files and directories); ifSVNDepth.INFINITY, onpathand everything beneath it. IfpropNameis an svn-controlled property (i.e. prefixed with "svn:"), then the caller is responsible for ensuring that the value uses LF line-endings. IfskipChecksis true, this method does no validity checking. But ifskipChecksis false, andpropNameis not a valid property forpath, it throws an exception, either with an error codeSVNErrorCode.ILLEGAL_TARGET(if the property is not appropriate forpath), or withSVNErrorCode.BAD_MIME_TYPE(ifpropNameis "svn:mime-type", butpropValis not a valid mime-type).changeListsis a collection ofStringchangelist names, used as a restrictive filter on items whose properties are set; that is, don't set properties on any item unless it's a member of one of those changelists. Ifchangelistsis empty (or null), no changelist filtering occurs.This method operates only on working copies and does not open any network connection.
- Parameters:
path- working copy pathpropName- property namepropValue- property valueskipChecks- true to force the operation to run without validity checkingdepth- working copy tree depth to processhandler- a caller's property handlerchangeLists- changelist names- Throws:
SVNException-pathdoes not exist- exception with
SVNErrorCode.CLIENT_PROPERTY_NAMEerror code - ifpropNameis a revision property name or not a valid property name or not a regular property name (one starting with a "svn:entry" or "svn:wc" prefix)
- Since:
- 1.2, SVN 1.5
- See Also:
-
doSetProperty
public void doSetProperty(File path, ISVNPropertyValueProvider propertyValueProvider, boolean skipChecks, SVNDepth depth, ISVNPropertyHandler handler, Collection<String> changeLists) throws SVNException Crawls the working copy atpathand callsISVNPropertyValueProvider.providePropertyValues(java.io.File, org.tmatesoft.svn.core.SVNProperties)to get properties to be change on each path being traversed IfdepthisSVNDepth.EMPTY, change the properties onpathonly; ifSVNDepth.FILES, change the properties onpathand its file children (if any); ifSVNDepth.IMMEDIATES, onpathand all of its immediate children (both files and directories); ifSVNDepth.INFINITY, onpathand everything beneath it. IfskipChecksis true, this method does no validity checking of changed properties. But ifskipChecksis false, and changed property name is not a valid property forpath, it throws an exception, either with an error codeSVNErrorCode.ILLEGAL_TARGET(if the property is not appropriate forpath), or withSVNErrorCode.BAD_MIME_TYPE(if changed propery name is "svn:mime-type", but changed property value is not a valid mime-type).changeListsis a collection ofStringchangelist names, used as a restrictive filter on items whose properties are set; that is, don't set properties on any item unless it's a member of one of those changelists. Ifchangelistsis empty (or null), no changelist filtering occurs.This method operates only on working copies and does not open any network connection.
- Parameters:
path- working copy pathpropertyValueProvider- changed properties providerskipChecks- true to force the operation to run without validity checkingdepth- working copy tree depth to processhandler- a caller's property handlerchangeLists- changelist names- Throws:
SVNException-pathdoes not exist- exception with
SVNErrorCode.CLIENT_PROPERTY_NAMEerror code - if changed property name is a revision property name or not a valid property name or not a regular property name (one starting with a "svn:entry" or "svn:wc" prefix)
- Since:
- 1.2, SVN 1.5
- See Also:
-
doSetProperty
public SVNCommitInfo doSetProperty(SVNURL url, String propName, SVNPropertyValue propValue, SVNRevision baseRevision, String commitMessage, SVNProperties revisionProperties, boolean skipChecks, ISVNPropertyHandler handler) throws SVNException SetspropNametopropValueonpath. ApropValueof null will delete the property.baseRevisionmust not be null; in this case, the property will only be set if it has not changed sincebaseRevision. Theauthentication managerandcommit handler, either provided by a caller or default ones, will be used to immediately attempt to commit the property change in the repository. IfpropNameis an svn-controlled property (i.e. prefixed with "svn:"), then the caller is responsible for ensuring that the value uses LF line-endings. IfskipChecksis true, this method does no validity checking. But ifskipChecksis false, andpropNameis not a valid property forpath, it throws an exception, either with an error codeSVNErrorCode.ILLEGAL_TARGET(if the property is not appropriate forpath), or withSVNErrorCode.BAD_MIME_TYPE(ifpropNameis "svn:mime-type", butpropValis not a valid mime-type). If non-null,revisionPropertiesis anSVNPropertiesobject holding additional, custom revision properties (Stringnames mapped toStringvalues) to be set on the new revision in the event that this is a committing operation. This table cannot contain any standard Subversion properties.- Parameters:
url- versioned item urlpropName- property namepropValue- property valuebaseRevision- revision to change properties againstcommitMessage- commit log messagerevisionProperties- custom revision properties to setskipChecks- true to force the operation to run without validity checkinghandler- a caller's property handler- Returns:
- commit information if the commit succeeds
- Throws:
SVNException-urldoes not exist inbaseRevision- exception with
SVNErrorCode.CLIENT_PROPERTY_NAMEerror code - ifpropNameis a revision property name or not a valid property name or not a regular property name (one starting with an "svn:entry" or "svn:wc" prefix) -
exception with
SVNErrorCode.UNSUPPORTED_FEATUREerror code - ifpropNameis either equal toSVNProperty.EOL_STYLEorSVNProperty.KEYWORDSorSVNProperty.CHARSET
- Since:
- 1.2, SVN 1.5
- See Also:
-
doSetRevisionProperty
public void doSetRevisionProperty(File path, SVNRevision revision, String propName, SVNPropertyValue propValue, boolean force, ISVNPropertyHandler handler) throws SVNException SetpropNametopropValueon revisionrevisionin the repository represented bypath. This method simply obtains a url given a working path and callsdoSetRevisionProperty(SVNURL, SVNRevision, String, SVNPropertyValue, boolean, ISVNPropertyHandler)passing this url and the rest parameters.- Parameters:
path- working copy pathrevision- revision which properties are to be modifiedpropName- property namepropValue- property valueforce- if true allows newlines in the author propertyhandler- caller's property handler- Throws:
SVNException- if one of the following is true:- exception with
SVNErrorCode.CLIENT_PROPERTY_NAMEerror code - ifpropNameis invalid -
exceptions thrown by
doSetRevisionProperty(SVNURL, SVNRevision, String, SVNPropertyValue, boolean, ISVNPropertyHandler)
- exception with
-
doSetRevisionProperty
public void doSetRevisionProperty(SVNURL url, SVNRevision revision, String propName, SVNPropertyValue propValue, boolean force, ISVNPropertyHandler handler) throws SVNException SetpropNametopropValueon revisionrevisionin the repository represented bypath. ApropValueof null will delete the property. Theauthentication manager, either provided by a caller or a default one, will be used for authentication. IfpropNameis an svn-controlled property (i.e. prefixed with "svn:"), then the caller is responsible for ensuring that the value is UTF8-encoded and uses LF line-endings. Although this routine accepts a working copy path it doesn't affect the working copy at all; it's a pure network operation that changes an *unversioned* property attached to a revision. This can be used to tweak log messages, dates, authors, and the like. Be careful: it's a lossy operation.Also note that unless the administrator creates a pre-revprop-change hook in the repository, this feature will fail.
- Parameters:
url- repository URLrevision- revision which properties are to be modifiedpropName- property namepropValue- property valueforce- if true allows newlines in the author propertyhandler- caller's property handler- Throws:
SVNException- if one of the following is true:- the operation can not be performed without forcing
-
propNameis either invalid or not a regular property name (one starting with an "svn:entry" or "svn:wc" prefix)
- See Also:
-
doGetProperty
public SVNPropertyData doGetProperty(File path, String propName, SVNRevision pegRevision, SVNRevision revision) throws SVNException Gets the value of the propertypropNameforpath. This method simply creates an implementation ofISVNPropertyHandlerwhich stores the value only forpathwhich is then used in the following call todoGetProperty(path, propName, pegRevision, revision, SVNDepth.EMPTY, handler, null).- Parameters:
path- a WC item's pathpropName- an item's property name; if it's null then all the item's properties will be retrieved but only the first of them returnedpegRevision- a revision in which the item is first looked uprevision- a target revision;- Returns:
- the item's property
- Throws:
SVNException- if one of the following is true:propNamestarts with thesvn:wc:prefixpathis not under version control
- See Also:
-
doGetProperty
public SVNPropertyData doGetProperty(SVNURL url, String propName, SVNRevision pegRevision, SVNRevision revision) throws SVNException Gets the value of the propertypropNameforurl. This method simply creates an implementation ofISVNPropertyHandlerwhich stores the value only forpathwhich is then used in the following call todoGetProperty(url, propName, pegRevision, revision, SVNDepth.EMPTY, handler).- Parameters:
url- an item's repository locationpropName- an item's property name; if it's null then all the item's properties will be retrieved but only the first of them returnedpegRevision- a revision in which the item is first looked uprevision- a target revision;- Returns:
- the item's property
- Throws:
SVNException- if one of the following is true:propNamestarts with thesvn:wc:prefixpathis not under version control
- See Also:
-
doGetProperty
public void doGetProperty(File path, String propName, SVNRevision pegRevision, SVNRevision revision, boolean recursive, ISVNPropertyHandler handler) throws SVNException Deprecated.Gets an item's versioned property and passes it to a provided property handler. It's possible to get either a local property (from a Working Copy) or a remote one (located in a repository). Ifrevision is one of: then the result is a WC item's property. Otherwise the property is taken from a repository (using the item's URL). - Parameters:
path- a WC item's pathpropName- an item's property name; if it's null then all the item's properties will be retrieved and passed tohandlerfor processingpegRevision- a revision in which the item is first looked uprevision- a target revision;recursive- true to descend recursivelyhandler- a caller's property handler- Throws:
SVNException- if one of the following is true:propNamestarts with thesvn:wc:prefixpathis not under version control
-
doGetProperty
public void doGetProperty(File path, String propName, SVNRevision pegRevision, SVNRevision revision, SVNDepth depth, ISVNPropertyHandler handler, Collection<String> changeLists) throws SVNException Invokeshandleron paths covered bydepthstarting with the specifiedpath. If bothrevision and pegRevisionare ones of: then this method gets properties from the working copy without connecting to the repository. Otherwise properties are taken from the repository (using the item's URL). The actual node revision selected is determined by the path as it exists inpegRevision. IfpegRevisionisSVNRevision.UNDEFINED, then it defaults toSVNRevision.WORKING. IfdepthisSVNDepth.EMPTY, fetch the property frompathonly; ifSVNDepth.FILES, fetch frompathand its file children (if any); ifSVNDepth.IMMEDIATES, frompathand all of its immediate children (both files and directories); ifSVNDepth.INFINITY, frompathand everything beneath it.changeListsis a collection ofString changelist names, used as a restrictive filter on items whose properties are set; that is, don't set properties on any item unless it's a member of one of those changelists. IfchangeListsis empty (or null), no changelist filtering occurs.- Parameters:
path- a WC item's pathpropName- an item's property name; if it's null then all the item's properties will be retrieved and passed tohandlerfor processingpegRevision- a revision in which the item is first looked uprevision- a target revisiondepth- tree depthhandler- a caller's property handlerchangeLists- collection of changelist names- Throws:
SVNException- if one of the following is true:propNamestarts with theSVNProperty.SVN_WC_PREFIXprefixpathis not under version control
- Since:
- 1.2, SVN 1.5
-
doGetProperty
public void doGetProperty(SVNURL url, String propName, SVNRevision pegRevision, SVNRevision revision, boolean recursive, ISVNPropertyHandler handler) throws SVNException Deprecated.Gets an item's versioned property from a repository and passes it to a provided property handler. This method is useful when having no Working Copy at all.- Parameters:
url- an item's repository locationpropName- an item's property name; if it's null then all the item's properties will be retrieved and passed tohandlerfor processingpegRevision- a revision in which the item is first looked uprevision- a target revisionrecursive- true to descend recursivelyhandler- a caller's property handler- Throws:
SVNException- ifpropNamestarts with thesvn:wc:prefix
-
doGetProperty
public void doGetProperty(SVNURL url, String propName, SVNRevision pegRevision, SVNRevision revision, SVNDepth depth, ISVNPropertyHandler handler) throws SVNException Invokeshandleron paths covered bydepthstarting with the specifiedpath. IfisSVNRevision.UNDEFINEDthen get properties from the repository head. Else get the properties as ofrevision. The actual node revision selected is determined by the path as it exists inpegRevision. IfpegRevisionisSVNRevision.UNDEFINED, then it defaults toSVNRevision.HEAD. IfdepthisSVNDepth.EMPTY, fetch the property frompathonly; ifSVNDepth.FILES, fetch frompathand its file children (if any); ifSVNDepth.IMMEDIATES, frompathand all of its immediate children (both files and directories); ifSVNDepth.INFINITY, frompathand everything beneath it.- Parameters:
url- versioned item urlpropName- an item's property name; if it's null then all the item's properties will be retrieved and passed tohandlerfor processingpegRevision- a revision in which the item is first looked uprevision- a target revisiondepth- tree depthhandler- a caller's property handler- Throws:
SVNException- if one of the following is true:propNamestarts with theSVNProperty.SVN_WC_PREFIXprefixpathis not under version control
- Since:
- 1.2, SVN 1.5
-
doGetRevisionProperty
public long doGetRevisionProperty(File path, String propName, SVNRevision revision, ISVNPropertyHandler handler) throws SVNException Gets an unversioned revision property from a repository (getting a repository URL from a Working Copy) and passes it to a provided property handler.- Parameters:
path- a local Working Copy item which repository location is used to connect to a repositorypropName- a revision property name; if this parameter is null then all the revision properties will be retrieved and passed tohandlerfor processingrevision- a revision which property is to be retrievedhandler- a caller's property handler- Throws:
SVNException- if one of the following is true:revisionis invalidpropNamestarts with thesvn:wc:prefix
- See Also:
-
doGetRevisionProperty
public long doGetRevisionProperty(SVNURL url, String propName, SVNRevision revision, ISVNPropertyHandler handler) throws SVNException Gets an unversioned revision property from a repository and passes it to a provided property handler.- Parameters:
url- a URL pointing to a repository location which revision property is to be gotpropName- a revision property name; if this parameter is null then all the revision properties will be retrieved and passed tohandlerfor processingrevision- a revision which property is to be retrievedhandler- a caller's property handler- Returns:
- actual revision number to which
revisionis resolved - Throws:
SVNException- if one of the following is true:revisionis invalidpropNamestarts with thesvn:wc:prefix
- See Also:
-
doDelete
Schedules a Working Copy item for deletion. This method is equivalent todoDelete(path, force, true, dryRun).- Parameters:
path- a WC item to be deletedforce- true to force the operation to rundryRun- true only to try the delete operation without actual deleting- Throws:
SVNException- if one of the following is true:pathis not under version control- can not delete
pathwithout forcing
- See Also:
-
doDelete
public void doDelete(File path, boolean force, boolean deleteFiles, boolean dryRun) throws SVNException Schedules a Working Copy item for deletion. This method allows to choose - whether file item(s) are to be deleted from the filesystem or not. Another version of thedoDelete()method is similar to the corresponding SVN client's command -'svn delete'as it always deletes files from the filesystem. This method deletes only local working copy paths without connecting to the repository.- Parameters:
path- a WC item to be deletedforce- true to force the operation to rundeleteFiles- if true then files will be scheduled for deletion as well as deleted from the filesystem, otherwise files will be only scheduled for deletion and still be present in the filesystemdryRun- true only to try the delete operation without actual deleting- Throws:
SVNException- if one of the following is true:pathis not under version control- can
not delete
pathwithout forcing
-
doAdd
public void doAdd(File path, boolean force, boolean mkdir, boolean climbUnversionedParents, boolean recursive) throws SVNException Deprecated.Schedules an unversioned item for addition to a repository thus putting it under version control. To create and add to version control a new directory, setmkdirto true. Calling this method is equivalent todoAdd(path, force, mkdir, climbUnversionedParents, recursive, false).- Parameters:
path- a path to be put under version control (will be added to a repository in next commit)force- when true forces the operation to run on already versioned files or directories without reporting error. When ran recursively, all unversioned files and directories in a tree will be scheduled for addition.mkdir- if true - creates a new directory and schedules it for additionclimbUnversionedParents- if true andpathis located in an unversioned parent directory then the parent will be automatically scheduled for addition, toorecursive- true to descend recursively (relevant for directories)- Throws:
SVNException- if one of the following is true:pathdoesn't belong to a Working Copy-
pathdoesn't exist andmkdiris false pathis the root directory of the Working Copy
-
doAdd
public void doAdd(File path, boolean force, boolean mkdir, boolean climbUnversionedParents, boolean recursive, boolean includeIgnored) throws SVNException Deprecated.Schedules an unversioned item for addition to a repository thus putting it under version control. To create and add to version control a new directory, setmkdirto true.- Parameters:
path- a path to be put under version control (will be added to a repository in next commit)force- when true forces the operation to run on already versioned files or directories without reporting error. When ran recursively, all unversioned files and directories in a tree will be scheduled for addition.mkdir- if true - creates a new directory and schedules it for additionclimbUnversionedParents- if true andpathis located in an unversioned parent directory then the parent will be automatically scheduled for addition, toorecursive- true to descend recursively (relevant for directories)includeIgnored- controls whether ignored items must be also added- Throws:
SVNException- if one of the following is true:pathdoesn't belong to a Working Copy-
pathdoesn't exist andmkdiris false pathis the root directory of the Working Copy
- Since:
- 1.1
-
doAdd
public void doAdd(File path, boolean force, boolean mkdir, boolean climbUnversionedParents, SVNDepth depth, boolean includeIgnored, boolean makeParents) throws SVNException Schedules a working copypathfor addition to the repository. IfdepthisSVNDepth.EMPTY, adds justpathand nothing below it. IfSVNDepth.FILES, addspathand any file children ofpath. IfSVNDepth.IMMEDIATES, addspath, any file children, and any immediate subdirectories (but nothing underneath those subdirectories). IfSVNDepth.INFINITY, addspathand everything under it fully recursively.path's parent must be under revision control already (unlessmakeParentsis true), butpathis not. Ifforceis set,pathis a directory,depthisSVNDepth.INFINITY, then schedules for addition unversioned files and directories scattered deep within a versioned tree. IfincludeIgnoredis false, doesn't add files or directories that match ignore patterns. IfmakeParentsis true, recurse uppath's directory and look for a versioned directory. If found, add all intermediate paths between it andpath. Important: this is a *scheduling* operation. No changes will happen to the repository until a commit occurs. This scheduling can be removed with a call todoRevert(File[], SVNDepth, Collection).- Parameters:
path- working copy pathforce- if true, this method does not throw exceptions on already-versioned itemsmkdir- if true, create a directory also atpathclimbUnversionedParents- not used; make use ofmakeParentsinsteaddepth- tree depthincludeIgnored- if true, does not apply ignore patterns to paths being addedmakeParents- if true, climb upper and schedule also all unversioned paths in the way- Throws:
SVNException--
exception with
SVNErrorCode.ENTRY_EXISTSerror code - ifforceis not set andpathis already under version exception withSVNErrorCode.CLIENT_NO_VERSIONED_PARENTerror code - ifmakeParentsis true but no unversioned paths stepping upper frompathare found- Since:
- 1.2, SVN 1.5
-
doAdd
public void doAdd(File[] paths, boolean force, boolean mkdir, boolean climbUnversionedParents, SVNDepth depth, boolean depthIsSticky, boolean includeIgnored, boolean makeParents) throws SVNException Schedules working copypathsfor addition to the repository. IfdepthisSVNDepth.EMPTY, adds justpathsand nothing below it. IfSVNDepth.FILES, addspathsand any file children ofpaths. IfSVNDepth.IMMEDIATES, addspaths, any file children, and any immediate subdirectories (but nothing underneath those subdirectories). IfSVNDepth.INFINITY, addspathsand everything under it fully recursively.paths' parent must be under revision control already (unlessmakeParentsis true), butpathsare not. Ifforceis set, path is a directory,depthisSVNDepth.INFINITY, then schedules for addition unversioned files and directories scattered deep within a versioned tree. IfincludeIgnoredis false, doesn't add files or directories that match ignore patterns. IfmakeParentsis true, recurse up path's directory and look for a versioned directory. If found, add all intermediate paths between it and the path. Important: this is a *scheduling* operation. No changes will happen to the repository until a commit occurs. This scheduling can be removed with a call todoRevert(File[], SVNDepth, Collection).- Parameters:
paths- working copy paths to addforce- if true, this method does not throw exceptions on already-versioned itemsmkdir- if true, create a directory also atpathclimbUnversionedParents- not used; make use ofmakeParentsinsteaddepth- tree depthdepthIsSticky- if depth should be recorded to the working copyincludeIgnored- if true, does not apply ignore patterns to paths being addedmakeParents- if true, climb upper and schedule also all unversioned paths in the way- Throws:
SVNException--
exception with
SVNErrorCode.ENTRY_EXISTSerror code - ifforceis not set and a path is already under version exception withSVNErrorCode.CLIENT_NO_VERSIONED_PARENTerror code - ifmakeParentsis true but no unversioned paths stepping upper from a path are found- Since:
- 1.3
-
doAdd
public void doAdd(File[] paths, boolean force, boolean mkdir, boolean climbUnversionedParents, SVNDepth depth, boolean depthIsSticky, boolean includeIgnored, boolean makeParents, boolean applyAutoProperties) throws SVNException Schedules working copypathsfor addition to the repository. IfdepthisSVNDepth.EMPTY, adds justpathsand nothing below it. IfSVNDepth.FILES, addspathsand any file children ofpaths. IfSVNDepth.IMMEDIATES, addspaths, any file children, and any immediate subdirectories (but nothing underneath those subdirectories). IfSVNDepth.INFINITY, addspathsand everything under it fully recursively.paths' parent must be under revision control already (unlessmakeParentsis true), butpathsare not. Ifforceis set, path is a directory,depthisSVNDepth.INFINITY, then schedules for addition unversioned files and directories scattered deep within a versioned tree. IfincludeIgnoredis false, doesn't add files or directories that match ignore patterns. IfmakeParentsis true, recurse up path's directory and look for a versioned directory. If found, add all intermediate paths between it and the path. Important: this is a *scheduling* operation. No changes will happen to the repository until a commit occurs. This scheduling can be removed with a call todoRevert(File[], SVNDepth, Collection).- Parameters:
paths- working copy paths to addforce- if true, this method does not throw exceptions on already-versioned itemsmkdir- if true, create a directory also atpathclimbUnversionedParents- not used; make use ofmakeParentsinsteaddepth- tree depthdepthIsSticky- if depth should be recorded to the working copyincludeIgnored- if true, does not apply ignore patterns to paths being addedmakeParents- if true, climb upper and schedule also all unversioned paths in the wayapplyAutoProperties- if true, applies auto-properties on file addition otherwise auto-properties application is disabled- Throws:
SVNException--
exception with
SVNErrorCode.ENTRY_EXISTSerror code - ifforceis not set and a path is already under version exception withSVNErrorCode.CLIENT_NO_VERSIONED_PARENTerror code - ifmakeParentsis true but no unversioned paths stepping upper from a path are found- Since:
- 1.8
-
doAdd
public void doAdd(File path, boolean force, boolean mkdir, boolean climbUnversionedParents, SVNDepth depth, boolean depthIsSticky, boolean includeIgnored, boolean makeParents) throws SVNException Schedules a working copypathfor addition to the repository. IfdepthisSVNDepth.EMPTY, adds justpathand nothing below it. IfSVNDepth.FILES, addspathand any file children ofpath. IfSVNDepth.IMMEDIATES, addspath, any file children, and any immediate subdirectories (but nothing underneath those subdirectories). IfSVNDepth.INFINITY, addspathand everything under it fully recursively.path's parent must be under revision control already (unlessmakeParentsis true), butpathis not. Ifforceis set,pathis a directory,depthisSVNDepth.INFINITY, then schedules for addition unversioned files and directories scattered deep within a versioned tree. IfincludeIgnoredis false, doesn't add files or directories that match ignore patterns. IfmakeParentsis true, recurse uppath's directory and look for a versioned directory. If found, add all intermediate paths between it andpath. Important: this is a *scheduling* operation. No changes will happen to the repository until a commit occurs. This scheduling can be removed with a call todoRevert(File[], SVNDepth, Collection).- Parameters:
path- working copy pathforce- if true, this method does not throw exceptions on already-versioned itemsmkdir- if true, create a directory also atpathclimbUnversionedParents- not used; make use ofmakeParentsinsteaddepth- tree depthdepthIsSticky- if depth should be recorded to the working copyincludeIgnored- if true, does not apply ignore patterns to paths being addedmakeParents- if true, climb upper and schedule also all unversioned paths in the way- Throws:
SVNException--
exception with
SVNErrorCode.ENTRY_EXISTSerror code - ifforceis not set andpathis already under version exception withSVNErrorCode.CLIENT_NO_VERSIONED_PARENTerror code - ifmakeParentsis true but no unversioned paths stepping upper frompathare found- Since:
- 1.3
-
doMarkReplaced
Schedulespathas being replaced. This method does not perform any deletion\addition in the filesysem nor does it require a connection to the repository. It just marks the currentpathitem as being replaced.- Parameters:
path- working copy path to mark as- Throws:
SVNException- Since:
- 1.2
-
doRevert
Deprecated.Reverts all local changes made to a Working Copy item(s) thus bringing it to a 'pristine' state.- Parameters:
path- a WC path to perform a revert onrecursive- true to descend recursively (relevant for directories)- Throws:
SVNException- if one of the following is true:pathis not under version control- when trying to revert an addition of a directory from within the directory itself
- See Also:
-
doRevert
Deprecated.usedoRevert(File[], SVNDepth, Collection)insteadReverts all local changes made to a Working Copy item(s) thus bringing it to a 'pristine' state.- Parameters:
paths- a WC paths to perform a revert onrecursive- true to descend recursively (relevant for directories)- Throws:
SVNException- if one of the following is true:pathis not under version control- when trying to revert an addition of a directory from within the directory itself
ISVNEventHandlerinstance to get information on whether certain path was reverted or not.
-
doRevert
public void doRevert(File[] paths, SVNDepth depth, Collection<String> changeLists) throws SVNException Restores the pristine version of working copypaths, effectively undoing any local mods. For each path inpaths, 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 (or null), 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.- Parameters:
paths- working copy paths to revertdepth- tree depthchangeLists- collection with changelist names- Throws:
SVNException- Since:
- 1.2, SVN 1.5
-
doResolve
Deprecated.usedoResolve(File, SVNDepth, SVNConflictChoice)insteadResolves a 'conflicted' state on a Working Copy item.- Parameters:
path- a WC item to be resolvedrecursive- true to descend recursively (relevant for directories) - this will resolve the entire tree- Throws:
SVNException- ifpathis not under version control
-
doResolve
public void doResolve(File path, SVNDepth depth, SVNConflictChoice conflictChoice) throws SVNException Performs automatic conflict resolution on a working copypath. IfdepthisSVNDepth.EMPTY, acts only onpath; ifSVNDepth.FILES, resolvespathand its conflicted file children (if any); ifSVNDepth.IMMEDIATES, resolvespathand all its immediate conflicted children (both files and directories, if any); ifSVNDepth.INFINITY, resolvespathand every conflicted file or directory anywhere beneath it. IfconflictChoiceisSVNConflictChoice.BASE, resolves the conflict with the old file contents; ifSVNConflictChoice.MINE_FULL, uses the original working contents; ifSVNConflictChoice.THEIRS_FULL, the new contents; and ifSVNConflictChoice.MERGED, doesn't change the contents at all, just removes the conflict status, which is the pre-1.2 (pre-SVN 1.5) behavior.SVNConflictChoice.THEIRS_CONFLICTandSVNConflictChoice.MINE_CONFLICTare not legal for binary files or properties. Ifpathis not in a state of conflict to begin with, does nothing. Ifpath's conflict state is removed and caller'sISVNEntryHandleris not null, then anSVNEventAction.RESOLVEDevent is dispatched to the handler. This is equivalent to callingdoResolve(path, depth, true, true, conflictChoice).- Parameters:
path- working copy pathdepth- tree depthconflictChoice- choice object for making decision while resolving- Throws:
SVNException- Since:
- 1.2, SVN 1.5
-
doResolve
public void doResolve(File path, SVNDepth depth, boolean resolveContents, boolean resolveProperties, SVNConflictChoice conflictChoice) throws SVNException Performs automatic conflict resolution on a working copypath. IfdepthisSVNDepth.EMPTY, acts only onpath; ifSVNDepth.FILES, resolvespathand its conflicted file children (if any); ifSVNDepth.IMMEDIATES, resolvespathand all its immediate conflicted children (both files and directories, if any); ifSVNDepth.INFINITY, resolvespathand every conflicted file or directory anywhere beneath it. IfconflictChoiceisSVNConflictChoice.BASE, resolves the conflict with the old file contents; ifSVNConflictChoice.MINE_FULL, uses the original working contents; ifSVNConflictChoice.THEIRS_FULL, the new contents; and ifSVNConflictChoice.MERGED, doesn't change the contents at all, just removes the conflict status, which is the pre-1.2 (pre-SVN 1.5) behavior.SVNConflictChoice.THEIRS_CONFLICTandSVNConflictChoice.MINE_CONFLICTare not legal for binary files or properties. Ifpathis not in a state of conflict to begin with, does nothing. Ifpath's conflict state is removed and caller'sISVNEntryHandleris not null, then anSVNEventAction.RESOLVEDevent is dispatched to the handler.- Parameters:
path- working copy pathdepth- tree depthresolveContents- resolve content conflictresolveProperties- resolve property conflictconflictChoice- choice object for making decision while resolving- Throws:
SVNException- Since:
- 1.2, SVN 1.5
-
doResolve
public void doResolve(File path, SVNDepth depth, boolean resolveContents, boolean resolveProperties, boolean resolveTree, SVNConflictChoice conflictChoice) throws SVNException Performs automatic conflict resolution on a working copypath. IfdepthisSVNDepth.EMPTY, acts only onpath; ifSVNDepth.FILES, resolvespathand its conflicted file children (if any); ifSVNDepth.IMMEDIATES, resolvespathand all its immediate conflicted children (both files and directories, if any); ifSVNDepth.INFINITY, resolvespathand every conflicted file or directory anywhere beneath it. IfconflictChoiceisSVNConflictChoice.BASE, resolves the conflict with the old file contents; ifSVNConflictChoice.MINE_FULL, uses the original working contents; ifSVNConflictChoice.THEIRS_FULL, the new contents; and ifSVNConflictChoice.MERGED, doesn't change the contents at all, just removes the conflict status, which is the pre-1.2 (pre-SVN 1.5) behavior.SVNConflictChoice.THEIRS_CONFLICTandSVNConflictChoice.MINE_CONFLICTare not legal for binary files or properties. Ifpathis not in a state of conflict to begin with, does nothing. Ifpath's conflict state is removed and caller'sISVNEntryHandleris not null, then anSVNEventAction.RESOLVEDevent is dispatched to the handler.- Parameters:
path- working copy pathdepth- tree depthresolveContents- resolve content conflictresolveProperties- resolve property conflictresolveTree- n resolve any tree conlictsconflictChoice- choice object for making decision while resolving- Throws:
SVNException- Since:
- 1.3, SVN 1.6
-
doLock
Locks file items in a Working Copy as well as in a repository so that no other user can commit changes to them.- Parameters:
paths- an array of local WC file paths that should be lockedstealLock- if true then all existing locks on the specifiedpathswill be "stolen"lockMessage- an optional lock comment- Throws:
SVNException- if one of the following is true:- a path to be locked is not under version control
- can not obtain a URL of a local path to lock it in the repository - there's no such entry
pathsto be locked belong to different repositories
- See Also:
-
doLock
Locks file items in a repository so that no other user can commit changes to them.- Parameters:
urls- an array of URLs to be lockedstealLock- if true then all existing locks on the specifiedurlswill be "stolen"lockMessage- an optional lock comment- Throws:
SVNException- See Also:
-
doUnlock
Unlocks file items in a Working Copy as well as in a repository.- Parameters:
paths- an array of local WC file paths that should be unlockedbreakLock- if true and there are locks that belong to different users then those locks will be also unlocked - that is "broken"- Throws:
SVNException- if one of the following is true:- a path is not under version control
- can not obtain a URL of a local path to unlock it in the repository - there's no such entry
- if a path is not locked in the Working Copy and
breakLockis false pathsto be unlocked belong to different repositories
- See Also:
-
doUnlock
Unlocks file items in a repository.- Parameters:
urls- an array of URLs that should be unlockedbreakLock- if true and there are locks that belong to different users then those locks will be also unlocked - that is "broken"- Throws:
SVNException- See Also:
-
doInfo
public void doInfo(File path, SVNRevision revision, boolean recursive, ISVNInfoHandler handler) throws SVNException Deprecated.Collects information about Working Copy item(s) and passes it to an info handler. Ifrevisionis valid and not local, then information will be collected on remote items (that is taken from a repository). Otherwise information is gathered on local items not accessing a repository.- Parameters:
path- a WC item on which info should be obtainedrevision- a target revisionrecursive- true to descend recursively (relevant for directories)handler- a caller's info handler- Throws:
SVNException- if one of the following is true:pathis not under version control- can
not obtain a URL corresponding to
pathto get its information from the repository - there's no such entry - if a remote info:
pathis an item that does not exist in the specifiedrevision
-
doInfo
public void doInfo(File path, SVNRevision pegRevision, SVNRevision revision, boolean recursive, ISVNInfoHandler handler) throws SVNException Deprecated.Collects information about Working Copy item(s) and passes it to an info handler. Ifrevisioninvalid input: '&'pegRevisionare valid and not local, then information will be collected on remote items (that is taken from a repository). Otherwise information is gathered on local items not accessing a repository.- Parameters:
path- a WC item on which info should be obtainedpegRevision- a revision in whichpathis first looked uprevision- a target revisionrecursive- true to descend recursively (relevant for directories)handler- a caller's info handler- Throws:
SVNException- if one of the following is true:pathis not under version control- can
not obtain a URL corresponding to
pathto get its information from the repository - there's no such entry - if a remote info:
pathis an item that does not exist in the specifiedrevision
-
doInfo
public void doInfo(File path, SVNRevision pegRevision, SVNRevision revision, SVNDepth depth, Collection<String> changeLists, ISVNInfoHandler handler) throws SVNException Invokeshandlerto return information aboutpathinrevision. The information returned is system-generated metadata, not the sort of "property" metadata created by users. SeeSVNInfo. If both revision arguments are either null orlocal, orinvalid, then information will be pulled solely from the working copy; no network connections will be made. Otherwise, information will be pulled from a repository. The actual node revision selected is determined by thepathas it exists inpegRevision. IfpegRevisionisSVNRevision.UNDEFINED, then it defaults toSVNRevision.WORKING. Ifpathis a file, just invokeshandleron it. If it is a directory, then descends according todepth. IfdepthisSVNDepth.EMPTY, invokeshandleronpathand nothing else; ifSVNDepth.FILES, onpathand its immediate file children; ifSVNDepth.IMMEDIATES, the preceding plus on each immediate subdirectory; ifSVNDepth.INFINITY, then recurses fully, invokinghandleronpathand everything beneath it.changeListsis a collection ofStringchangelist names, used as a restrictive filter on items whose info is reported; that is, doesn't report info about any item unless it's a member of one of those changelists. IfchangeListsis empty (or null), no changelist filtering occurs.- Parameters:
path- a WC item on which info should be obtainedpegRevision- a revision in whichpathis first looked uprevision- a target revisiondepth- tree depthchangeLists- collection changelist nameshandler- caller's info handler- Throws:
SVNException- Since:
- 1.2, SVN 1.5
-
doInfo
public void doInfo(SVNURL url, SVNRevision pegRevision, SVNRevision revision, boolean recursive, ISVNInfoHandler handler) throws SVNException Deprecated.Collects information about item(s) in a repository and passes it to an info handler.- Parameters:
url- a URL of an item which information is to be obtained and processedpegRevision- a revision in which the item is first looked uprevision- a target revisionrecursive- true to descend recursively (relevant for directories)handler- a caller's info handler- Throws:
SVNException- ifurlis an item that does not exist in the specifiedrevision
-
doInfo
public void doInfo(SVNURL url, SVNRevision pegRevision, SVNRevision revision, SVNDepth depth, ISVNInfoHandler handler) throws SVNException Invokeshandlerto return information abouturlinrevision. The information returned is system-generated metadata, not the sort of "property" metadata created by users. SeeSVNInfo. Ifrevisionargument is either null orinvalid, it defaults toSVNRevision.HEAD. IfrevisionisSVNRevision.PREVIOUS(or some other kind that requires a local path), an error will be returned, because the desired revision cannot be determined. IfpegRevisionargument is either null orinvalid, it defaults torevision. Information will be pulled from the repository. The actual node revision selected is determined by theurlas it exists inpegRevision. IfpegRevisionisSVNRevision.UNDEFINED, then it defaults toSVNRevision.WORKING. Ifurlis a file, just invokeshandleron it. If it is a directory, then descends according todepth. IfdepthisSVNDepth.EMPTY, invokeshandleronurland nothing else; ifSVNDepth.FILES, onurland its immediate file children; ifSVNDepth.IMMEDIATES, the preceding plus on each immediate subdirectory; ifSVNDepth.INFINITY, then recurses fully, invokinghandleronurland everything beneath it.- Parameters:
url- versioned item urlpegRevision- revision in whichpathis first looked uprevision- target revisiondepth- tree depthhandler- caller's info handler- Throws:
SVNException- Since:
- 1.2, SVN 1.5
-
doGetWorkingCopyID
Returns the current Working Copy min- and max- revisions as well as changes and switch status within a single string. This method is the same asdoGetWorkingCopyID(path, trailURL, false).- Parameters:
path- a local pathtrailURL- optional: if not null specifies the name of the item that should be met in the URL corresponding to the repository location of thepath; if that URL ends with something different than this optional parameter - the Working Copy will be considered "switched"- Returns:
- brief info on the Working Copy or the string "exported" if
pathis a clean directory - Throws:
SVNException- ifpathis neither versioned nor even exported- See Also:
-
doGetWorkingCopyID
Returns the current Working Copy min- and max- revisions as well as changes and switch status within a single string. A return string has a form of"minR[:maxR][M][S]"where:minR- is the smallest revision number met in the Working CopymaxR- is the biggest revision number met in the Working Copy; appears only if there are different revision in the Working CopyM- appears only if there're local edits to the Working Copy - that means 'Modified'S- appears only if the Working Copy is switched against a different URL
pathis a directory - this method recursively descends into the Working Copy, collects and processes local information. This method operates on local working copies only without accessing a repository.- Parameters:
path- a local pathtrailURL- optional: if not null specifies the name of the item that should be met in the URL corresponding to the repository location of thepath; if that URL ends with something different than this optional parameter - the Working Copy will be considered "switched"committed- if true committed (last chaned) revisions instead of working copy ones are reported- Returns:
- brief info on the Working Copy or the string "exported" if
pathis a clean directory - Throws:
SVNException- ifpathis neither versioned nor even exported- Since:
- 1.2
-
doInfo
Collects and returns information on a single Working Copy item. This method is the same asdoInfo(path, SVNRevision.UNDEFINED, revision, SVNDepth.EMPTY, null, handler)wherehandlerjust storesSVNInfofor thepathand then returns it to the caller.- Parameters:
path- a WC item on which info should be obtainedrevision- a target revision- Returns:
- collected info
- Throws:
SVNException- if one of the following is true:pathis not under version control- can
not obtain a URL corresponding to
pathto get its information from the repository - there's no such entry - if a remote info:
pathis an item that does not exist in the specifiedrevision
- See Also:
-
doInfo
public SVNInfo doInfo(SVNURL url, SVNRevision pegRevision, SVNRevision revision) throws SVNException Collects and returns information on a single item in a repository. This method is the same asdoInfo(url, pegRevision, revision, SVNDepth.EMPTY, handler)wherehandlerjust storesSVNInfofor theurl.- Parameters:
url- a URL of an item which information is to be obtainedpegRevision- a revision in which the item is first looked uprevision- a target revision- Returns:
- collected info
- Throws:
SVNException- ifurlis an item that does not exist in the specifiedrevision- See Also:
-
doCleanupWCProperties
Recursively removes all DAV-specific "svn:wc:" properties from thedirectoryand beneath.This method does not connect to a repository, it's a local operation only. Nor does it change any user's versioned data. Changes are made only in administrative version control files.
- Parameters:
directory- working copy path- Throws:
SVNException- Since:
- 1.2
-
doSetWCFormat
Changes working copy format. This method may be used to upgrade\downgrade working copy formats.If externals are not
ignoredthen external working copies are also converted to the new working copyformat.This method does not connect to a repository, it's a local operation only. Nor does it change any user's versioned data. Changes are made only in administrative version control files.
Once upgraded to 1.7 format (12) working copy format could not be downgraded.
- Parameters:
directory- working copy directoryformat- format to set, supported formats are: 12 (SVN 1.7), 10 (SVN 1.6), 9 (SVN 1.5), 8 (SVN 1.4) and 4 (SVN 1.2)- Throws:
SVNException- Since:
- 1.2
-
doSetProperty
public void doSetProperty(File path, String propName, SVNPropertyValue propValue, boolean force, boolean recursive, ISVNPropertyHandler handler) throws SVNException Deprecated.This method is deprecated.- Parameters:
path- a WC item which properties are to be modifiedpropName- a property namepropValue- a property valueforce- true to force the operation to runrecursive- true to descend recursivelyhandler- a caller's property handler- Throws:
SVNException- if one of the following is true:propNameis a revision propertypropNamestarts with thesvn:wc:prefix
-
doAdd(File, boolean, boolean, boolean, SVNDepth, boolean, boolean)instead