Class OAuth2RefreshToken
- java.lang.Object
-
- org.springframework.security.oauth2.core.AbstractOAuth2Token
-
- org.springframework.security.oauth2.core.OAuth2RefreshToken
-
- All Implemented Interfaces:
java.io.Serializable
,OAuth2Token
public class OAuth2RefreshToken extends AbstractOAuth2Token
An implementation of anAbstractOAuth2Token
representing an OAuth 2.0 Refresh Token.A refresh token is a credential that represents an authorization granted by the resource owner to the client. It is used by the client to obtain a new access token when the current access token becomes invalid or expires, or to obtain additional access tokens with identical or narrower scope.
- Since:
- 5.1
- See Also:
OAuth2AccessToken
, Section 1.5 Refresh Token, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description OAuth2RefreshToken(java.lang.String tokenValue, java.time.Instant issuedAt)
Constructs anOAuth2RefreshToken
using the provided parameters.OAuth2RefreshToken(java.lang.String tokenValue, java.time.Instant issuedAt, java.time.Instant expiresAt)
Constructs anOAuth2RefreshToken
using the provided parameters.
-
Method Summary
-
Methods inherited from class org.springframework.security.oauth2.core.AbstractOAuth2Token
equals, getExpiresAt, getIssuedAt, getTokenValue, hashCode
-
-
-
-
Constructor Detail
-
OAuth2RefreshToken
public OAuth2RefreshToken(java.lang.String tokenValue, java.time.Instant issuedAt)
Constructs anOAuth2RefreshToken
using the provided parameters.- Parameters:
tokenValue
- the token valueissuedAt
- the time at which the token was issued
-
OAuth2RefreshToken
public OAuth2RefreshToken(java.lang.String tokenValue, java.time.Instant issuedAt, java.time.Instant expiresAt)
Constructs anOAuth2RefreshToken
using the provided parameters.- Parameters:
tokenValue
- the token valueissuedAt
- the time at which the token was issuedexpiresAt
- the time at which the token expires- Since:
- 5.5
-
-