org.jets3t.apps.synchronize
Class CommandLineCredentialsProvider

java.lang.Object
  extended by org.jets3t.apps.synchronize.CommandLineCredentialsProvider
All Implemented Interfaces:
org.apache.commons.httpclient.auth.CredentialsProvider

public class CommandLineCredentialsProvider
extends Object
implements org.apache.commons.httpclient.auth.CredentialsProvider

Prompts for the user to enter HTTP Proxy authentication credentials via the command line.

Author:
James Murty

Field Summary
 
Fields inherited from interface org.apache.commons.httpclient.auth.CredentialsProvider
PROVIDER
 
Constructor Summary
CommandLineCredentialsProvider()
           
 
Method Summary
 org.apache.commons.httpclient.Credentials getCredentials(org.apache.commons.httpclient.auth.AuthScheme authscheme, String host, int port, boolean proxy)
          Implementation method for the CredentialsProvider interface.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CommandLineCredentialsProvider

public CommandLineCredentialsProvider()
Method Detail

getCredentials

public org.apache.commons.httpclient.Credentials getCredentials(org.apache.commons.httpclient.auth.AuthScheme authscheme,
                                                                String host,
                                                                int port,
                                                                boolean proxy)
                                                         throws org.apache.commons.httpclient.auth.CredentialsNotAvailableException
Implementation method for the CredentialsProvider interface.

Based on sample code: InteractiveAuthenticationExample

Specified by:
getCredentials in interface org.apache.commons.httpclient.auth.CredentialsProvider
Throws:
org.apache.commons.httpclient.auth.CredentialsNotAvailableException