|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.lang.Throwable
java.lang.Exception
java.io.IOException
com.google.api.client.http.HttpResponseException
com.google.api.client.auth.oauth2.TokenResponseException
public class TokenResponseException
Exception thrown when receiving an error response from the token server as specified in Error Response
To get the structured details, use getDetails().
Sample usage can be found for AuthorizationCodeTokenRequest.
| Method Summary | |
|---|---|
static TokenResponseException |
from(JsonFactory jsonFactory,
HttpResponse response)
Returns a new instance of TokenResponseException. |
TokenErrorResponse |
getDetails()
Returns the token error response details or null if unable to parse. |
| Methods inherited from class com.google.api.client.http.HttpResponseException |
|---|
computeMessage, computeMessageBuffer, getHeaders, getResponse, getStatusCode, isSuccessStatusCode |
| Methods inherited from class java.lang.Throwable |
|---|
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Method Detail |
|---|
public final TokenErrorResponse getDetails()
null if unable to parse.
public static TokenResponseException from(JsonFactory jsonFactory,
HttpResponse response)
TokenResponseException.
If there is a JSON error response, it is parsed using TokenErrorResponse, which can be
inspected using getDetails(). Otherwise, the full response content is read and
included in the exception message.
jsonFactory - JSON factoryresponse - HTTP response
TokenErrorResponse
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||