org.tigris.subversion.svnclientadapter
Interface ISVNPromptUserPassword


public interface ISVNPromptUserPassword

An interface describing a callback used during authentification.


Field Summary
static int AcceptPermanently
          accept the connection to the server forever
static int AcceptTemporary
          accept the connection to the server one time.
static int Reject
          reject the connection to the server
 
Method Summary
 java.lang.String askQuestion(java.lang.String realm, java.lang.String question, boolean showAnswer, boolean maySave)
          Ask the user a question about authentification the save data check box status will be queried by userAllowedSave
 int askTrustSSLServer(java.lang.String info, boolean allowPermanently)
          If there are problems with the certifcate of the SSL-server, this callback will be used to deside if the connection will be used.
 boolean askYesNo(java.lang.String realm, java.lang.String question, boolean yesIsDefault)
          ask the user a yes/no question
 java.lang.String getPassword()
          retrieve the password entered during the prompt call
 int getSSHPort()
          retrieve the SSH port entered during the prompt call
 java.lang.String getSSHPrivateKeyPassphrase()
          retrieve the passphrase for the key file entered during the prompt call
 java.lang.String getSSHPrivateKeyPath()
          retrieve the SSH key file entered during the prompt call
 java.lang.String getSSLClientCertPassword()
          retrieve the password for the certifcate
 java.lang.String getSSLClientCertPath()
          retrieve the SSL certificate entered during the prompt call
 java.lang.String getUsername()
          retrieve the username entered during the prompt call
 boolean prompt(java.lang.String realm, java.lang.String username, boolean maySave)
          Request the password to be used from the user.
 boolean promptSSH(java.lang.String realm, java.lang.String username, int sshPort, boolean maySave)
          Request the SSH info to be used from the user.
 boolean promptSSL(java.lang.String realm, boolean maySave)
          Request the SSL client certificate info to be used from the user.
 boolean promptUser(java.lang.String realm, java.lang.String username, boolean maySave)
          Request the username to be used for SVN operation the save data check box status will be queried by userAllowedSave
 boolean userAllowedSave()
          query if the user allowed the saving of the data of the last call
 

Field Detail

Reject

static final int Reject
reject the connection to the server

See Also:
Constant Field Values

AcceptTemporary

static final int AcceptTemporary
accept the connection to the server one time.

See Also:
Constant Field Values

AcceptPermanently

static final int AcceptPermanently
accept the connection to the server forever

See Also:
Constant Field Values
Method Detail

askYesNo

boolean askYesNo(java.lang.String realm,
                 java.lang.String question,
                 boolean yesIsDefault)
ask the user a yes/no question

Parameters:
realm - for which server realm this information is requested.
question - question to be asked
yesIsDefault - if yes should be the default
Returns:
the answer

getUsername

java.lang.String getUsername()
retrieve the username entered during the prompt call

Returns:
the username

getPassword

java.lang.String getPassword()
retrieve the password entered during the prompt call

Returns:
the password

askTrustSSLServer

int askTrustSSLServer(java.lang.String info,
                      boolean allowPermanently)
If there are problems with the certifcate of the SSL-server, this callback will be used to deside if the connection will be used.

Parameters:
info - the probblems with the certificate.
allowPermanently - if AcceptPermantly is a legal answer
Returns:
one of Reject/AcceptTemporary/AcceptPermanently

prompt

boolean prompt(java.lang.String realm,
               java.lang.String username,
               boolean maySave)
Request the password to be used from the user. the save data check box status will be queried by userAllowedSave

Parameters:
realm - realm for the username
username - username in the realm
maySave - should a save data check box be enabled.
Returns:
password as entered or null if canceled.

promptUser

boolean promptUser(java.lang.String realm,
                   java.lang.String username,
                   boolean maySave)
Request the username to be used for SVN operation the save data check box status will be queried by userAllowedSave

Parameters:
realm - realm for the username
username - username in the realm
maySave - should a save data check box be enabled.
Returns:
password as entered or null if canceled.

askQuestion

java.lang.String askQuestion(java.lang.String realm,
                             java.lang.String question,
                             boolean showAnswer,
                             boolean maySave)
Ask the user a question about authentification the save data check box status will be queried by userAllowedSave

Parameters:
realm - real of the question
question - text of the question
showAnswer - flag if the answer should be displayed
maySave - should a save data check box be enabled.
Returns:
answer as entered or null if canceled

userAllowedSave

boolean userAllowedSave()
query if the user allowed the saving of the data of the last call

Returns:
was the save data check box checked

promptSSH

boolean promptSSH(java.lang.String realm,
                  java.lang.String username,
                  int sshPort,
                  boolean maySave)
Request the SSH info to be used from the user. the save data check box status will be queried by userAllowedSave

Parameters:
realm - realm for the username
username - username in the realm
sshPort - the port number to use
maySave - should a save data check box be enabled.
Returns:
true if OK was pressed

getSSHPrivateKeyPath

java.lang.String getSSHPrivateKeyPath()
retrieve the SSH key file entered during the prompt call

Returns:
the key file

getSSHPrivateKeyPassphrase

java.lang.String getSSHPrivateKeyPassphrase()
retrieve the passphrase for the key file entered during the prompt call

Returns:
the passphrase

getSSHPort

int getSSHPort()
retrieve the SSH port entered during the prompt call

Returns:
the port number

promptSSL

boolean promptSSL(java.lang.String realm,
                  boolean maySave)
Request the SSL client certificate info to be used from the user. the save data check box status will be queried by userAllowedSave

Parameters:
realm - realm for the action
maySave - should a save data check box be enabled.
Returns:
true if OK was pressed

getSSLClientCertPassword

java.lang.String getSSLClientCertPassword()
retrieve the password for the certifcate

Returns:
the password

getSSLClientCertPath

java.lang.String getSSLClientCertPath()
retrieve the SSL certificate entered during the prompt call

Returns:
the certificate