org.springframework.security.oauth.provider.token
Class InMemoryProviderTokenServices
java.lang.Object
org.springframework.security.oauth.provider.token.RandomValueProviderTokenServices
org.springframework.security.oauth.provider.token.InMemoryProviderTokenServices
- All Implemented Interfaces:
- org.springframework.beans.factory.InitializingBean, OAuthProviderTokenServices, OAuthTokenLifecycleRegistry
- Direct Known Subclasses:
- InMemorySelfCleaningProviderTokenServices
public class InMemoryProviderTokenServices
- extends RandomValueProviderTokenServices
Implementation of TokenServices that stores tokens in memory.
- Author:
- Ryan Heaton
| Methods inherited from class org.springframework.security.oauth.provider.token.RandomValueProviderTokenServices |
afterPropertiesSet, authorizeRequestToken, createAccessToken, createUnauthorizedRequestToken, getAccessTokenValiditySeconds, getLifecycleListeners, getRandom, getRequestTokenValiditySeconds, getToken, getTokenSecretLengthBytes, isExpired, onTokenCreated, onTokenRemoved, register, setAccessTokenValiditySeconds, setRandom, setRequestTokenValiditySeconds, setTokenSecretLengthBytes |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
tokenStore
protected final ConcurrentHashMap<String,OAuthProviderTokenImpl> tokenStore
InMemoryProviderTokenServices
public InMemoryProviderTokenServices()
readToken
protected OAuthProviderTokenImpl readToken(String token)
- Description copied from class:
RandomValueProviderTokenServices
- Read a token from persistence.
- Specified by:
readToken in class RandomValueProviderTokenServices
- Parameters:
token - The token to read.
- Returns:
- The token, or null if the token doesn't exist.
storeToken
protected void storeToken(String tokenValue,
OAuthProviderTokenImpl token)
- Description copied from class:
RandomValueProviderTokenServices
- Store a token from persistence.
- Specified by:
storeToken in class RandomValueProviderTokenServices
- Parameters:
tokenValue - The token value.token - The token to store.
removeToken
protected OAuthProviderTokenImpl removeToken(String tokenValue)
- Description copied from class:
RandomValueProviderTokenServices
- Remove a token from persistence.
- Specified by:
removeToken in class RandomValueProviderTokenServices
- Parameters:
tokenValue - The token to remove.
- Returns:
- The token that was removed.
Copyright © 2013. All rights reserved.