You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by hw...@apache.org on 2010/09/06 22:02:24 UTC

svn commit: r993141 [2/25] - in /subversion/branches/performance: ./ build/ac-macros/ build/generator/ contrib/server-side/ notes/ notes/wc-ng/ subversion/bindings/javahl/native/ subversion/bindings/javahl/src/org/apache/subversion/javahl/ subversion/b...

Modified: subversion/branches/performance/subversion/bindings/javahl/native/SVNClient.cpp
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/native/SVNClient.cpp?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/native/SVNClient.cpp (original)
+++ subversion/branches/performance/subversion/bindings/javahl/native/SVNClient.cpp Mon Sep  6 20:02:15 2010
@@ -26,11 +26,9 @@
 
 #include "SVNClient.h"
 #include "JNIUtil.h"
-#include "ClientNotifyCallback.h"
 #include "CopySources.h"
 #include "DiffSummaryReceiver.h"
-#include "ConflictResolverCallback.h"
-#include "ProgressListener.h"
+#include "ClientContext.h"
 #include "Prompter.h"
 #include "Pool.h"
 #include "Targets.h"
@@ -41,6 +39,7 @@
 #include "LogMessageCallback.h"
 #include "InfoCallback.h"
 #include "PatchCallback.h"
+#include "CommitCallback.h"
 #include "StatusCallback.h"
 #include "ChangelistCallback.h"
 #include "ListCallback.h"
@@ -68,27 +67,14 @@
 #include <iostream>
 #include <sstream>
 
-struct log_msg_baton
-{
-    const char *message;
-    CommitMessage *messageHandler;
-};
 
-SVNClient::SVNClient()
+SVNClient::SVNClient(jobject jthis_in)
+    : context(jthis_in)
 {
-    m_notify2 = NULL;
-    m_progressListener = NULL;
-    m_prompter = NULL;
-    m_commitMessage = NULL;
-    m_conflictResolver = NULL;
 }
 
 SVNClient::~SVNClient()
 {
-    delete m_notify2;
-    delete m_progressListener;
-    delete m_prompter;
-    delete m_conflictResolver;
 }
 
 SVNClient *SVNClient::getCppObject(jobject jthis)
@@ -99,10 +85,10 @@ SVNClient *SVNClient::getCppObject(jobje
     return (cppAddr == 0 ? NULL : reinterpret_cast<SVNClient *>(cppAddr));
 }
 
-void SVNClient::dispose(jobject jthis)
+void SVNClient::dispose()
 {
     static jfieldID fid = 0;
-    SVNBase::dispose(jthis, &fid, JAVA_PACKAGE"/SVNClient");
+    SVNBase::dispose(&fid, JAVA_PACKAGE"/SVNClient");
 }
 
 jstring SVNClient::getAdminDirectoryName()
