Activate it with {@link Authenticator#setDefault(Authenticator)}:
Credentials login = new Credentials(username, password); Authenticator.setDefault(new GmailHttpAuthenticator(login));
When using with {@link Proxy}:
Credentials login = new Credentials(username, password); Credentials proxyLogin = new Credentials(proxyUser, proxyPass); Authenticator.setDefault(new GmailHttpAuthenticator(login, proxyLogin));
@see Authenticator @see Credentials @author Tomas Varaneckas <tomas.varaneckas@gmail.com> @version $Id: GmailHttpAuthenticator.java 37 2009-07-09 17:26:41Z tomas.varaneckas $ @since 0.1
|
|
|
|