Class OAuth2Error
java.lang.Object
org.springframework.security.oauth2.core.OAuth2Error
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
BearerTokenError
A representation of an OAuth 2.0 Error.
At a minimum, an error response will contain an error code. The error code may be one of the standard codes defined by the specification, or a new code defined in the OAuth Extensions Error Registry, for cases where protocol extensions require additional error code(s) above the standard codes.
- Since:
- 5.0
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionOAuth2Error(String errorCode) Constructs anOAuth2Errorusing the provided parameters.OAuth2Error(String errorCode, @Nullable String description, @Nullable String uri) Constructs anOAuth2Errorusing the provided parameters. -
Method Summary
-
Constructor Details
-
OAuth2Error
Constructs anOAuth2Errorusing the provided parameters.- Parameters:
errorCode- the error code
-
OAuth2Error
-
-
Method Details
-
getErrorCode
-
getDescription
Returns the error description.- Returns:
- the error description, or
nullif not available
-
getUri
Returns the error uri.- Returns:
- the error uri, or
nullif not available
-
toString
-