@@ -136,7 +122,7 @@ void SVNClient::list(const char *url, Re
                      ListCallback *callback)
 {
     SVN::Pool requestPool;
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -168,7 +154,7 @@ SVNClient::status(const char *path, svn_
 
     SVN_JNI_NULL_PTR_EX(path, "path", );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
     callback->setWcCtx(ctx->wc_ctx);
@@ -181,29 +167,13 @@ SVNClient::status(const char *path, svn_
     SVN_JNI_ERR(svn_client_status5(&youngest, ctx, checkedPath.c_str(),
                                    &rev,
                                    depth,
-                                   getAll, onServer, noIgnore,
+                                   getAll, onServer, noIgnore, FALSE,
                                    ignoreExternals,
                                    changelists.array(requestPool),
                                    StatusCallback::callback, callback,
                                    requestPool.pool()), );
 }
 
-void SVNClient::username(const char *pi_username)
-{
-    m_userName = (pi_username == NULL ? "" : pi_username);
-}
-
-void SVNClient::password(const char *pi_password)
-{
-    m_passWord = (pi_password == NULL ? "" : pi_password);
-}
-
-void SVNClient::setPrompt(Prompter *prompter)
-{
-    delete m_prompter;
-    m_prompter = prompter;
-}
-
 void SVNClient::logMessages(const char *path, Revision &pegRevision,
                             std::vector<RevisionRange> &logRanges,
                             bool stopOnCopy, bool discoverPaths,
@@ -214,7 +184,7 @@ void SVNClient::logMessages(const char *
 
     SVN_JNI_NULL_PTR_EX(path, "path", );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -275,7 +245,7 @@ jlong SVNClient::checkout(const char *mo
     SVN_JNI_ERR(path.error_occured(), -1);
     svn_revnum_t rev;
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return -1;
 
@@ -293,39 +263,22 @@ jlong SVNClient::checkout(const char *mo
     return rev;
 }
 
-void SVNClient::notification2(ClientNotifyCallback *notify2)
-{
-    delete m_notify2;
-    m_notify2 = notify2;
-}
-
-void SVNClient::setConflictResolver(ConflictResolverCallback *conflictResolver)
-{
-    delete m_conflictResolver;
-    m_conflictResolver = conflictResolver;
-}
-
-void SVNClient::setProgressListener(ProgressListener *listener)
-{
-    delete m_progressListener;
-    m_progressListener = listener;
-}
-
-void SVNClient::remove(Targets &targets, const char *message, bool force,
-                       bool keep_local, RevpropTable &revprops)
+void SVNClient::remove(Targets &targets, CommitMessage *message, bool force,
+                       bool keep_local, RevpropTable &revprops,
+                       CommitCallback *callback)
 {
-    svn_commit_info_t *commit_info = NULL;
     SVN::Pool requestPool;
-    svn_client_ctx_t *ctx = getContext(message);
+    svn_client_ctx_t *ctx = context.getContext(message);
     if (ctx == NULL)
         return;
 
     const apr_array_header_t *targets2 = targets.array(requestPool);
     SVN_JNI_ERR(targets.error_occured(), );
 
-    SVN_JNI_ERR(svn_client_delete3(&commit_info, targets2, force, keep_local,
-                                   revprops.hash(requestPool), ctx,
-                                   requestPool.pool()), );
+    SVN_JNI_ERR(svn_client_delete4(targets2, force, keep_local,
+                                   revprops.hash(requestPool),
+                                   CommitCallback::callback, callback,
+                                   ctx, requestPool.pool()), );
 }
 
 void SVNClient::revert(const char *path, svn_depth_t depth,
@@ -335,7 +288,7 @@ void SVNClient::revert(const char *path,
 
     SVN_JNI_NULL_PTR_EX(path, "path", );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -357,7 +310,7 @@ void SVNClient::add(const char *path,
 
     Path intPath(path);
     SVN_JNI_ERR(intPath.error_occured(), );
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -373,7 +326,7 @@ jlongArray SVNClient::update(Targets &ta
 {
     SVN::Pool requestPool;
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     apr_array_header_t *revs;
     if (ctx == NULL)
         return NULL;
@@ -406,34 +359,31 @@ jlongArray SVNClient::update(Targets &ta
     return jrevs;
 }
 
-jlong SVNClient::commit(Targets &targets, const char *message,
-                        svn_depth_t depth, bool noUnlock, bool keepChangelist,
-                        StringArray &changelists, RevpropTable &revprops)
+void SVNClient::commit(Targets &targets, CommitMessage *message,
+                       svn_depth_t depth, bool noUnlock, bool keepChangelist,
+                       StringArray &changelists, RevpropTable &revprops,
+                       CommitCallback *callback)
 {
     SVN::Pool requestPool;
-    svn_commit_info_t *commit_info = NULL;
     const apr_array_header_t *targets2 = targets.array(requestPool);
-    SVN_JNI_ERR(targets.error_occured(), -1);
-    svn_client_ctx_t *ctx = getContext(message);
+    SVN_JNI_ERR(targets.error_occured(), );
+    svn_client_ctx_t *ctx = context.getContext(message);
     if (ctx == NULL)
-        return SVN_INVALID_REVNUM;
+        return;
 
-    SVN_JNI_ERR(svn_client_commit4(&commit_info, targets2, depth,
+    SVN_JNI_ERR(svn_client_commit5(targets2, depth,
                                    noUnlock, keepChangelist,
                                    changelists.array(requestPool),
-                                   revprops.hash(requestPool), ctx,
-                                   requestPool.pool()),
-                SVN_INVALID_REVNUM);
-
-    if (commit_info && SVN_IS_VALID_REVNUM(commit_info->revision))
-        return commit_info->revision;
-
-    return SVN_INVALID_REVNUM;
+                                   revprops.hash(requestPool),
+                                   CommitCallback::callback, callback,
+                                   ctx, requestPool.pool()),
+                );
 }
 
 void SVNClient::copy(CopySources &copySources, const char *destPath,
-                     const char *message, bool copyAsChild, bool makeParents,
-                     bool ignoreExternals, RevpropTable &revprops)
+                     CommitMessage *message, bool copyAsChild,
+                     bool makeParents, bool ignoreExternals,
+                     RevpropTable &revprops, CommitCallback *callback)
 {
     SVN::Pool requestPool;
 
@@ -448,20 +398,21 @@ void SVNClient::copy(CopySources &copySo
     Path destinationPath(destPath);
     SVN_JNI_ERR(destinationPath.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(message);
+    svn_client_ctx_t *ctx = context.getContext(message);
     if (ctx == NULL)
         return;
 
-    svn_commit_info_t *commit_info;
-    SVN_JNI_ERR(svn_client_copy5(&commit_info, srcs, destinationPath.c_str(),
+    SVN_JNI_ERR(svn_client_copy6(srcs, destinationPath.c_str(),
                                  copyAsChild, makeParents, ignoreExternals,
-                                 revprops.hash(requestPool), ctx,
-                                 requestPool.pool()), );
+                                 revprops.hash(requestPool),
+                                 CommitCallback::callback, callback,
+                                 ctx, requestPool.pool()), );
 }
 
 void SVNClient::move(Targets &srcPaths, const char *destPath,
-                     const char *message, bool force, bool moveAsChild,
-                     bool makeParents, RevpropTable &revprops)
+                     CommitMessage *message, bool force, bool moveAsChild,
+                     bool makeParents, RevpropTable &revprops,
+                     CommitCallback *callback)
 {
     SVN::Pool requestPool;
 
@@ -471,32 +422,33 @@ void SVNClient::move(Targets &srcPaths, 
     Path destinationPath(destPath);
     SVN_JNI_ERR(destinationPath.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(message);
+    svn_client_ctx_t *ctx = context.getContext(message);
     if (ctx == NULL)
         return;
 
-    svn_commit_info_t *commit_info;
-    SVN_JNI_ERR(svn_client_move5(&commit_info, (apr_array_header_t *) srcs,
+    SVN_JNI_ERR(svn_client_move6((apr_array_header_t *) srcs,
                                  destinationPath.c_str(), force, moveAsChild,
-                                 makeParents, revprops.hash(requestPool), ctx,
+                                 makeParents, revprops.hash(requestPool),
+                                 CommitCallback::callback, callback, ctx,
                                  requestPool.pool()), );
 }
 
-void SVNClient::mkdir(Targets &targets, const char *message, bool makeParents,
-                      RevpropTable &revprops)
+void SVNClient::mkdir(Targets &targets, CommitMessage *message,
+                      bool makeParents, RevpropTable &revprops,
+                      CommitCallback *callback)
 {
     SVN::Pool requestPool;
-    svn_commit_info_t *commit_info = NULL;
-    svn_client_ctx_t *ctx = getContext(message);
+    svn_client_ctx_t *ctx = context.getContext(message);
     if (ctx == NULL)
         return;
 
     const apr_array_header_t *targets2 = targets.array(requestPool);
     SVN_JNI_ERR(targets.error_occured(), );
 
-    SVN_JNI_ERR(svn_client_mkdir3(&commit_info, targets2, makeParents,
-                                  revprops.hash(requestPool), ctx,
-                                  requestPool.pool()), );
+    SVN_JNI_ERR(svn_client_mkdir4(targets2, makeParents,
+                                  revprops.hash(requestPool),
+                                  CommitCallback::callback, callback,
+                                  ctx, requestPool.pool()), );
 }
 
 void SVNClient::cleanup(const char *path)
@@ -506,7 +458,7 @@ void SVNClient::cleanup(const char *path
     Path intPath(path);
     SVN_JNI_ERR(intPath.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -520,7 +472,7 @@ void SVNClient::resolve(const char *path
     SVN_JNI_NULL_PTR_EX(path, "path", );
     Path intPath(path);
     SVN_JNI_ERR(intPath.error_occured(), );
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -541,7 +493,7 @@ jlong SVNClient::doExport(const char *sr
     Path destinationPath(destPath);
     SVN_JNI_ERR(destinationPath.error_occured(), -1);
     svn_revnum_t rev;
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return -1;
 
@@ -574,7 +526,7 @@ jlong SVNClient::doSwitch(const char *pa
     SVN_JNI_ERR(intPath.error_occured(), -1);
 
     svn_revnum_t rev;
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return -1;
 
@@ -594,9 +546,9 @@ jlong SVNClient::doSwitch(const char *pa
 }
 
 void SVNClient::doImport(const char *path, const char *url,
-                         const char *message, svn_depth_t depth,
+                         CommitMessage *message, svn_depth_t depth,
                          bool noIgnore, bool ignoreUnknownNodeTypes,
-                         RevpropTable &revprops)
+                         RevpropTable &revprops, CommitCallback *callback)
 {
     SVN::Pool requestPool;
     SVN_JNI_NULL_PTR_EX(path, "path", );
@@ -606,23 +558,22 @@ void SVNClient::doImport(const char *pat
     Path intUrl(url);
     SVN_JNI_ERR(intUrl.error_occured(), );
 
-    svn_commit_info_t *commit_info = NULL;
-    svn_client_ctx_t *ctx = getContext(message);
+    svn_client_ctx_t *ctx = context.getContext(message);
     if (ctx == NULL)
         return;
 
-    SVN_JNI_ERR(svn_client_import3(&commit_info, intPath.c_str(),
-                                   intUrl.c_str(), depth, noIgnore,
-                                   ignoreUnknownNodeTypes,
-                                   revprops.hash(requestPool), ctx,
-                                   requestPool.pool()), );
+    SVN_JNI_ERR(svn_client_import4(intPath.c_str(), intUrl.c_str(), depth,
+                                   noIgnore, ignoreUnknownNodeTypes,
+                                   revprops.hash(requestPool),
+                                   CommitCallback::callback, callback, 
+                                   ctx, requestPool.pool()), );
 }
 
 jobject
 SVNClient::suggestMergeSources(const char *path, Revision &pegRevision)
 {
     SVN::Pool requestPool;
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return NULL;
 
@@ -653,7 +604,7 @@ void SVNClient::merge(const char *path1,
     Path srcPath2 = path2;
     SVN_JNI_ERR(srcPath2.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -679,7 +630,7 @@ void SVNClient::merge(const char *path, 
     Path srcPath(path);
     SVN_JNI_ERR(srcPath.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -734,7 +685,7 @@ void SVNClient::mergeReintegrate(const c
     Path srcPath(path);
     SVN_JNI_ERR(srcPath.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -751,7 +702,7 @@ SVNClient::getMergeinfo(const char *targ
     SVN::Pool requestPool;
     JNIEnv *env = JNIUtil::getEnv();
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return NULL;
 
@@ -828,7 +779,7 @@ void SVNClient::getMergeinfoLog(int type
 {
     SVN::Pool requestPool;
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -868,7 +819,7 @@ jbyteArray SVNClient::propertyGet(const 
     Path intPath(path);
     SVN_JNI_ERR(intPath.error_occured(), NULL);
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return NULL;
 
@@ -904,7 +855,7 @@ void SVNClient::properties(const char *p
     Path intPath(path);
     SVN_JNI_ERR(intPath.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -920,7 +871,7 @@ void SVNClient::properties(const char *p
 void SVNClient::propertySet(const char *path, const char *name,
                             const char *value, svn_depth_t depth,
                             StringArray &changelists, bool force,
-                            RevpropTable &revprops)
+                            RevpropTable &revprops, CommitCallback *callback)
 {
     SVN::Pool requestPool;
     SVN_JNI_NULL_PTR_EX(path, "path", );
@@ -932,18 +883,18 @@ void SVNClient::propertySet(const char *
     else
       val = svn_string_create(value, requestPool.pool());
 
-    svn_commit_info_t *commit_info = NULL;
     Path intPath(path);
     SVN_JNI_ERR(intPath.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
-    SVN_JNI_ERR(svn_client_propset3(&commit_info, name, val, intPath.c_str(),
+    SVN_JNI_ERR(svn_client_propset4(name, val, intPath.c_str(),
                                     depth, force, SVN_INVALID_REVNUM,
                                     changelists.array(requestPool),
                                     revprops.hash(requestPool),
+                                    CommitCallback::callback, callback,
                                     ctx, requestPool.pool()), );
 }
 
@@ -967,7 +918,7 @@ void SVNClient::diff(const char *target1
         SVN_JNI_NULL_PTR_EX(target2, "target2", );
 
     SVN_JNI_NULL_PTR_EX(outfileName, "outfileName", );
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -1094,7 +1045,7 @@ SVNClient::diffSummarize(const char *tar
     SVN_JNI_NULL_PTR_EX(target1, "target1", );
     SVN_JNI_NULL_PTR_EX(target2, "target2", );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -1123,7 +1074,7 @@ SVNClient::diffSummarize(const char *tar
 
     SVN_JNI_NULL_PTR_EX(target, "target", );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -1142,158 +1093,6 @@ SVNClient::diffSummarize(const char *tar
                                                requestPool.pool()), );
 }
 
-svn_client_ctx_t *SVNClient::getContext(const char *message)
-{
-    apr_pool_t *pool = JNIUtil::getRequestPool()->pool();
-    svn_auth_baton_t *ab;
-    svn_client_ctx_t *ctx;
-    SVN_JNI_ERR(svn_client_create_context(&ctx, pool), NULL);
-
-    const char *configDir = m_configDir.c_str();
-    if (m_configDir.length() == 0)
-        configDir = NULL;
-    SVN_JNI_ERR(svn_config_get_config(&(ctx->config), configDir, pool), NULL);
-    svn_config_t *config = (svn_config_t *) apr_hash_get(ctx->config,
-                                                         SVN_CONFIG_CATEGORY_CONFIG,
-                                                         APR_HASH_KEY_STRING);
-
-    /* The whole list of registered providers */
-    apr_array_header_t *providers;
-
-    /* Populate the registered providers with the platform-specific providers */
-    SVN_JNI_ERR(svn_auth_get_platform_specific_client_providers(&providers,
-                                                                config,
-                                                                pool),
-                NULL);
-
-    /* The main disk-caching auth providers, for both
-     * 'username/password' creds and 'username' creds.  */
-    svn_auth_provider_object_t *provider;
-
-    svn_auth_get_simple_provider(&provider, pool);
-    APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-    svn_auth_get_username_provider(&provider, pool);
-    APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-
-    /* The server-cert, client-cert, and client-cert-password providers. */
-    SVN_JNI_ERR(svn_auth_get_platform_specific_provider(&provider,
-                                                        "windows",
-                                                        "ssl_server_trust",
-                                                        pool),
-                NULL);
-
-    if (provider)
-        APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-
-    svn_auth_get_ssl_server_trust_file_provider(&provider, pool);
-    APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-    svn_auth_get_ssl_client_cert_file_provider(&provider, pool);
-    APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-    svn_auth_get_ssl_client_cert_pw_file_provider(&provider, pool);
-    APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-
-    if (m_prompter != NULL)
-    {
-        /* Two basic prompt providers: username/password, and just username.*/
-        provider = m_prompter->getProviderSimple();
-
-        APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-
-        provider = m_prompter->getProviderUsername();
-        APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-
-        /* Three ssl prompt providers, for server-certs, client-certs,
-         * and client-cert-passphrases.  */
-        provider = m_prompter->getProviderServerSSLTrust();
-        APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-
-        provider = m_prompter->getProviderClientSSL();
-        APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-
-        provider = m_prompter->getProviderClientSSLPassword();
-        APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
-    }
-
-    /* Build an authentication baton to give to libsvn_client. */
-    svn_auth_open(&ab, providers, pool);
-
-    /* Place any default --username or --password credentials into the
-     * auth_baton's run-time parameter hash.  ### Same with --no-auth-cache? */
-    if (!m_userName.empty())
-        svn_auth_set_parameter(ab, SVN_AUTH_PARAM_DEFAULT_USERNAME,
-                               m_userName.c_str());
-    if (!m_passWord.empty())
-        svn_auth_set_parameter(ab, SVN_AUTH_PARAM_DEFAULT_PASSWORD,
-                               m_passWord.c_str());
-
-    ctx->auth_baton = ab;
-    ctx->notify_func = NULL;
-    ctx->notify_baton = NULL;
-    ctx->log_msg_func3 = getCommitMessage;
-    ctx->log_msg_baton3 = getCommitMessageBaton(message);
-    ctx->cancel_func = checkCancel;
-    m_cancelOperation = false;
-    ctx->cancel_baton = this;
-    ctx->notify_func2= ClientNotifyCallback::notify;
-    ctx->notify_baton2 = m_notify2;
-
-    ctx->progress_func = ProgressListener::progress;
-    ctx->progress_baton = m_progressListener;
-
-    if (m_conflictResolver)
-    {
-        ctx->conflict_func = ConflictResolverCallback::resolveConflict;
-        ctx->conflict_baton = m_conflictResolver;
-    }
-
-    return ctx;
-}
-
-svn_error_t *
-SVNClient::getCommitMessage(const char **log_msg,
-                            const char **tmp_file,
-                            const apr_array_header_t *commit_items,
-                            void *baton,
-                            apr_pool_t *pool)
-{
-    *log_msg = NULL;
-    *tmp_file = NULL;
-    log_msg_baton *lmb = (log_msg_baton *) baton;
-
-    if (lmb && lmb->messageHandler)
-    {
-        jstring jmsg = lmb->messageHandler->getCommitMessage(commit_items);
-        if (jmsg != NULL)
-        {
-            JNIStringHolder msg(jmsg);
-            *log_msg = apr_pstrdup(pool, msg);
-        }
-        return SVN_NO_ERROR;
-    }
-    else if (lmb && lmb->message)
-    {
-        *log_msg = apr_pstrdup(pool, lmb->message);
-        return SVN_NO_ERROR;
-    }
-
-    return SVN_NO_ERROR;
-}
-
-void *SVNClient::getCommitMessageBaton(const char *message)
-{
-    if (message != NULL || m_commitMessage)
-    {
-        log_msg_baton *baton = (log_msg_baton *)
-            apr_palloc(JNIUtil::getRequestPool()->pool(), sizeof(*baton));
-
-        baton->message = message;
-        baton->messageHandler = m_commitMessage;
-
-        return baton;
-    }
-    return NULL;
-}
-
 jbyteArray SVNClient::fileContent(const char *path, Revision &revision,
                                   Revision &pegRevision)
 {
@@ -1420,7 +1219,7 @@ svn_stream_t *SVNClient::createReadStrea
     }
     else
     {
-        svn_client_ctx_t *ctx = getContext(NULL);
+        svn_client_ctx_t *ctx = context.getContext(NULL);
         if (ctx == NULL)
             return NULL;
 
@@ -1444,7 +1243,7 @@ jbyteArray SVNClient::revProperty(const 
     Path intPath(path);
     SVN_JNI_ERR(intPath.error_occured(), NULL);
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return NULL;
 
@@ -1489,7 +1288,7 @@ void SVNClient::relocate(const char *fro
     Path intTo(to);
     SVN_JNI_ERR(intTo.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -1509,7 +1308,7 @@ void SVNClient::blame(const char *path, 
     Path intPath(path);
     SVN_JNI_ERR(intPath.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -1523,47 +1322,11 @@ void SVNClient::blame(const char *path, 
         );
 }
 
-void SVNClient::setConfigDirectory(const char *configDir)
-{
-    // A change to the config directory may necessitate creation of
-    // the config templates.
-    SVN::Pool requestPool;
-    SVN_JNI_ERR(svn_config_ensure(configDir, requestPool.pool()), );
-
-    m_configDir = (configDir == NULL ? "" : configDir);
-}
-
-const char *SVNClient::getConfigDirectory()
-{
-    return m_configDir.c_str();
-}
-
-void SVNClient::commitMessageHandler(CommitMessage *commitMessage)
-{
-    delete m_commitMessage;
-    m_commitMessage = commitMessage;
-}
-
-void SVNClient::cancelOperation()
-{
-    m_cancelOperation = true;
-}
-
-svn_error_t *SVNClient::checkCancel(void *cancelBaton)
-{
-    SVNClient *that = (SVNClient*)cancelBaton;
-    if (that->m_cancelOperation)
-        return svn_error_create(SVN_ERR_CANCELLED, NULL,
-                                _("Operation canceled"));
-    else
-        return SVN_NO_ERROR;
-}
-
 void SVNClient::addToChangelist(Targets &srcPaths, const char *changelist,
                                 svn_depth_t depth, StringArray &changelists)
 {
     SVN::Pool requestPool;
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
 
     const apr_array_header_t *srcs = srcPaths.array(requestPool);
     SVN_JNI_ERR(srcPaths.error_occured(), );
@@ -1577,7 +1340,7 @@ void SVNClient::removeFromChangelists(Ta
                                       StringArray &changelists)
 {
     SVN::Pool requestPool;
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
 
     const apr_array_header_t *srcs = srcPaths.array(requestPool);
     SVN_JNI_ERR(srcPaths.error_occured(), );
@@ -1593,7 +1356,7 @@ void SVNClient::getChangelists(const cha
                                ChangelistCallback *callback)
 {
     SVN::Pool requestPool;
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
 
     SVN_JNI_ERR(svn_client_get_changelists(rootPath,
                                            changelists.array(requestPool),
@@ -1607,7 +1370,7 @@ void SVNClient::lock(Targets &targets, c
     SVN::Pool requestPool;
     const apr_array_header_t *targetsApr = targets.array(requestPool);
     SVN_JNI_ERR(targets.error_occured(), );
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
 
     SVN_JNI_ERR(svn_client_lock(targetsApr, comment, force, ctx,
                                 requestPool.pool()), );
@@ -1619,7 +1382,7 @@ void SVNClient::unlock(Targets &targets,
 
     const apr_array_header_t *targetsApr = targets.array(requestPool);
     SVN_JNI_ERR(targets.error_occured(), );
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     SVN_JNI_ERR(svn_client_unlock((apr_array_header_t*)targetsApr, force,
                                   ctx, requestPool.pool()), );
 }
@@ -1634,7 +1397,7 @@ void SVNClient::setRevProperty(const cha
     Path intPath(path);
     SVN_JNI_ERR(intPath.error_occured(), );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -1673,7 +1436,7 @@ jstring SVNClient::getVersionInfo(const 
     SVN_JNI_ERR(intPath.error_occured(), NULL);
 
     int wc_format;
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return NULL;
     SVN_JNI_ERR(svn_wc_check_wc2(&wc_format, ctx->wc_ctx, intPath.c_str(),
@@ -1732,7 +1495,7 @@ void SVNClient::upgrade(const char *path
     SVN::Pool requestPool;
     SVN_JNI_NULL_PTR_EX(path, "path", );
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -1750,7 +1513,7 @@ jobject SVNClient::revProperties(const c
     Path intPath(path);
     SVN_JNI_ERR(intPath.error_occured(), NULL);
 
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     const char *URL;
     svn_revnum_t set_rev;
     SVN_JNI_ERR(svn_client_url_from_path2(&URL, intPath.c_str(), ctx,
@@ -1783,7 +1546,7 @@ SVNClient::info2(const char *path, Revis
     SVN_JNI_NULL_PTR_EX(path, "path", );
 
     SVN::Pool requestPool;
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -1808,7 +1571,7 @@ SVNClient::patch(const char *patchPath, 
     SVN_JNI_NULL_PTR_EX(targetPath, "targetPath", );
 
     SVN::Pool requestPool;
-    svn_client_ctx_t *ctx = getContext(NULL);
+    svn_client_ctx_t *ctx = context.getContext(NULL);
     if (ctx == NULL)
         return;
 
@@ -1825,3 +1588,9 @@ SVNClient::patch(const char *patchPath, 
                                  ctx, requestPool.pool(),
                                  requestPool.pool()), );
 }
+
+ClientContext &
+SVNClient::getClientContext()
+{
+    return context;
+}

Modified: subversion/branches/performance/subversion/bindings/javahl/native/SVNClient.h
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/native/SVNClient.h?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/native/SVNClient.h (original)
+++ subversion/branches/performance/subversion/bindings/javahl/native/SVNClient.h Mon Sep  6 20:02:15 2010
@@ -31,12 +31,10 @@
 #include <string>
 #include <jni.h>
 #include "Path.h"
+#include "ClientContext.h"
 
 class Revision;
 class RevisionRange;
-class ClientNotifyCallback;
-class ConflictResolverCallback;
-class ProgressListener;
 class Targets;
 class JNIByteArray;
 class Prompter;
@@ -46,6 +44,7 @@ class BlameCallback;
 class ProplistCallback;
 class LogMessageCallback;
 class InfoCallback;
+class CommitCallback;
 class ListCallback;
 class StatusCallback;
 class PatchCallback;
@@ -69,16 +68,6 @@ class SVNClient :public SVNBase
   void unlock(Targets &targets, bool force);
   void lock(Targets &targets, const char *comment, bool force);
   jobject revProperties(const char *path, Revision &revision);
-  void cancelOperation();
-  void commitMessageHandler(CommitMessage *commitMessage);
-  const char *getConfigDirectory();
-
-  /**
-   * Set the configuration directory, taking the usual steps to
-   * ensure that Subversion's config file templates exist in the
-   * specified location.
-   */
-  void setConfigDirectory(const char *configDir);
 
   void blame(const char *path, Revision &pegRevision,
              Revision &revisionStart, Revision &revisionEnd,
@@ -93,7 +82,7 @@ class SVNClient :public SVNBase
                          size_t bufSize);
   void propertySet(const char *path, const char *name, const char *value,
                    svn_depth_t depth, StringArray &changelists, bool force,
-                   RevpropTable &revprops);
+                   RevpropTable &revprops, CommitCallback *callback);
   void properties(const char *path, Revision &revision,
                   Revision &pegRevision, svn_depth_t depth,
                   StringArray &changelists, ProplistCallback *callback);
@@ -114,9 +103,9 @@ class SVNClient :public SVNBase
              bool ignoreAncestry, bool dryRun, bool recordOnly);
   void mergeReintegrate(const char *path, Revision &pegRevision,
                         const char *localPath, bool dryRun);
-  void doImport(const char *path, const char *url, const char *message,
+  void doImport(const char *path, const char *url, CommitMessage *message,
                 svn_depth_t depth, bool noIgnore, bool ignoreUnknownNodeTypes,
-                RevpropTable &revprops);
+                RevpropTable &revprops, CommitCallback *callback);
   jlong doSwitch(const char *path, const char *url, Revision &revision,
                  Revision &pegRevision, svn_depth_t depth,
                  bool depthIsSticky, bool ignoreExternals,
@@ -128,28 +117,28 @@ class SVNClient :public SVNBase
   void resolve(const char *path, svn_depth_t depth,
                svn_wc_conflict_choice_t choice);
   void cleanup(const char *path);
-  void mkdir(Targets &targets, const char *message, bool makeParents,
-             RevpropTable &revprops);
+  void mkdir(Targets &targets, CommitMessage *message, bool makeParents,
+             RevpropTable &revprops, CommitCallback *callback);
   void move(Targets &srcPaths, const char *destPath,
-            const char *message, bool force, bool moveAsChild,
-            bool makeParents, RevpropTable &revprops);
+            CommitMessage *message, bool force, bool moveAsChild,
+            bool makeParents, RevpropTable &revprops, CommitCallback *callback);
   void copy(CopySources &copySources, const char *destPath,
-            const char *message, bool copyAsChild, bool makeParents,
-            bool ignoreExternals, RevpropTable &revprops);
-  jlong commit(Targets &targets, const char *message, svn_depth_t depth,
-               bool noUnlock, bool keepChangelist,
-               StringArray &changelists, RevpropTable &revprops);
+            CommitMessage *message, bool copyAsChild, bool makeParents,
+            bool ignoreExternals, RevpropTable &revprops,
+            CommitCallback *callback);
+  void commit(Targets &targets, CommitMessage *message, svn_depth_t depth,
+              bool noUnlock, bool keepChangelist,
+              StringArray &changelists, RevpropTable &revprops,
+              CommitCallback *callback);
   jlongArray update(Targets &targets, Revision &revision, svn_depth_t depth,
                     bool depthIsSticky, bool ignoreExternals,
                     bool allowUnverObstructions);
   void add(const char *path, svn_depth_t depth, bool force, bool no_ignore,
            bool add_parents);
   void revert(const char *path, svn_depth_t depth, StringArray &changelists);
-  void remove(Targets &targets, const char *message, bool force,
-              bool keep_local, RevpropTable &revprops);
-  void notification2(ClientNotifyCallback *notify2);
-  void setConflictResolver(ConflictResolverCallback *conflictResolver);
-  void setProgressListener(ProgressListener *progressListener);
+  void remove(Targets &targets, CommitMessage *message, bool force,
+              bool keep_local, RevpropTable &revprops,
+              CommitCallback *callback);
   jlong checkout(const char *moduleName, const char *destPath,
                  Revision &revision, Revision &pegRevsion, svn_depth_t depth,
                  bool ignoreExternals, bool allowUnverObstructions);
@@ -158,9 +147,6 @@ class SVNClient :public SVNBase
                    bool discoverPaths, bool includeMergedRevisions,
                    StringArray &revProps,
                    long limit, LogMessageCallback *callback);
-  void setPrompt(Prompter *prompter);
-  void password(const char *pi_password);
-  void username(const char *pi_username);
   jstring getAdminDirectoryName();
   jboolean isAdminDirectory(const char *name);
   void addToChangelist(Targets &srcPaths, const char *changelist,
@@ -205,14 +191,14 @@ class SVNClient :public SVNBase
                      svn_depth_t depth, StringArray &changelists,
                      bool ignoreAncestry, DiffSummaryReceiver &receiver);
 
+  ClientContext &getClientContext();
+
   const char *getLastPath();
-  void dispose(jobject jthis);
+  void dispose();
   static SVNClient *getCppObject(jobject jthis);
-  SVNClient();
+  SVNClient(jobject jthis_in);
   virtual ~SVNClient();
  private:
-  static svn_error_t *checkCancel(void *cancelBaton);
-  svn_client_ctx_t *getContext(const char *message);
   svn_stream_t *createReadStream(apr_pool_t *pool, const char *path,
                                  Revision &revision, Revision &pegRevision,
                                  size_t &size);
@@ -228,31 +214,8 @@ class SVNClient :public SVNBase
             bool ignoreAncestry, bool noDiffDelete, bool force,
             bool showCopiesAsAdds);
 
-  ClientNotifyCallback *m_notify2;
-  ConflictResolverCallback *m_conflictResolver;
-  ProgressListener *m_progressListener;
-  Prompter *m_prompter;
   Path m_lastPath;
-  bool m_cancelOperation;
-  CommitMessage *m_commitMessage;
-
-  /**
-   * Implements the svn_client_get_commit_log3_t API.
-   */
-  static svn_error_t *getCommitMessage(const char **log_msg,
-                                       const char **tmp_file,
-                                       const apr_array_header_t *
-                                       commit_items,
-                                       void *baton,
-                                       apr_pool_t *pool);
-  /**
-   * Produce a baton for the getCommitMessage() callback.
-   */
-  void *getCommitMessageBaton(const char *message);
-
-  std::string m_userName;
-  std::string m_passWord;
-  std::string m_configDir;
+  ClientContext context;
 };
 
 #endif // SVNCLIENT_H

Modified: subversion/branches/performance/subversion/bindings/javahl/native/SVNRepos.cpp
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/native/SVNRepos.cpp?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/native/SVNRepos.cpp (original)
+++ subversion/branches/performance/subversion/bindings/javahl/native/SVNRepos.cpp Mon Sep  6 20:02:15 2010
@@ -53,10 +53,10 @@ SVNRepos *SVNRepos::getCppObject(jobject
   return (cppAddr == 0 ? NULL : reinterpret_cast<SVNRepos *>(cppAddr));
 }
 
-void SVNRepos::dispose(jobject jthis)
+void SVNRepos::dispose()
 {
   static jfieldID fid = 0;
-  SVNBase::dispose(jthis, &fid, JAVA_PACKAGE"/SVNRepos");
+  SVNBase::dispose(&fid, JAVA_PACKAGE"/SVNRepos");
 }
 
 void SVNRepos::create(File &path, bool disableFsyncCommits,
@@ -613,7 +613,7 @@ void SVNRepos::upgrade(File &path, Repos
               );
 }
 
-jobject SVNRepos::lslocks(File &path)
+jobject SVNRepos::lslocks(File &path, svn_depth_t depth)
 {
   SVN::Pool requestPool;
   svn_repos_t *repos;
@@ -631,8 +631,8 @@ jobject SVNRepos::lslocks(File &path)
                              requestPool.pool()), NULL);
   fs = svn_repos_fs (repos);
   /* Fetch all locks on or below the root directory. */
-  SVN_JNI_ERR(svn_repos_fs_get_locks(&locks, repos, "/", NULL, NULL,
-                                     requestPool.pool()),
+  SVN_JNI_ERR(svn_repos_fs_get_locks2(&locks, repos, "/", depth, NULL, NULL,
+                                      requestPool.pool()),
               NULL);
 
   JNIEnv *env = JNIUtil::getEnv();

Modified: subversion/branches/performance/subversion/bindings/javahl/native/SVNRepos.h
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/native/SVNRepos.h?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/native/SVNRepos.h (original)
+++ subversion/branches/performance/subversion/bindings/javahl/native/SVNRepos.h Mon Sep  6 20:02:15 2010
@@ -42,7 +42,7 @@ class SVNRepos : public SVNBase
 {
  public:
   void rmlocks(File &path, StringArray &locks);
-  jobject lslocks(File &path);
+  jobject lslocks(File &path, svn_depth_t depth);
   void verify(File &path, Revision &revisionStart, Revision &revisionEnd,
               ReposNotifyCallback *notifyCallback);
   void setRevProp(File &path, Revision &revision,
@@ -69,7 +69,7 @@ class SVNRepos : public SVNBase
   void pack(File &path, ReposNotifyCallback *callback);
   SVNRepos();
   virtual ~SVNRepos();
-  void dispose(jobject jthis);
+  void dispose();
   static SVNRepos *getCppObject(jobject jthis);
 
  private:

Modified: subversion/branches/performance/subversion/bindings/javahl/native/org_apache_subversion_javahl_SVNClient.cpp
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/native/org_apache_subversion_javahl_SVNClient.cpp?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/native/org_apache_subversion_javahl_SVNClient.cpp (original)
+++ subversion/branches/performance/subversion/bindings/javahl/native/org_apache_subversion_javahl_SVNClient.cpp Mon Sep  6 20:02:15 2010
@@ -33,9 +33,6 @@
 #include "Revision.h"
 #include "RevisionRange.h"
 #include "EnumMapper.h"
-#include "ClientNotifyCallback.h"
-#include "ConflictResolverCallback.h"
-#include "ProgressListener.h"
 #include "CommitMessage.h"
 #include "Prompter.h"
 #include "Targets.h"
@@ -44,6 +41,7 @@
 #include "BlameCallback.h"
 #include "ProplistCallback.h"
 #include "PatchCallback.h"
+#include "CommitCallback.h"
 #include "LogMessageCallback.h"
 #include "InfoCallback.h"
 #include "StatusCallback.h"
@@ -61,7 +59,7 @@ Java_org_apache_subversion_javahl_SVNCli
 (JNIEnv *env, jobject jthis)
 {
   JNIEntry(SVNClient, ctNative);
-  SVNClient *obj = new SVNClient;
+  SVNClient *obj = new SVNClient(jthis);
   return obj->getCppAddr();
 }
 
@@ -76,7 +74,7 @@ Java_org_apache_subversion_javahl_SVNCli
       JNIUtil::throwError(_("bad C++ this"));
       return;
     }
-  cl->dispose(jthis);
+  cl->dispose();
 }
 
 JNIEXPORT void JNICALL
@@ -212,7 +210,7 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
-  cl->username(username);
+  cl->getClientContext().username(username);
 }
 
 JNIEXPORT void JNICALL
@@ -236,7 +234,7 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
-  cl->password(password);
+  cl->getClientContext().password(password);
 }
 
 JNIEXPORT void JNICALL
@@ -254,7 +252,7 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
-  cl->setPrompt(prompter);
+  cl->getClientContext().setPrompt(prompter);
 }
 
 JNIEXPORT void JNICALL
@@ -345,84 +343,10 @@ Java_org_apache_subversion_javahl_SVNCli
 }
 
 JNIEXPORT void JNICALL
-Java_org_apache_subversion_javahl_SVNClient_notification2
-(JNIEnv *env, jobject jthis, jobject jnotify2)
-{
-  JNIEntry(SVNClient, notification2);
-  SVNClient *cl = SVNClient::getCppObject(jthis);
-  if (cl == NULL)
-    {
-      JNIUtil::throwError(_("bad C++ this"));
-      return;
-    }
-  ClientNotifyCallback *notify2 = ClientNotifyCallback::makeCNotify(jnotify2);
-  if (JNIUtil::isExceptionThrown())
-    return;
-
-  cl->notification2(notify2);
-}
-
-JNIEXPORT void JNICALL
-Java_org_apache_subversion_javahl_SVNClient_setConflictResolver
-(JNIEnv *env, jobject jthis, jobject jconflictResolver)
-{
-  JNIEntry(SVNClient, setConflictResolver);
-  SVNClient *cl = SVNClient::getCppObject(jthis);
-  if (cl == NULL)
-    {
-      JNIUtil::throwError(_("bad C++ this"));
-      return;
-    }
-  ConflictResolverCallback *listener =
-    ConflictResolverCallback::makeCConflictResolverCallback(jconflictResolver);
-  if (JNIUtil::isExceptionThrown())
-    return;
-
-  cl->setConflictResolver(listener);
-}
-
-JNIEXPORT void JNICALL
-Java_org_apache_subversion_javahl_SVNClient_setProgressListener
-(JNIEnv *env, jobject jthis, jobject jprogressListener)
-{
-  JNIEntry(SVNClient, setProgressListener);
-  SVNClient *cl = SVNClient::getCppObject(jthis);
-  if (cl == NULL)
-    {
-      JNIUtil::throwError(_("bad C++ this"));
-      return;
-    }
-  ProgressListener *listener =
-    ProgressListener::makeCProgressListener(jprogressListener);
-  if (JNIUtil::isExceptionThrown())
-    return;
-
-  cl->setProgressListener(listener);
-}
-
-JNIEXPORT void JNICALL
-Java_org_apache_subversion_javahl_SVNClient_commitMessageHandler
-(JNIEnv *env, jobject jthis, jobject jcommitMessage)
-{
-  JNIEntry(SVNClient, commitMessageHandler);
-  SVNClient *cl = SVNClient::getCppObject(jthis);
-  if (cl == NULL)
-    {
-      JNIUtil::throwError("bad C++ this");
-      return;
-    }
-  CommitMessage *commitMessage =
-    CommitMessage::makeCCommitMessage(jcommitMessage);
-  if (JNIUtil::isExceptionThrown())
-    return;
-
-  cl->commitMessageHandler(commitMessage);
-}
-
-JNIEXPORT void JNICALL
 Java_org_apache_subversion_javahl_SVNClient_remove
-(JNIEnv *env, jobject jthis, jobject jtargets, jstring jmessage,
- jboolean jforce, jboolean keepLocal, jobject jrevpropTable)
+(JNIEnv *env, jobject jthis, jobject jtargets, jboolean jforce,
+ jboolean keepLocal, jobject jrevpropTable, jobject jmessage,
+ jobject jcallback)
 {
   JNIEntry(SVNClient, remove);
   SVNClient *cl = SVNClient::getCppObject(jthis);
@@ -433,7 +357,10 @@ Java_org_apache_subversion_javahl_SVNCli
     }
   StringArray targetsArr(jtargets);
   Targets targets(targetsArr);
-  JNIStringHolder message(jmessage);
+  if (JNIUtil::isExceptionThrown())
+    return;
+
+  CommitMessage message(jmessage);
   if (JNIUtil::isExceptionThrown())
     return;
 
@@ -441,8 +368,9 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
-  cl->remove(targets, message, jforce ? true : false,
-             keepLocal ? true : false, revprops);
+  CommitCallback callback(jcallback);
+  cl->remove(targets, &message, jforce ? true : false,
+             keepLocal ? true : false, revprops, jcallback ? &callback : NULL);
 }
 
 JNIEXPORT void JNICALL
@@ -516,44 +444,49 @@ Java_org_apache_subversion_javahl_SVNCli
                     jallowUnverObstructions ? true : false);
 }
 
-JNIEXPORT jlong JNICALL
+JNIEXPORT void JNICALL
 Java_org_apache_subversion_javahl_SVNClient_commit
-(JNIEnv *env, jobject jthis, jobject jtargets, jstring jmessage, jobject jdepth,
+(JNIEnv *env, jobject jthis, jobject jtargets, jobject jdepth,
  jboolean jnoUnlock, jboolean jkeepChangelist, jobject jchangelists,
- jobject jrevpropTable)
+ jobject jrevpropTable, jobject jmessage, jobject jcallback)
 {
   JNIEntry(SVNClient, commit);
   SVNClient *cl = SVNClient::getCppObject(jthis);
   if (cl == NULL)
     {
       JNIUtil::throwError(_("bad C++ this"));
-      return -1;
+      return;
     }
   StringArray targetsArr(jtargets);
   Targets targets(targetsArr);
-  JNIStringHolder message(jmessage);
   if (JNIUtil::isExceptionThrown())
-    return -1;
+    return;
+
+  CommitMessage message(jmessage);
+  if (JNIUtil::isExceptionThrown())
+    return;
 
   // Build the changelist vector from the Java array.
   StringArray changelists(jchangelists);
   if (JNIUtil::isExceptionThrown())
-    return -1;
+    return;
 
   RevpropTable revprops(jrevpropTable);
   if (JNIUtil::isExceptionThrown())
-    return -1;
+    return;
 
-  return cl->commit(targets, message, EnumMapper::toDepth(jdepth),
-                    jnoUnlock ? true : false, jkeepChangelist ? true : false,
-                    changelists, revprops);
+  CommitCallback callback(jcallback);
+  cl->commit(targets, &message, EnumMapper::toDepth(jdepth),
+             jnoUnlock ? true : false, jkeepChangelist ? true : false,
+             changelists, revprops,
+             jcallback ? &callback : NULL);
 }
 
 JNIEXPORT void JNICALL
 Java_org_apache_subversion_javahl_SVNClient_copy
 (JNIEnv *env, jobject jthis, jobject jcopySources, jstring jdestPath,
- jstring jmessage, jboolean jcopyAsChild, jboolean jmakeParents,
- jboolean jignoreExternals, jobject jrevpropTable)
+ jboolean jcopyAsChild, jboolean jmakeParents, jboolean jignoreExternals,
+ jobject jrevpropTable, jobject jmessage, jobject jcallback)
 {
   JNIEntry(SVNClient, copy);
 
@@ -575,7 +508,7 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
-JNIStringHolder message(jmessage);
+  CommitMessage message(jmessage);
   if (JNIUtil::isExceptionThrown())
     return;
 
@@ -583,16 +516,17 @@ JNIStringHolder message(jmessage);
   if (JNIUtil::isExceptionThrown())
     return;
 
-  cl->copy(copySources, destPath, message, jcopyAsChild ? true : false,
+  CommitCallback callback(jcallback);
+  cl->copy(copySources, destPath, &message, jcopyAsChild ? true : false,
            jmakeParents ? true : false, jignoreExternals ? true : false,
-           revprops);
+           revprops, jcallback ? &callback : NULL);
 }
 
 JNIEXPORT void JNICALL
 Java_org_apache_subversion_javahl_SVNClient_move
 (JNIEnv *env, jobject jthis, jobject jsrcPaths, jstring jdestPath,
- jstring jmessage, jboolean jforce, jboolean jmoveAsChild,
- jboolean jmakeParents, jobject jrevpropTable)
+ jboolean jforce, jboolean jmoveAsChild, jboolean jmakeParents,
+ jobject jrevpropTable, jobject jmessage, jobject jcallback)
 {
   JNIEntry(SVNClient, move);
 
@@ -609,7 +543,8 @@ Java_org_apache_subversion_javahl_SVNCli
   JNIStringHolder destPath(jdestPath);
   if (JNIUtil::isExceptionThrown())
     return;
-  JNIStringHolder message(jmessage);
+
+  CommitMessage message(jmessage);
   if (JNIUtil::isExceptionThrown())
     return;
 
@@ -617,15 +552,16 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
-  cl->move(srcPaths, destPath, message, jforce ? true : false,
+  CommitCallback callback(jcallback);
+  cl->move(srcPaths, destPath, &message, jforce ? true : false,
            jmoveAsChild ? true : false, jmakeParents ? true : false,
-           revprops);
+           revprops, jcallback ? &callback : NULL);
 }
 
 JNIEXPORT void JNICALL
 Java_org_apache_subversion_javahl_SVNClient_mkdir
-(JNIEnv *env, jobject jthis, jobject jtargets, jstring jmessage,
- jboolean jmakeParents, jobject jrevpropTable)
+(JNIEnv *env, jobject jthis, jobject jtargets, jboolean jmakeParents,
+ jobject jrevpropTable, jobject jmessage, jobject jcallback)
 {
   JNIEntry(SVNClient, mkdir);
   SVNClient *cl = SVNClient::getCppObject(jthis);
@@ -636,7 +572,10 @@ Java_org_apache_subversion_javahl_SVNCli
     }
   StringArray targetsArr(jtargets);
   Targets targets(targetsArr);
-  JNIStringHolder message(jmessage);
+  if (JNIUtil::isExceptionThrown())
+    return;
+
+  CommitMessage message(jmessage);
   if (JNIUtil::isExceptionThrown())
     return;
 
@@ -644,7 +583,9 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
-  cl->mkdir(targets, message, jmakeParents ? true : false, revprops);
+  CommitCallback callback(jcallback);
+  cl->mkdir(targets, &message, jmakeParents ? true : false, revprops,
+            jcallback ? &callback : NULL);
 }
 
 JNIEXPORT void JNICALL
@@ -760,9 +701,9 @@ Java_org_apache_subversion_javahl_SVNCli
 
 JNIEXPORT void JNICALL
 Java_org_apache_subversion_javahl_SVNClient_doImport
-(JNIEnv *env, jobject jthis, jstring jpath, jstring jurl, jstring jmessage,
- jobject jdepth, jboolean jnoIgnore, jboolean jignoreUnknownNodeTypes,
- jobject jrevpropTable)
+(JNIEnv *env, jobject jthis, jstring jpath, jstring jurl, jobject jdepth,
+ jboolean jnoIgnore, jboolean jignoreUnknownNodeTypes, jobject jrevpropTable,
+ jobject jmessage, jobject jcallback)
 {
   JNIEntry(SVNClient, doImport);
   SVNClient *cl = SVNClient::getCppObject(jthis);
@@ -779,7 +720,7 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
-  JNIStringHolder message(jmessage);
+  CommitMessage message(jmessage);
   if (JNIUtil::isExceptionThrown())
     return;
 
@@ -787,9 +728,11 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
-  cl->doImport(path, url, message, EnumMapper::toDepth(jdepth),
+  CommitCallback callback(jcallback);
+  cl->doImport(path, url, &message, EnumMapper::toDepth(jdepth),
                jnoIgnore ? true : false,
-               jignoreUnknownNodeTypes ? true : false, revprops);
+               jignoreUnknownNodeTypes ? true : false, revprops,
+               jcallback ? &callback : NULL);
 }
 
 JNIEXPORT jobject JNICALL
@@ -971,7 +914,8 @@ Java_org_apache_subversion_javahl_SVNCli
 JNIEXPORT void JNICALL
 Java_org_apache_subversion_javahl_SVNClient_propertySet
 (JNIEnv *env, jobject jthis, jstring jpath, jstring jname, jstring jvalue,
- jobject jdepth, jobject jchangelists, jboolean jforce, jobject jrevpropTable)
+ jobject jdepth, jobject jchangelists, jboolean jforce, jobject jrevpropTable,
+ jobject jcallback)
 {
   JNIEntry(SVNClient, propertySet);
   SVNClient *cl = SVNClient::getCppObject(jthis);
@@ -1000,8 +944,9 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
+  CommitCallback callback(jcallback);
   cl->propertySet(path, name, value, EnumMapper::toDepth(jdepth), changelists,
-                  jforce ? true:false, revprops);
+                  jforce ? true:false, revprops, jcallback ? &callback : NULL);
 }
 
 JNIEXPORT jbyteArray JNICALL
@@ -1576,7 +1521,7 @@ Java_org_apache_subversion_javahl_SVNCli
   if (JNIUtil::isExceptionThrown())
     return;
 
-  cl->setConfigDirectory(configDir);
+  cl->getClientContext().setConfigDirectory(configDir);
 }
 
 JNIEXPORT jstring JNICALL
@@ -1591,7 +1536,7 @@ Java_org_apache_subversion_javahl_SVNCli
       return NULL;
     }
 
-  const char *configDir = cl->getConfigDirectory();
+  const char *configDir = cl->getClientContext().getConfigDirectory();
   return JNIUtil::makeJString(configDir);
 }
 
@@ -1606,7 +1551,7 @@ Java_org_apache_subversion_javahl_SVNCli
       JNIUtil::throwError("bad C++ this");
       return;
     }
-  cl->cancelOperation();
+  cl->getClientContext().cancelOperation();
 }
 
 JNIEXPORT void JNICALL

Modified: subversion/branches/performance/subversion/bindings/javahl/native/org_apache_subversion_javahl_SVNRepos.cpp
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/native/org_apache_subversion_javahl_SVNRepos.cpp?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/native/org_apache_subversion_javahl_SVNRepos.cpp (original)
+++ subversion/branches/performance/subversion/bindings/javahl/native/org_apache_subversion_javahl_SVNRepos.cpp Mon Sep  6 20:02:15 2010
@@ -30,6 +30,7 @@
 #include "JNIStringHolder.h"
 #include "JNIByteArray.h"
 #include "SVNRepos.h"
+#include "EnumMapper.h"
 #include "Revision.h"
 #include "InputStream.h"
 #include "OutputStream.h"
@@ -59,7 +60,7 @@ Java_org_apache_subversion_javahl_SVNRep
       JNIUtil::throwError(_("bad C++ this"));
       return;
     }
-  cl->dispose(jthis);
+  cl->dispose();
 }
 
 JNIEXPORT void JNICALL
@@ -407,7 +408,7 @@ Java_org_apache_subversion_javahl_SVNRep
 
 JNIEXPORT jobject JNICALL
 Java_org_apache_subversion_javahl_SVNRepos_lslocks
-(JNIEnv *env, jobject jthis, jobject jpath)
+(JNIEnv *env, jobject jthis, jobject jpath, jobject jdepth)
 {
   JNIEntry(SVNRepos, lslocks);
   SVNRepos *cl = SVNRepos::getCppObject(jthis);
@@ -421,7 +422,7 @@ Java_org_apache_subversion_javahl_SVNRep
   if (JNIUtil::isExceptionThrown())
     return NULL;
 
-  return cl->lslocks(path);
+  return cl->lslocks(path, EnumMapper::toDepth(jdepth));
 }
 
 JNIEXPORT void JNICALL

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ClientNotifyInformation.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ClientNotifyInformation.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ClientNotifyInformation.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ClientNotifyInformation.java Mon Sep  6 20:02:15 2010
@@ -25,10 +25,11 @@ package org.apache.subversion.javahl;
 
 import java.util.Map;
 import java.util.EventObject;
+import org.apache.subversion.javahl.callback.ClientNotifyCallback;
 
 /**
- * The event passed to the {@link Notify2#onNotify(NotifyInformation)}
- * API to notify {@link SVNClientInterface} of relevant events.
+ * The event passed to the {@link ClientNotifyCallback#onNotify}
+ * API to notify {@link ISVNClient} of relevant events.
  *
  * @since 1.2
  */
@@ -44,7 +45,7 @@ public class ClientNotifyInformation ext
     private static final long serialVersionUID = 1L;
 
     /**
-     * The {@link NotifyAction} which triggered this event.
+     * The {@link Action} which triggered this event.
      */
     private Action action;
 
@@ -69,12 +70,12 @@ public class ClientNotifyInformation ext
     private String errMsg;
 
     /**
-     * The {@link NotifyStatus} of the content of the item.
+     * The {@link Status} of the content of the item.
      */
     private Status contentState;
 
     /**
-     * The {@link NotifyStatus} of the properties of the item.
+     * The {@link Status} of the properties of the item.
      */
     private Status propState;
 
@@ -128,14 +129,14 @@ public class ClientNotifyInformation ext
      * This constructor is to be used by the native code.
      *
      * @param path The path of the item, which is the source of the event.
-     * @param action The {@link NotifyAction} which triggered this event.
+     * @param action The {@link Action} which triggered this event.
      * @param kind The {@link NodeKind} of the item.
      * @param mimeType The MIME type of the item.
      * @param lock Any lock for the item.
      * @param errMsg Any error message for the item.
-     * @param contentState The {@link NotifyStatus} of the content of
+     * @param contentState The {@link Status} of the content of
      * the item.
-     * @param propState The {@link NotifyStatus} of the properties of
+     * @param propState The {@link Status} of the properties of
      * the item.
      * @param lockState The {@link LockStatus} of the lock of the item.
      * @param revision The revision of the item.
@@ -187,7 +188,7 @@ public class ClientNotifyInformation ext
     }
 
     /**
-     * @return The {@link NotifyAction} which triggered this event.
+     * @return The {@link Action} which triggered this event.
      */
     public Action getAction()
     {
@@ -227,7 +228,7 @@ public class ClientNotifyInformation ext
     }
 
     /**
-     * @return The {@link NotifyStatus} of the content of the item.
+     * @return The {@link Status} of the content of the item.
      */
     public Status getContentState()
     {
@@ -235,7 +236,7 @@ public class ClientNotifyInformation ext
     }
 
     /**
-     * @return The {@link NotifyStatus} of the properties of the item.
+     * @return The {@link Status} of the properties of the item.
      */
     public Status getPropState()
     {

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/CommitItem.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/CommitItem.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/CommitItem.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/CommitItem.java Mon Sep  6 20:02:15 2010
@@ -23,6 +23,8 @@
 
 package org.apache.subversion.javahl;
 
+import java.net.URI;
+
 /**
  * This class describes a item which will be commited.
  */
@@ -55,12 +57,12 @@ public class CommitItem implements java.
     /**
      * the url of the item
      */
-    String url;
+    URI url;
 
     /**
      * the source of the copy
      */
-    String copyUrl;
+    URI copyUrl;
 
     /**
      * the revision
@@ -76,7 +78,7 @@ public class CommitItem implements java.
      * @param cu    copy source url
      * @param r     revision number
      */
-    public CommitItem(String p, NodeKind nk, int sf, String u, String cu, long r)
+    public CommitItem(String p, NodeKind nk, int sf, URI u, URI cu, long r)
     {
         path = p;
         nodeKind = nk;
@@ -125,7 +127,7 @@ public class CommitItem implements java.
      * Returns the url of the item
      * @return url
      */
-    public String getUrl()
+    public URI getUrl()
     {
         return url;
     }
@@ -134,7 +136,7 @@ public class CommitItem implements java.
      * Returns the source url if the item is copied
      * @return source url
      */
-    public String getCopyUrl()
+    public URI getCopyUrl()
     {
         return copyUrl;
     }

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/DiffSummary.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/DiffSummary.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/DiffSummary.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/DiffSummary.java Mon Sep  6 20:02:15 2010
@@ -24,11 +24,11 @@
 package org.apache.subversion.javahl;
 
 import java.util.EventObject;
+import org.apache.subversion.javahl.callback.DiffSummaryCallback;
 
 /**
- * The event passed to the {@link
- * DiffSummaryReceiver#onSummary(DiffSummary)} API in response to path
- * differences reported by {@link SVNClientInterface#diffSummarize}.
+ * The event passed to the {@link DiffSummaryCallback#onSummary} API
+ * in response to path differences reported by {@link ISVNClient#diffSummarize}.
  *
  * @since 1.5
  */

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/DirEntry.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/DirEntry.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/DirEntry.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/DirEntry.java Mon Sep  6 20:02:15 2010
@@ -26,7 +26,7 @@ package org.apache.subversion.javahl;
 import java.util.Date;
 
 /**
- * A general subversion directory entry. Used for SVNClientInterface.list
+ * A general subversion directory entry. Used for {@link ISVNClient#list}.
  */
 public class DirEntry implements java.io.Serializable
 {

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNClient.java Mon Sep  6 20:02:15 2010
@@ -198,15 +198,6 @@ public interface ISVNClient
     void setProgressCallback(ProgressCallback listener);
 
     /**
-     * Sets the commit message handler. This allows more complex commit message
-     * with the list of the elements to be commited as input.
-     * @param messageHandler    callback for entering commit messages
-     *                          if this is set the message parameter is ignored.
-     * @since 1.0
-     */
-    void commitMessageHandler(CommitMessage messageHandler);
-
-    /**
      * Sets a file for deletion.
      * @param path      path or url to be deleted
      * @param message   if path is a url, this will be the commit message.
@@ -218,8 +209,9 @@ public interface ISVNClient
      * @throws ClientException
      * @since 1.5
      */
-    void remove(Set<String> path, String message, boolean force,
-                boolean keepLocal, Map<String, String> revpropTable)
+    void remove(Set<String> path, boolean force, boolean keepLocal,
+                Map<String, String> revpropTable, CommitMessageCallback handler,
+                CommitCallback callback)
             throws ClientException;
 
     /**
@@ -284,10 +276,10 @@ public interface ISVNClient
      * @throws ClientException
      * @since 1.5
      */
-    long commit(Set<String> path, String message, Depth depth,
-                boolean noUnlock, boolean keepChangelist,
-                Collection<String> changelists,
-                Map<String, String> revpropTable)
+    void commit(Set<String> path, Depth depth, boolean noUnlock,
+                boolean keepChangelist, Collection<String> changelists,
+                Map<String, String> revpropTable, CommitMessageCallback handler,
+                CommitCallback callback)
             throws ClientException;
 
     /**
@@ -308,9 +300,10 @@ public interface ISVNClient
      * @throws ClientException If the copy operation fails.
      * @since 1.7
      */
-    void copy(List<CopySource> sources, String destPath, String message,
+    void copy(List<CopySource> sources, String destPath,
               boolean copyAsChild, boolean makeParents,
-              boolean ignoreExternals, Map<String, String> revpropTable)
+              boolean ignoreExternals, Map<String, String> revpropTable,
+              CommitMessageCallback handler, CommitCallback callback)
             throws ClientException;
 
     /**
@@ -331,9 +324,10 @@ public interface ISVNClient
      * @throws ClientException If the move operation fails.
      * @since 1.5
      */
-    void move(Set<String> srcPaths, String destPath, String message,
-              boolean force, boolean moveAsChild, boolean makeParents,
-              Map<String, String> revpropTable)
+    void move(Set<String> srcPaths, String destPath, boolean force,
+              boolean moveAsChild, boolean makeParents,
+              Map<String, String> revpropTable,
+              CommitMessageCallback handler, CommitCallback callback)
         throws ClientException;
 
     /**
@@ -348,8 +342,9 @@ public interface ISVNClient
      * @throws ClientException
      * @since 1.5
      */
-    void mkdir(Set<String> path, String message, boolean makeParents,
-               Map<String, String> revpropTable)
+    void mkdir(Set<String> path, boolean makeParents,
+               Map<String, String> revpropTable,
+               CommitMessageCallback handler, CommitCallback callback)
             throws ClientException;
 
     /**
@@ -429,9 +424,10 @@ public interface ISVNClient
      *
      * @since 1.5
      */
-    void doImport(String path, String url, String message, Depth depth,
+    void doImport(String path, String url, Depth depth,
                   boolean noIgnore, boolean ignoreUnknownNodeTypes,
-                  Map<String, String> revpropTable)
+                  Map<String, String> revpropTable,
+                  CommitMessageCallback handler, CommitCallback callback)
             throws ClientException;
 
     /**
@@ -620,11 +616,11 @@ public interface ISVNClient
      *
      * @param target Path or URL.
      * @param pegRevision Revision at which to interpret
-     * <code>target</code>.  If {@link RevisionKind#unspecified} or
+     * <code>target</code>.  If {@link Revision.Kind#unspecified} or
      * <code>null</code>, behave identically to {@link
-     * #diffSummarize(String, Revision, String, Revision, int,
-     * boolean, DiffSummaryCallback)}, using <code>path</code> for
-     * both of that method's targets.
+     * #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
      * <code>target</code>.
      * @param endRevision End of range for comparsion of
@@ -682,7 +678,7 @@ public interface ISVNClient
      */
     void propertySet(String path, String name, String value, Depth depth,
                      Collection<String> changelists, boolean force,
-                     Map<String, String> revpropTable)
+                     Map<String, String> revpropTable, CommitCallback callback)
             throws ClientException;
 
     /**
@@ -695,7 +691,7 @@ public interface ISVNClient
      * @since 1.5
      */
     void propertyRemove(String path, String name, Depth depth,
-                        Collection<String> changelists)
+                        Collection<String> changelists, CommitCallback callback)
             throws ClientException;
 
     /**
@@ -711,7 +707,8 @@ public interface ISVNClient
      * @since 1.5
      */
     void propertyCreate(String path, String name, String value, Depth depth,
-                        Collection<String> changelists, boolean force)
+                        Collection<String> changelists, boolean force,
+                        CommitCallback callback)
             throws ClientException;
 
     /**

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNRepos.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNRepos.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNRepos.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNRepos.java Mon Sep  6 20:02:15 2010
@@ -137,7 +137,6 @@ public interface ISVNRepos {
 	 * load the data of a dump into a repository,
 	 * @param path              the path to the repository
 	 * @param dataInput         the data input source
-	 * @param messageOutput     the target for processing messages
 	 * @param ignoreUUID        ignore any UUID found in the input stream
 	 * @param forceUUID         set the repository UUID to any found in the
 	 *                          stream
@@ -145,6 +144,7 @@ public interface ISVNRepos {
 	 * @param usePostCommitHook use the post-commit hook when processing commits
 	 * @param relativePath      the directory in the repository, where the data
 	 *                          in put optional.
+	 * @param callback          the target for processing messages
 	 * @throws ClientException  throw in case of problem
 	 * @since 1.5
 	 */
@@ -217,10 +217,12 @@ public interface ISVNRepos {
 	/**
 	 * list all locks in the repository
 	 * @param path              the path to the repository
+     * @param depth             the depth to recurse
 	 * @throws ClientException  throw in case of problem
-	 * @since 1.2
+	 * @since 1.7
 	 */
-	public abstract Set<Lock> lslocks(File path) throws ClientException;
+	public abstract Set<Lock> lslocks(File path, Depth depth)
+            throws ClientException;
 
 	/**
 	 * remove multiple locks from the repository

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/Info2.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/Info2.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/Info2.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/Info2.java Mon Sep  6 20:02:15 2010
@@ -26,7 +26,7 @@ package org.apache.subversion.javahl;
 import java.util.Date;
 
 /**
- * this class is returned by SVNClientInterface.info2 and contains information
+ * this class is returned by {@link ISVNClient#info2} and contains information
  * about items in the repository or working copy
  * @since 1.2
  */

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ProgressEvent.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ProgressEvent.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ProgressEvent.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ProgressEvent.java Mon Sep  6 20:02:15 2010
@@ -23,10 +23,11 @@
 
 package org.apache.subversion.javahl;
 
+import org.apache.subversion.javahl.callback.ProgressCallback;
+
 /**
- * The event passed to the {@link
- * ProgressListener#onProgress(ProgressEvent)} API to inform {@link
- * SVNClientInterface} of command progress (in terms of bytes).
+ * The event passed to the {@link ProgressCallback#onProgress} API to inform
+ * {@link ISVNClient} of command progress (in terms of bytes).
  *
  * @since 1.5
  */

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ReposNotifyInformation.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ReposNotifyInformation.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ReposNotifyInformation.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/ReposNotifyInformation.java Mon Sep  6 20:02:15 2010
@@ -24,10 +24,11 @@
 package org.apache.subversion.javahl;
 
 import java.util.EventObject;
+import org.apache.subversion.javahl.callback.ReposNotifyCallback;
 
 /**
- * The event passed to the {@link Notify2#onNotify(NotifyInformation)}
- * API to notify {@link SVNClientInterface} of relevant events.
+ * The event passed to the {@link ReposNotifyCallback#onNotify}
+ * API to notify {@link ISVNClient} of relevant events.
  *
  * @since 1.2
  */
@@ -43,7 +44,7 @@ public class ReposNotifyInformation exte
     private static final long serialVersionUID = 1L;
 
     /**
-     * The {@link NotifyAction} which triggered this event.
+     * The {@link Action} which triggered this event.
      */
     private Action action;
 
@@ -70,7 +71,7 @@ public class ReposNotifyInformation exte
     /**
      * This constructor is to be used by the native code.
      *
-     * @param action The {@link NotifyAction} which triggered this event.
+     * @param action The {@link Action} which triggered this event.
      * @param revision potentially the revision.
      */
     public ReposNotifyInformation(Action action, long revision, String warning,
@@ -90,7 +91,7 @@ public class ReposNotifyInformation exte
     }
 
     /**
-     * @return The {@link NotifyAction} which triggered this event.
+     * @return The {@link Action} which triggered this event.
      */
     public Action getAction()
     {

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/SVNClient.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/SVNClient.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/SVNClient.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/SVNClient.java Mon Sep  6 20:02:15 2010
@@ -65,9 +65,7 @@ public class SVNClient implements ISVNCl
         }
     }
 
-    /** Don't call this function!  Public fucntion for backward compat reasons
-      */
-    public long getCppAddr()
+    private long getCppAddr()
     {
         return cppAddr;
     }
@@ -94,6 +92,8 @@ public class SVNClient implements ISVNCl
      */
     protected long cppAddr;
 
+    private ClientContext clientContext = new ClientContext();
+
     /**
      * @since 1.0
      */
@@ -174,29 +174,34 @@ public class SVNClient implements ISVNCl
     /**
      * @since 1.2
      */
-    public native void notification2(ClientNotifyCallback notify);
+    public void notification2(ClientNotifyCallback notify)
+    {
+        clientContext.notify = notify;
+    }
 
     /**
      * @since 1.5
      */
-    public native void setConflictResolver(ConflictResolverCallback listener);
+    public void setConflictResolver(ConflictResolverCallback listener)
+    {
+        clientContext.resolver = listener;
+    }
 
     /**
      * @since 1.5
      */
-    public native void setProgressCallback(ProgressCallback listener);
-
-    /**
-     * @since 1.0
-     */
-    public native void commitMessageHandler(CommitMessage messageHandler);
+    public void setProgressCallback(ProgressCallback listener)
+    {
+        clientContext.listener = listener;
+    }
 
     /**
      * @since 1.5
      */
-    public native void remove(Set<String> paths, String message, boolean force,
+    public native void remove(Set<String> paths, boolean force,
                               boolean keepLocal,
-                              Map<String, String> revpropTable)
+                              Map<String, String> revpropTable,
+                              CommitMessageCallback handler, CommitCallback callback)
             throws ClientException;
 
     /**
@@ -225,36 +230,39 @@ public class SVNClient implements ISVNCl
     /**
      * @since 1.5
      */
-    public native long commit(Set<String> paths, String message, Depth depth,
-                              boolean noUnlock, boolean keepChangelist,
+    public native void commit(Set<String> paths, Depth depth, boolean noUnlock,
+                              boolean keepChangelist,
                               Collection<String> changelists,
-                              Map<String, String> revpropTable)
+                              Map<String, String> revpropTable,
+                              CommitMessageCallback handler, CommitCallback callback)
             throws ClientException;
 
     /**
      * @since 1.7
      */
     public native void copy(List<CopySource> sources, String destPath,
-                            String message, boolean copyAsChild,
-                            boolean makeParents, boolean ignoreExternals,
-                            Map<String, String> revpropTable)
+                            boolean copyAsChild, boolean makeParents,
+                            boolean ignoreExternals,
+                            Map<String, String> revpropTable,
+                            CommitMessageCallback handler, CommitCallback callback)
             throws ClientException;
 
     /**
      * @since 1.5
      */
     public native void move(Set<String> srcPaths, String destPath,
-                            String message, boolean force, boolean moveAsChild,
+                            boolean force, boolean moveAsChild,
                             boolean makeParents,
-                            Map<String, String> revpropTable)
+                            Map<String, String> revpropTable,
+                            CommitMessageCallback handler, CommitCallback callback)
             throws ClientException;
 
     /**
      * @since 1.5
      */
-    public native void mkdir(Set<String> paths, String message,
-                             boolean makeParents,
-                             Map<String, String> revpropTable)
+    public native void mkdir(Set<String> paths, boolean makeParents,
+                             Map<String, String> revpropTable,
+                             CommitMessageCallback handler, CommitCallback callback)
             throws ClientException;
 
     /**
@@ -291,10 +299,11 @@ public class SVNClient implements ISVNCl
     /**
      * @since 1.5
      */
-    public native void doImport(String path, String url, String message,
-                                Depth depth, boolean noIgnore,
+    public native void doImport(String path, String url, Depth depth,
+                                boolean noIgnore,
                                 boolean ignoreUnknownNodeTypes,
-                                Map<String, String> revpropTable)
+                                Map<String, String> revpropTable,
+                                CommitMessageCallback handler, CommitCallback callback)
             throws ClientException;
 
     /**
@@ -406,17 +415,20 @@ public class SVNClient implements ISVNCl
     public native void propertySet(String path, String name, String value,
                                    Depth depth, Collection<String> changelists,
                                    boolean force,
-                                   Map<String, String> revpropTable)
+                                   Map<String, String> revpropTable,
+                                   CommitCallback callback)
             throws ClientException;
 
     /**
      * @since 1.5
      */
     public void propertyRemove(String path, String name, Depth depth,
-                               Collection<String> changelists)
+                               Collection<String> changelists,
+                               CommitCallback callback)
             throws ClientException
     {
-        propertySet(path, name, null, depth, changelists, false, null);
+        propertySet(path, name, null, depth, changelists, false, null,
+                    callback);
     }
 
     /**
@@ -424,10 +436,11 @@ public class SVNClient implements ISVNCl
      */
     public void propertyCreate(String path, String name, String value,
                                Depth depth, Collection<String> changelists,
-                               boolean force)
+                               boolean force, CommitCallback callback)
             throws ClientException
     {
-        propertySet(path, name, value, depth, changelists, force, null);
+        propertySet(path, name, value, depth, changelists, force, null,
+                    callback);
     }
 
     /**
@@ -627,4 +640,38 @@ public class SVNClient implements ISVNCl
                              PatchCallback callback)
             throws ClientException;
 
+    /**
+     * A private class to hold the contextual information required to
+     * persist in this object, such as notification handlers.
+     */
+    private class ClientContext
+        implements ClientNotifyCallback, ProgressCallback,
+            ConflictResolverCallback
+    {
+        public ClientNotifyCallback notify = null;
+        public ProgressCallback listener = null;
+        public ConflictResolverCallback resolver = null;
+
+        public void onNotify(ClientNotifyInformation notifyInfo)
+        {
+            if (notify != null)
+                notify.onNotify(notifyInfo);
+        }
+
+        public void onProgress(ProgressEvent event)
+        {
+            if (listener != null)
+                listener.onProgress(event);
+        }
+
+        public ConflictResult resolve(ConflictDescriptor conflict)
+            throws SubversionException
+        {
+            if (resolver != null)
+                return resolver.resolve(conflict);
+            else
+                return new ConflictResult(ConflictResult.Choice.postpone,
+                                          null);
+        }
+    }
 }

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/SVNRepos.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/SVNRepos.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/SVNRepos.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/SVNRepos.java Mon Sep  6 20:02:15 2010
@@ -205,10 +205,12 @@ public class SVNRepos implements ISVNRep
     /**
      * list all locks in the repository
      * @param path              the path to the repository
+     * @param depth             the depth to recurse
      * @throws ClientException  throw in case of problem
-     * @since 1.2
+     * @since 1.7
      */
-    public native Set<Lock> lslocks(File path) throws ClientException;
+    public native Set<Lock> lslocks(File path, Depth depth)
+            throws ClientException;
 
     /**
      * remove multiple locks from the repository

Modified: subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/callback/BlameCallback.java
URL: http://svn.apache.org/viewvc/subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/callback/BlameCallback.java?rev=993141&r1=993140&r2=993141&view=diff
==============================================================================
--- subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/callback/BlameCallback.java (original)
+++ subversion/branches/performance/subversion/bindings/javahl/src/org/apache/subversion/javahl/callback/BlameCallback.java Mon Sep  6 20:02:15 2010
@@ -26,10 +26,11 @@ package org.apache.subversion.javahl.cal
 import org.apache.subversion.javahl.ClientException;
 
 import java.util.Map;
+import org.apache.subversion.javahl.ISVNClient;
 
 /**
  * This interface is used to receive every single line for a file on a
- * the SVNClientInterface.blame call.
+ * the {@link ISVNClient#blame} call.
  *
  * @since 1.7
  */
@@ -37,7 +38,7 @@ public interface BlameCallback
 {
     /**
      * the method will be called for every line in a file.
-     * @param line              the line number for this line
+     * @param lineNum           the line number for this line
      * @param revision          the revision of the last change.
      * @param revProps          the revision properties for this revision.
      * @param mergedRevision    the revision of the last merged change.