Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>The solution is simple: call</p> <pre><code>svnRepository.setAuthenticationManager(...); </code></pre> <p>with a proper ISVNAuthenticationManager implementation.</p> <p>SVNKit has already several ready-to-use implementations of this class. The simplest one is <code>BasicAuthenticationManager</code> which can be constructed by one or several <code>SVNAuthentication</code>. Each <code>SVNAuthentication</code> instance represents some kind of credentials (see its subclasses). So if, for example, your repository is secured by only username and password, you can construct <code>SVNPasswordAuthentication</code> with your password and then construct <code>BasicAuthenticationManager</code> using it and pass to <code>SVNRepository</code>.</p> <p>Another useful implementation is <code>DefaultSVNAuthenticationManager</code> which describes "authentication data stored in <code>~/.subversion</code> directory". To construct it you can use <code>SVNWCUtil.createDefaultAuthenticationManager()</code>. You can also customize this class, for example, to allow or disallow to enter a password from a keyboard in interactive mode, or to store or not to store entered password in in <code>~/.subversion</code> directory (or also you can use another directory for that). To understand how to do that, I recommend you to look at <code>SVNCommandEnvironment.createClientAuthenticationManager()</code> which constructs <code>ISVNAuthenticationManager</code> implementation for command line utility.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload