Package com.nimbusds.openid.connect.sdk
Class UserInfoResponse
java.lang.Object
com.nimbusds.openid.connect.sdk.UserInfoResponse
- Direct Known Subclasses:
UserInfoErrorResponse
,UserInfoSuccessResponse
The base abstract class for UserInfo success and error responses.
Related specifications:
- OpenID Connect Core 1.0, section 5.3.2 and 5.3.3.
- OAuth 2.0 Bearer Token Usage (RFC 6750), section 3.1.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic UserInfoResponse
parse
(HTTPResponse httpResponse) Parses a UserInfo response from the specified HTTP response.Casts this response to a UserInfo error response.Casts this response to a UserInfo 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
-
UserInfoResponse
public UserInfoResponse()
-
-
Method Details
-
toSuccessResponse
Casts this response to a UserInfo success response.- Returns:
- The UserInfo success response.
-
toErrorResponse
Casts this response to a UserInfo error response.- Returns:
- The UserInfo error response.
-
parse
Parses a UserInfo response from the specified HTTP response.- Parameters:
httpResponse
- The HTTP response. Must not benull
.- Returns:
- The UserInfo success or error response.
- Throws:
ParseException
- If the HTTP response couldn't be parsed to a UserInfo response.
-