|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.google.api.client.googleapis.auth.clientlogin.ClientLogin
public final class ClientLogin
Client Login authentication method as described in ClientLogin for Installed Applications.
| Nested Class Summary | |
|---|---|
static class |
ClientLogin.ErrorInfo
Key/value data to parse an error response. |
static class |
ClientLogin.Response
Key/value data to parse a success response. |
| Field Summary | |
|---|---|
String |
accountType
Type of account to request authorization for. |
String |
applicationName
Short string identifying your application for logging purposes of the form: "companyName-applicationName-versionID". |
String |
authTokenType
Name of the Google service you're requesting authorization for, for example "cl" for
Google Calendar. |
String |
captchaAnswer
(optional) String entered by the user as an answer to a CAPTCHA challenge. |
String |
captchaToken
(optional) Token representing the specific CAPTCHA challenge. |
String |
password
User's password. |
com.google.api.client.http.GenericUrl |
serverUrl
URL for the Client Login authorization server. |
com.google.api.client.http.HttpTransport |
transport
HTTP transport required for executing request in authenticate(). |
String |
username
User's full email address. |
| Constructor Summary | |
|---|---|
ClientLogin()
|
|
| Method Summary | |
|---|---|
ClientLogin.Response |
authenticate()
Authenticates based on the provided field values. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public com.google.api.client.http.HttpTransport transport
authenticate().
public com.google.api.client.http.GenericUrl serverUrl
By default this is "https://www.google.com", but it may be overridden for testing
purposes.
public String applicationName
public String authTokenType
"cl" for
Google Calendar.
public String username
public String password
public String accountType
public String captchaToken
public String captchaAnswer
| Constructor Detail |
|---|
public ClientLogin()
| Method Detail |
|---|
public ClientLogin.Response authenticate()
throws com.google.api.client.http.HttpResponseException,
IOException
com.google.api.client.http.HttpResponseException - if the authentication response has an error code, such as for a
CAPTCHA challenge. Call exception.getResponse(). parseAs(
ClientLoginAuthenticator.ErrorInfo.class) to parse the
response.
IOException - some other kind of I/O exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||