Class RestTemplateAccessTokenRetriever
- java.lang.Object
-
- org.bremersee.security.authentication.RestTemplateAccessTokenRetriever
-
- All Implemented Interfaces:
AccessTokenRetriever<String>
public class RestTemplateAccessTokenRetriever extends Object implements AccessTokenRetriever<String>
The rest template access token retriever.- Author:
- Christian Bremer
-
-
Constructor Summary
Constructors Constructor Description RestTemplateAccessTokenRetriever(org.springframework.web.client.RestTemplate restTemplate)
Instantiates a new rest template access token retriever.RestTemplateAccessTokenRetriever(org.springframework.web.client.RestTemplate restTemplate, AccessTokenCache accessTokenCache)
Instantiates a new rest template access token retriever.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
retrieveAccessToken(AccessTokenRetrieverProperties input)
Retrieve the access token from the identity provider.
-
-
-
Constructor Detail
-
RestTemplateAccessTokenRetriever
public RestTemplateAccessTokenRetriever(org.springframework.web.client.RestTemplate restTemplate)
Instantiates a new rest template access token retriever.- Parameters:
restTemplate
- the rest template
-
RestTemplateAccessTokenRetriever
public RestTemplateAccessTokenRetriever(org.springframework.web.client.RestTemplate restTemplate, AccessTokenCache accessTokenCache)
Instantiates a new rest template access token retriever.- Parameters:
restTemplate
- the rest templateaccessTokenCache
- the access token cache
-
-
Method Detail
-
retrieveAccessToken
public String retrieveAccessToken(AccessTokenRetrieverProperties input)
Description copied from interface:AccessTokenRetriever
Retrieve the access token from the identity provider.- Specified by:
retrieveAccessToken
in interfaceAccessTokenRetriever<String>
- Parameters:
input
- the request properties- Returns:
- the access token
-
-