Package com.nimbusds.oauth2.sdk
Class TokenIntrospectionResponse
java.lang.Object
com.nimbusds.oauth2.sdk.TokenIntrospectionResponse
- Direct Known Subclasses:
TokenIntrospectionErrorResponse
,TokenIntrospectionSuccessResponse
Token introspection response. This is the base abstract class for token
introspection success and error responses.
Related specifications:
- OAuth 2.0 Token Introspection (RFC 7662).
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic TokenIntrospectionResponse
parse
(HTTPResponse httpResponse) Parses a token introspection response from the specified HTTP response.Casts this response to a token introspection error response.Casts this response to a token introspection success response.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.nimbusds.oauth2.sdk.Response
indicatesSuccess, toHTTPResponse
-
Constructor Details
-
TokenIntrospectionResponse
public TokenIntrospectionResponse()
-
-
Method Details
-
toSuccessResponse
Casts this response to a token introspection success response.- Returns:
- The token introspection success response.
-
toErrorResponse
Casts this response to a token introspection error response.- Returns:
- The token introspection error response.
-
parse
Parses a token introspection response from the specified HTTP response.- Parameters:
httpResponse
- The HTTP response. Must not benull
.- Returns:
- The token introspection success or error response.
- Throws:
ParseException
- If the HTTP response couldn't be parsed to a token introspection response.
-