summaryrefslogtreecommitdiff
path: root/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java
diff options
context:
space:
mode:
Diffstat (limited to 'subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java')
-rw-r--r--subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java541
1 files changed, 515 insertions, 26 deletions
diff --git a/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java b/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java
index 2ffe446..c1cebc8 100644
--- a/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java
+++ b/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java
@@ -51,6 +51,11 @@ public interface ISVNClient
public Version getVersion();
/**
+ * @return Runtime version information about the loaded libsvn_client.
+ */
+ public RuntimeVersion getRuntimeVersion();
+
+ /**
* @return Extended version information about the underlying
* native libraries and operating system.
*/
@@ -74,16 +79,40 @@ public interface ISVNClient
public boolean isAdminDirectory(String name);
/**
- * List a directory or file of the working copy.
+ * Return the status of the working copy and maybe repository.
*
* @param path Path to explore.
* @param depth How deep to recurse into subdirectories.
* @param onServer Request status information from server.
+ * @param onDisk Check the working copy for local modifications.
+ * A value of <code>false</code> only
+ * has effect when <code>onServer</code> is
+ * <code>true</code>.
* @param getAll get status for uninteresting (unchanged) files.
* @param noIgnore get status for normaly ignored files and directories.
* @param ignoreExternals if externals are ignored during status
+ * @param depthAsSticky When set, interpret <code>depth</code> as
+ * the ambient depth of the working copy.
* @param changelists changelists to filter by
+ * @since 1.9
*/
+ void status(String path, Depth depth,
+ boolean onServer, boolean ignoreLocal,
+ boolean getAll, boolean noIgnore,
+ boolean ignoreExternals, boolean depthAsSticky,
+ Collection<String> changelists, StatusCallback callback)
+ throws ClientException;
+
+ /**
+ * Return information about the status of the working copy and
+ * maybe repository.
+ * <p>
+ * Behaves like the 1.9 version with
+ * <code>onDisk = true</code> and
+ * <code>depthAsSticky = false</code>.
+ * @deprecated
+ */
+ @Deprecated
void status(String path, Depth depth, boolean onServer,
boolean getAll, boolean noIgnore, boolean ignoreExternals,
Collection<String> changelists, StatusCallback callback)
@@ -131,9 +160,25 @@ public interface ISVNClient
* accepted by the command-line client.
* @param prompt the callback interface
*/
+ void setPrompt(AuthnCallback prompt);
+
+ /**
+ * Register callback interface to supply username and password on demand.
+ * This callback can also be used to provide theequivalent of the
+ * <code>--no-auth-cache</code> and <code>--non-interactive</code> arguments
+ * accepted by the command-line client.
+ * @param prompt the callback interface
+ */
+ @SuppressWarnings("deprecation")
void setPrompt(UserPasswordCallback prompt);
/**
+ * Set callbacks for ra_svn tunnel handling.
+ * @since 1.9
+ */
+ void setTunnelAgent(TunnelAgent tunnelAgent);
+
+ /**
* Retrieve the log messages for an item.
* @param path path or url to get the log message for.
* @param pegRevision revision to interpret path
@@ -210,6 +255,35 @@ public interface ISVNClient
throws ClientException;
/**
+ * Reverts set of files or directories to a pristine state.
+ * @param path A set of paths to revert.
+ * @param depth the depth to recurse into subdirectories
+ * @param changelists changelists to filter by
+ * @param clearChangelists If set, will clear changelist association
+ * from the reverted paths.
+ * @param metadataOnly Revert just the metadata (including conflict data)
+ * and not the working files/dirs
+ * @throws ClientException
+ * @since 1.9
+ */
+ void revert(Set<String> paths, Depth depth,
+ Collection<String> changelists,
+ boolean clearChangelists,
+ boolean metadataOnly)
+ throws ClientException;
+
+ /**
+ * Reverts set of files or directories to a pristine state.
+ * <p>
+ * Behaves like the 1.9 version with <code>clearChangelists</code>
+ * set to <code>false</code>;
+ */
+ void revert(Set<String> paths, Depth depth,
+ Collection<String> changelists)
+ throws ClientException;
+
+
+ /**
* Reverts a file to a pristine state.
* @param path path of the file.
* @param depth the depth to recurse into subdirectories
@@ -221,6 +295,10 @@ public interface ISVNClient
/**
* Adds a file to the repository.
+ * <p>
+ * <b>Note:</b> Behaves like the 1.8 version with
+ * <code>noAutoProps</code> set to <code>false</code>.
+ *
* @param path path to be added.
* @param depth the depth to recurse into subdirectories
* @param force if adding a directory and recurse true and path is a
@@ -229,7 +307,6 @@ public interface ISVNClient
* ignore patterns
* @param addParents add any intermediate parents to the working copy
* @throws ClientException
- * @note this method behaves like the 1.8 version with noAutoProps=false
*/
void add(String path, Depth depth, boolean force, boolean noIgnores,
boolean addParents)
@@ -299,12 +376,46 @@ public interface ISVNClient
* @param makeParents Whether to create intermediate parents
* @param ignoreExternals Whether or not to process external definitions
* as part of this operation.
+ * @param metadataOnly Copy just the metadata and not the working files/dirs
+ * @param pinExternals Whether or not to pin external definitions as part
+ * of this operation.
+ * @param externalsToPin The set of externals to pin.
+ * Keys are either local absolute paths (when the source of the
+ * copy is the working copy) or URLs within the repository
+ * (when the source is the repository) where an
+ * <code>svn:externals</code> property is defined.
+ * Values are lists of parsed {@link ExternalItem}
+ * objects from each external definitions.
+ * If <code>pinExternals</code> is <code>true</code>, only
+ * the externals in this set will be pinned; if this parameter
+ * is <code>null</code>, all externals will be pinned.
+ * If <code>pinExternals</code> is <code>false</code>,
+ * this parameter will be ignored.
* @param revpropTable A string-to-string mapping of revision properties
* to values which will be set if this operation
* results in a commit.
* @param handler the commit message callback, may be <code>null</code>
* if <code>destPath</code> is not a URL
* @throws ClientException If the copy operation fails.
+ * @throws NullPointerException if the <code>sources</code> list is empty.
+ * @since 1.9
+ */
+ void copy(List<CopySource> sources, String destPath,
+ boolean copyAsChild, boolean makeParents,
+ boolean ignoreExternals, boolean metadataOnly,
+ boolean pinExternals,
+ Map<String, List<ExternalItem>> externalsToPin,
+ Map<String, String> revpropTable,
+ CommitMessageCallback handler, CommitCallback callback)
+ throws ClientException;
+
+ /**
+ * Copy versioned paths with the history preserved.
+ * <p>
+ * Behaves like the 1.9 version with
+ * <code>pinExternals</code> set to <code>false</code> and
+ * <code>externalsToPin</code> set to <code>null</code> and
+ * <code>metadataOnly</code> set to <code>false</code>.
*/
void copy(List<CopySource> sources, String destPath,
boolean copyAsChild, boolean makeParents,
@@ -344,6 +455,7 @@ public interface ISVNClient
* @deprecated Provided for backward compatibility with 1.7. Passes
* metadataOnly false and allowMixRev true.
*/
+ @Deprecated
void move(Set<String> srcPaths, String destPath, boolean force,
boolean moveAsChild, boolean makeParents,
Map<String, String> revpropTable,
@@ -370,6 +482,30 @@ public interface ISVNClient
* Recursively cleans up a local directory, finishing any
* incomplete operations, removing lockfiles, etc.
* @param path a local directory.
+ * @param breakLocks ### FIXME: Missing docstring in svn_client.h
+ * @param clearDavCache ### FIXME: Missing docstring in svn_client.h
+ * @param removeUnusedPristines ### FIXME: Missing docstring in svn_client.h
+ * @param includeExternals Recurse into externals working copies
+ * and clean them up, too.
+ * @throws ClientException
+ * @since 1.9
+ */
+ void cleanup(String path,
+ boolean breakLocks,
+ boolean fixRecordedTimestamps,
+ boolean clearDavCache,
+ boolean removeUnusedPristines,
+ boolean includeExternals)
+ throws ClientException;
+
+ /**
+ * Recursively cleans up a local directory, finishing any
+ * incomplete operations, removing lockfiles, etc.
+ * <p>
+ * Behaves like the 1.9 version with <code>includeExternals</code>
+ * set to <code>false<code>, and the other flags to
+ * <code>true</code>.
+ * @param path a local directory.
* @throws ClientException
*/
void cleanup(String path) throws ClientException;
@@ -399,6 +535,31 @@ public interface ISVNClient
* @param depth how deep to recurse in subdirectories
* @param nativeEOL which EOL characters to use during export
* @throws ClientException
+ * @since 1.9
+ */
+ long doExport(String srcPath, String destPath, Revision revision,
+ Revision pegRevision, boolean force,
+ boolean ignoreExternals, boolean ignoreKeywords,
+ Depth depth, String nativeEOL)
+ throws ClientException;
+
+ /**
+ * Exports the contents of either a subversion repository into a
+ * 'clean' directory (meaning a directory with no administrative
+ * directories).
+ * <p>
+ * <b>Note:</b> Behaves like the 1.9 version with
+ * ignoreKeywords set to false.
+ *
+ * @param srcPath the url of the repository path to be exported
+ * @param destPath a destination path that must not already exist.
+ * @param revision the revsion to be exported
+ * @param pegRevision the revision to interpret srcPath
+ * @param force set if it is ok to overwrite local files
+ * @param ignoreExternals ignore external during export
+ * @param depth how deep to recurse in subdirectories
+ * @param nativeEOL which EOL characters to use during export
+ * @throws ClientException
*/
long doExport(String srcPath, String destPath, Revision revision,
Revision pegRevision, boolean force, boolean ignoreExternals,
@@ -457,6 +618,10 @@ public interface ISVNClient
/**
* Import a file or directory into a repository directory at
* head.
+ * <p>
+ * <b>Note:</b> Behaves like the 1.8 version with noAutoProps
+ * set to false and without the filtering option.
+ *
* @param path the local path
* @param url the target url
* @param depth depth to traverse into subdirectories
@@ -469,8 +634,6 @@ public interface ISVNClient
* @param handler the commit message callback
* @param callback the commit status callback
* @throws ClientException
- * @note this method behaves like the 1.8 version with noAutoProps=false
- * and without the filtering option.
*/
void doImport(String path, String url, Depth depth,
boolean noIgnore, boolean ignoreUnknownNodeTypes,
@@ -501,6 +664,33 @@ public interface ISVNClient
* @param ignoreMergeinfo ignore merge history, treat sources as unrelated
* @param diffIgnoreAncestry always treat source files as related
* @param dryRun do not change anything
+ * @param allowMixedRev allow merging into a mixed-revision working copy
+ * @param recordOnly record mergeinfo but do not run merge
+ * @throws ClientException
+ * @since 1.9
+ */
+ void merge(String path1, Revision revision1, String path2,
+ Revision revision2, String localPath, boolean force, Depth depth,
+ boolean ignoreMergeinfo, boolean diffIgnoreAncestry,
+ boolean dryRun, boolean allowMixedRev, boolean recordOnly)
+ throws ClientException;
+
+ /**
+ * Merge changes from two paths into a new local path.
+ * <p>
+ * <b>Note:</b> Behaves like the 1.9 version with allowMixedRev
+ * always set to <code>true</code>.
+ *
+ * @param path1 first path or url
+ * @param revision1 first revision
+ * @param path2 second path or url
+ * @param revision2 second revision
+ * @param localPath target local path
+ * @param force overwrite local changes
+ * @param depth how deep to traverse into subdirectories
+ * @param ignoreMergeinfo ignore merge history, treat sources as unrelated
+ * @param diffIgnoreAncestry always treat source files as related
+ * @param dryRun do not change anything
* @param recordOnly record mergeinfo but do not run merge
* @throws ClientException
* @since 1.8
@@ -513,6 +703,9 @@ public interface ISVNClient
/**
* Merge changes from two paths into a new local path.
+ * <p>
+ * <b>Note:</b> Behaves like the 1.8 version where ignoreAncestry
+ * maps to both ignoreMergeinfo and diffIgnoreAncestry
*
* @param path1 first path or url
* @param revision1 first revision
@@ -525,8 +718,6 @@ public interface ISVNClient
* @param dryRun do not change anything
* @param recordOnly record mergeinfo but do not run merge
* @throws ClientException
- * @note Behaves like the 1.8 where ignoreAncestry maps to
- * both ignoreMergeinfo and diffIgnoreAncestry
*/
void merge(String path1, Revision revision1, String path2,
Revision revision2, String localPath, boolean force, Depth depth,
@@ -545,6 +736,33 @@ public interface ISVNClient
* @param ignoreMergeinfo ignore merge history, treat sources as unrelated
* @param diffIgnoreAncestry always treat source files as related
* @param dryRun do not change anything
+ * @param allowMixedRev allow merging into a mixed-revision working copy
+ * @param recordOnly record mergeinfo but do not run merge
+ * @throws ClientException
+ * @since 1.9
+ */
+ void merge(String path, Revision pegRevision, List<RevisionRange> revisions,
+ String localPath, boolean force, Depth depth,
+ boolean ignoreMergeinfo, boolean diffIgnoreAncestry,
+ boolean dryRun, boolean allowMixedRev, boolean recordOnly)
+ throws ClientException;
+
+ /**
+ * Merge set of revisions into a new local path.
+ * <p>
+ * <b>Note:</b> Behaves like the 1.9 version with allowMixedRev
+ * always set to <code>true</code>.
+ *
+ * @param path path or url
+ * @param pegRevision revision to interpret path
+ * @param revisions revisions to merge; may be null, indicating that
+ * the optimal range should be determined automatcially
+ * @param localPath target local path
+ * @param force overwrite local changes
+ * @param depth how deep to traverse into subdirectories
+ * @param ignoreMergeinfo ignore merge history, treat sources as unrelated
+ * @param diffIgnoreAncestry always treat source files as related
+ * @param dryRun do not change anything
* @param recordOnly record mergeinfo but do not run merge
* @throws ClientException
* @since 1.8
@@ -557,6 +775,10 @@ public interface ISVNClient
/**
* Merge set of revisions into a new local path.
+ * <p>
+ * <b>Note:</b> Behaves like the 1.8 version where ignoreAncestry
+ * maps to both ignoreMergeinfo and diffIgnoreAncestry.
+ *
* @param path path or url
* @param pegRevision revision to interpret path
* @param revisions revisions to merge;
@@ -569,8 +791,6 @@ public interface ISVNClient
* @param dryRun do not change anything
* @param recordOnly record mergeinfo but do not run merge
* @throws ClientException
- * @note Behaves like the 1.8 where ignoreAncestry maps to
- * both ignoreMergeinfo and diffIgnoreAncestry
*/
void merge(String path, Revision pegRevision, List<RevisionRange> revisions,
String localPath, boolean force, Depth depth,
@@ -594,6 +814,7 @@ public interface ISVNClient
* @throws ClientException
* @deprecated Will be removed in a future release
*/
+ @Deprecated
void mergeReintegrate(String path, Revision pegRevision,
String localPath, boolean dryRun)
throws ClientException;
@@ -616,7 +837,7 @@ public interface ISVNClient
* @param pegRevision peg rev for pathOrUrl
* @param mergeSourceUrl the source of the merge
* @param srcPegRevision peg rev for mergeSourceUrl
- * @param srcStartRevieion lower bound of the source revision range
+ * @param srcStartRevision lower bound of the source revision range
* @param srcEndRevision upper bound of the source revision range
* @param discoverChangedPaths return paths of changed items
* @param depth the depth to recurse to
@@ -635,6 +856,10 @@ public interface ISVNClient
/**
* Retrieve either merged or eligible-to-be-merged revisions.
+ * <p>
+ * <b>Note:</b> Behaves like the 1.8 version, with unspecified
+ * revision range.
+ *
* @param kind kind of revisions to receive
* @param pathOrUrl target of merge
* @param pegRevision peg rev for pathOrUrl
@@ -644,7 +869,6 @@ public interface ISVNClient
* @param depth the depth to recurse to
* @param revProps the revprops to retrieve
* @param callback the object to receive the log messages
- * @note Behaves like the 1.8 version, with unspecified revision range.
*/
void getMergeinfoLog(Mergeinfo.LogKind kind, String pathOrUrl,
Revision pegRevision, String mergeSourceUrl,
@@ -660,7 +884,7 @@ public interface ISVNClient
* @param target2 second path or url
* @param revision2 second revision
* @param relativeToDir index path is relative to this path
- * @param outFileName file name where difference are written
+ * @param outStream the stream to which difference are written
* @param depth how deep to traverse into subdirectories
* @param ignoreAncestry ignore if files are not related
* @param noDiffDeleted no output on deleted files
@@ -681,6 +905,26 @@ public interface ISVNClient
DiffOptions options)
throws ClientException;
+ /**
+ * Display the differences between two paths
+ * @param target1 first path or url
+ * @param revision1 first revision
+ * @param target2 second path or url
+ * @param revision2 second revision
+ * @param relativeToDir index path is relative to this path
+ * @param outFileName file name where difference are written
+ * @param depth how deep to traverse into subdirectories
+ * @param ignoreAncestry ignore if files are not related
+ * @param noDiffDeleted no output on deleted files
+ * @param force diff even on binary files
+ * @param copiesAsAdds if set, copied files will be shown in their
+ * entirety, not as diffs from their sources
+ * @param ignoreProps don't show property diffs
+ * @param propsOnly show property changes only
+ * @param options additional options for controlling the output
+ * @throws ClientException
+ * @since 1.8
+ */
void diff(String target1, Revision revision1, String target2,
Revision revision2, String relativeToDir, String outFileName,
Depth depth, Collection<String> changelists,
@@ -696,7 +940,7 @@ public interface ISVNClient
* @param target2 second path or url
* @param revision2 second revision
* @param relativeToDir index path is relative to this path
- * @param outFileName file name where difference are written
+ * @param outStream the stream to which difference are written
* @param depth how deep to traverse into subdirectories
* @param ignoreAncestry ignore if files are not related
* @param noDiffDeleted no output on deleted files
@@ -714,6 +958,24 @@ public interface ISVNClient
boolean copiesAsAdds, boolean ignoreProps, boolean propsOnly)
throws ClientException;
+ /**
+ * Display the differences between two paths
+ * @param target1 first path or url
+ * @param revision1 first revision
+ * @param target2 second path or url
+ * @param revision2 second revision
+ * @param relativeToDir index path is relative to this path
+ * @param outFileName file name where difference are written
+ * @param depth how deep to traverse into subdirectories
+ * @param ignoreAncestry ignore if files are not related
+ * @param noDiffDeleted no output on deleted files
+ * @param force diff even on binary files
+ * @param copiesAsAdds if set, copied files will be shown in their
+ * entirety, not as diffs from their sources
+ * @param ignoreProps don't show property diffs
+ * @param propsOnly show property changes only
+ * @throws ClientException
+ */
void diff(String target1, Revision revision1, String target2,
Revision revision2, String relativeToDir, String outFileName,
Depth depth, Collection<String> changelists,
@@ -728,7 +990,7 @@ public interface ISVNClient
* @param startRevision first Revision to compare
* @param endRevision second Revision to compare
* @param relativeToDir index path is relative to this path
- * @param outFileName file name where difference are written
+ * @param outStream the stream to which difference are written
* @param depth how deep to traverse into subdirectories
* @param changelists if non-null, filter paths using changelists
* @param ignoreAncestry ignore if files are not related
@@ -750,6 +1012,27 @@ public interface ISVNClient
DiffOptions options)
throws ClientException;
+ /**
+ * Display the differences between two paths.
+ * @param target path or url
+ * @param pegRevision revision tointerpret target
+ * @param startRevision first Revision to compare
+ * @param endRevision second Revision to compare
+ * @param relativeToDir index path is relative to this path
+ * @param outFileName file name where difference are written
+ * @param depth how deep to traverse into subdirectories
+ * @param changelists if non-null, filter paths using changelists
+ * @param ignoreAncestry ignore if files are not related
+ * @param noDiffDeleted no output on deleted files
+ * @param force diff even on binary files
+ * @param copiesAsAdds if set, copied files will be shown in their
+ * entirety, not as diffs from their sources
+ * @param ignoreProps don't show property diffs
+ * @param propsOnly show property changes only
+ * @param options additional options for controlling the output
+ * @throws ClientException
+ * @since 1.8
+ */
void diff(String target, Revision pegRevision, Revision startRevision,
Revision endRevision, String relativeToDir, String outFileName,
Depth depth, Collection<String> changelists,
@@ -765,7 +1048,7 @@ public interface ISVNClient
* @param startRevision first Revision to compare
* @param endRevision second Revision to compare
* @param relativeToDir index path is relative to this path
- * @param outFileName file name where difference are written
+ * @param outStream the stream to which difference are written
* @param depth how deep to traverse into subdirectories
* @param changelists if non-null, filter paths using changelists
* @param ignoreAncestry ignore if files are not related
@@ -785,6 +1068,25 @@ public interface ISVNClient
boolean copiesAsAdds, boolean ignoreProps, boolean propsOnly)
throws ClientException;
+ /**
+ * Display the differences between two paths.
+ * @param target path or url
+ * @param pegRevision revision tointerpret target
+ * @param startRevision first Revision to compare
+ * @param endRevision second Revision to compare
+ * @param relativeToDir index path is relative to this path
+ * @param outFileName file name where difference are written
+ * @param depth how deep to traverse into subdirectories
+ * @param changelists if non-null, filter paths using changelists
+ * @param ignoreAncestry ignore if files are not related
+ * @param noDiffDeleted no output on deleted files
+ * @param force diff even on binary files
+ * @param copiesAsAdds if set, copied files will be shown in their
+ * entirety, not as diffs from their sources
+ * @param ignoreProps don't show property diffs
+ * @param propsOnly show property changes only
+ * @throws ClientException
+ */
void diff(String target, Revision pegRevision, Revision startRevision,
Revision endRevision, String relativeToDir, String outFileName,
Depth depth, Collection<String> changelists,
@@ -824,14 +1126,14 @@ public interface ISVNClient
*
* @param target Path or URL.
* @param pegRevision Revision at which to interpret
- * <code>target</code>. If {@link Revision.Kind#unspecified} or
+ * <code>target</code>. If {@link Revision#UNSPECIFIED} or
* <code>null</code>, behave identically to {@link
* #diffSummarize(String, Revision, String, Revision, Depth,
* Collection, boolean, DiffSummaryCallback)}, using
* <code>path</code> for both of that method's targets.
- * @param startRevision Beginning of range for comparsion of
+ * @param startRevision Beginning of range for comparison of
* <code>target</code>.
- * @param endRevision End of range for comparsion of
+ * @param endRevision End of range for comparison of
* <code>target</code>.
* @param depth how deep to recurse.
* @param changelists if non-null, filter paths using changelists
@@ -889,14 +1191,11 @@ public interface ISVNClient
*
* @param paths paths of the items
* @param name name of the property
- * @param value new value of the property. Set value to <code>
- * null</code> to delete a property
+ * @param value new value of the property. Set value to
+ * <code>null</code> to delete a property
* @param depth the depth to recurse into subdirectories
* @param changelists changelists to filter by
* @param force do not check if the value is valid
- * @param revpropTable A string-to-string mapping of revision properties
- * to values which will be set if this operation
- * results in a commit.
* @throws ClientException
*/
void propertySetLocal(Set<String> paths, String name, byte[] value,
@@ -904,6 +1203,21 @@ public interface ISVNClient
boolean force)
throws ClientException;
+ /**
+ * Sets one property of an item with a String value
+ *
+ * @param paths paths of the items
+ * @param name name of the property
+ * @param value new value of the property. Set value to <code>
+ * null</code> to delete a property
+ * @param depth the depth to recurse into subdirectories
+ * @param changelists changelists to filter by
+ * @param force do not check if the value is valid
+ * @param revpropTable A string-to-string mapping of revision properties
+ * to values which will be set if this operation
+ * results in a commit.
+ * @throws ClientException
+ */
void propertySetRemote(String path, long baseRev, String name,
byte[] value, CommitMessageCallback handler,
boolean force, Map<String, String> revpropTable,
@@ -964,6 +1278,9 @@ public interface ISVNClient
/**
* Retrieve the content of a file
+ *
+ * Always expands keywords and never returns properties.
+ *
* @param path the path of the file
* @param revision the revision to retrieve
* @param pegRevision the revision to interpret path
@@ -982,11 +1299,40 @@ public interface ISVNClient
* @param revision the revision to retrieve
* @param pegRevision the revision at which to interpret the path
* @param stream the stream to write the file's content to
+ * @param returnProps whether to return the file's own (not inherited)
+ * properties dalong with the contents
+ * @return The file's properties if <code>returnProps</code> is
+ * set (which may yield an empty map), otherwise
+ * <code>null</code>.
+ * @throws ClientException
+ * @see java.io.PipedOutputStream
+ * @see java.io.PipedInputStream
+ * @since 1.9
+ */
+ Map<String, byte[]>
+ streamFileContent(String path,
+ Revision revision, Revision pegRevision,
+ boolean expandKeywords, boolean returnProps,
+ OutputStream stream)
+ throws ClientException;
+
+ /**
+ * Write the file's content to the specified output stream. If
+ * you need an InputStream, use a
+ * PipedInputStream/PipedOutputStream combination.
+ *
+ * Always expands keywords and never returns properties.
+ *
+ * @param path the path of the file
+ * @param revision the revision to retrieve
+ * @param pegRevision the revision at which to interpret the path
+ * @param stream the stream to write the file's content to
* @throws ClientException
* @see java.io.PipedOutputStream
* @see java.io.PipedInputStream
*/
- void streamFileContent(String path, Revision revision, Revision pegRevision,
+ void streamFileContent(String path,
+ Revision revision, Revision pegRevision,
OutputStream stream)
throws ClientException;
@@ -1013,12 +1359,28 @@ public interface ISVNClient
* information
* @param callback callback to receive the file content and the other
* information
+ * @param options additional options for controlling the output
* @throws ClientException
+ * @since 1.9
*/
void blame(String path, Revision pegRevision, Revision revisionStart,
Revision revisionEnd, boolean ignoreMimeType,
boolean includeMergedRevisions,
- BlameCallback callback) throws ClientException;
+ BlameCallback callback, DiffOptions options)
+ throws ClientException;
+
+ /**
+ * Retrieve the content together with the author, the revision and the date
+ * of the last change of each line
+ * <p>
+ * Behaves like the 1.9 version with <code>options</code> set to
+ * their default values.
+ */
+ void blame(String path, Revision pegRevision, Revision revisionStart,
+ Revision revisionEnd, boolean ignoreMimeType,
+ boolean includeMergedRevisions,
+ BlameCallback callback)
+ throws ClientException;
/**
* Set directory for the configuration information, taking the
@@ -1040,6 +1402,19 @@ public interface ISVNClient
String getConfigDirectory() throws ClientException;
/**
+ * Set an event handler that will be called every time the
+ * configuration is loaded by this client object.
+ */
+ void setConfigEventHandler(ConfigEvent configHandler)
+ throws ClientException;
+
+ /**
+ * Return a reference to the installed configuration event
+ * handler. The returned value may be <code>null</code>.
+ */
+ ConfigEvent getConfigEventHandler() throws ClientException;
+
+ /**
* cancel the active operation
* @throws ClientException
*/
@@ -1069,7 +1444,8 @@ public interface ISVNClient
/**
* Recursively get the paths which belong to a changelist
* @param rootPath the wc path under which to check
- * @param changelists the changelists to look under
+ * @param changelists the changelists to look under;
+ * if <code>null</code>, all changelists will be considered.
* @param depth the depth to recurse
* @param callback the callback to return the changelists through
*/
@@ -1097,13 +1473,59 @@ public interface ISVNClient
throws ClientException;
/**
- * Retrieve information about repository or working copy items.
+ * Invoke <code>callback</code> to return information
+ * <code>pathOrUrl</code> in <code>revision</code>. The
+ * information returned is system-generated metadata, not the sort
+ * of "property" metadata created by users.
+ * <p>
+ * If both revision arguments are either <code>null</code> or
+ * {@link Revision#START}, then information will be pulled solely
+ * from the working copy; no network connections will be made.
+ * <p>
+ * Otherwise, information will be pulled from a repository. The
+ * actual node revision selected is determined by the
+ * <code>pathOrUrl</code> as it exists in
+ * <code>pegRevision</code>. If <code>pegRevision</code> is
+ * {@link Revision#START}, then it defaults to {@link
+ * Revision#HEAD} for URLs or {@link Revision#WORKING} for WC
+ * targets.
+ * <p>
+ * If <code>pathOrUrl</code> is not a local path, then if
+ * <code>revision</code> is {@link Revision#PREVIOUS} (or some
+ * other kind that requires a local path), an error will be
+ * returned, because the desired revision cannot be determined.
+ * <p>
+ * If <code>pathOrUrl</code> is a file, just invoke the callback on it. If it
+ * is a directory, then descend according to <code>depth</code>.
+ * <p>
* @param pathOrUrl the path or the url of the item
* @param revision the revision of the item to return
* @param pegRevision the revision to interpret pathOrUrl
* @param depth the depth to recurse
+ * @param fetchExcluded when <code>true</code>, retrieve
+ * information about nodes that are excluded from the working copy
+ * @param fetchActualOnly when <code>true</code>, retrieve
+ * information about node that are not versioned, but are still
+ * tree conflicted.
+ * @param includeExternals Recurs into externals directories
* @param changelists if non-null, filter paths using changelists
* @param callback a callback to receive the infos retrieved
+ * @since 1.9
+ */
+ void info(String pathOrUrl,
+ Revision revision, Revision pegRevision, Depth depth,
+ boolean fetchExcluded, boolean fetchActualOnly,
+ boolean includeExternals,
+ Collection<String> changelists, InfoCallback callback)
+ throws ClientException;
+
+ /**
+ * Retrieve information about repository or working copy items.
+ * <p>
+ * Behaves like the 1.9 version, with <code>fetchExcluded</code>
+ * set to <code>false</code>, <code>fetchActualOnly</code> set to
+ * <code>true</code> anf <code>includeExternals</code> set to
+ * <code>false</code>.
*/
void info2(String pathOrUrl, Revision revision, Revision pegRevision,
Depth depth, Collection<String> changelists,
@@ -1145,4 +1567,71 @@ public interface ISVNClient
int stripCount, boolean reverse, boolean ignoreWhitespace,
boolean removeTempfiles, PatchCallback callback)
throws ClientException;
+
+ /**
+ * Recursively vacuum a working copy, removing unnecessary data.
+ * <p>
+ * This method will report an error when
+ * <code>removeUnversionedItems</code> or
+ * <code>removeIgnoredItems</code> are set, and the working copy
+ * is already locked. This prevents accidental corruption of the
+ * working copy if this method is invoked while another client is
+ * performing some other operation on the working copy.
+ * @param path The path of the working copy directory.
+ * @param removeUnversionedItems Remove unversioned items from the
+ * working copy after it has been successfully cleaned up.
+ * @param removeIgnoredItems Remove unversioned items that are
+ * ignored by Subversion, after the working copy has been
+ * successfully cleaned up.
+ * @param fixRecordedTimestamps Update timestamps recorded in the
+ * working copy database to their actual on-disk values.
+ * @param removeUnusedPristines Remove pristine files that are not
+ * referenced by the working copy.
+ * @param includeExternals Recurse into externals working copies
+ * and vacuum them, too.
+ * @since 1.9
+ */
+ void vacuum(String path,
+ boolean removeUnversionedItems,
+ boolean removeIgnoredItems,
+ boolean fixRecordedTimestamps,
+ boolean removeUnusedPristines,
+ boolean includeExternals)
+ throws ClientException;
+
+ /**
+ * Open a persistent session to a repository.
+ * <p>
+ * <b>Note:</b> The session object inherits the progress callback,
+ * configuration directory and authentication info.
+ *
+ * @param pathOrUrl A path in a working copy from which the
+ * session URL is derived, or the URL itself.
+ * @throws remote.RetryOpenSession If the session URL was redirected
+ * @throws SubversionException If an URL redirect cycle was detected
+ * @throws ClientException
+ * @since 1.9
+ */
+ ISVNRemote openRemoteSession(String pathOrUrl)
+ throws ClientException, SubversionException;
+
+ /**
+ * Open a persistent session to a repository.
+ * <p>
+ * <b>Note:</b> The session object inherits the progress callback,
+ * configuration directory and authentication info.
+ *
+ * @param pathOrUrl A path in a working copy from which the
+ * session URL is derived, or the URL itself.
+ * @param retryAttempts The number of times to retry the operation
+ * if the given URL is redirected.
+ * @throws IllegalArgumentException If <code>retryAttempts</code>
+ * is not positive
+ * @throws remote.RetryOpenSession If the session URL was redirected
+ * @throws SubversionException If an URL redirect cycle was detected
+ * @throws ClientException
+ * @since 1.9
+ */
+ ISVNRemote openRemoteSession(String pathOrUrl, int retryAttempts)
+ throws ClientException, SubversionException;
}