Package org.openiam.esb.am.service.impl
Class OAuthServiceImpl
- java.lang.Object
-
- org.openiam.esb.am.service.impl.OAuthServiceImpl
-
- All Implemented Interfaces:
OAuthService
@Service("oAuthService") public class OAuthServiceImpl extends Object implements OAuthService
Created by alexander on 24.04.15.
-
-
Constructor Summary
Constructors Constructor Description OAuthServiceImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<OAuthToken>
findBeans(OAuthSearchBean searchBean, int from, int size)
Find OAuth tokens.OAuthTokenEntity
getOAuthTokenByRefreshToken(String refreshToken)
OAuthTokenEntity
getOAuthTokenByToken(String accessToken)
void
revokeIdTokens(List<String> idTokens)
Revoke ID tokens.void
revokeTokens(List<String> tokens)
Revoke token.OAuthTokenEntity
saveOAuthToken(OAuthTokenEntity oAuthTokenEntity)
-
-
-
Method Detail
-
findBeans
@Transactional(readOnly=true) public List<OAuthToken> findBeans(OAuthSearchBean searchBean, int from, int size)
Description copied from interface:OAuthService
Find OAuth tokens.- Specified by:
findBeans
in interfaceOAuthService
- Returns:
- OAuth tokens
-
getOAuthTokenByToken
@Transactional(readOnly=true) public OAuthTokenEntity getOAuthTokenByToken(String accessToken)
- Specified by:
getOAuthTokenByToken
in interfaceOAuthService
-
getOAuthTokenByRefreshToken
@Transactional(readOnly=true) public OAuthTokenEntity getOAuthTokenByRefreshToken(String refreshToken)
- Specified by:
getOAuthTokenByRefreshToken
in interfaceOAuthService
-
saveOAuthToken
@Transactional public OAuthTokenEntity saveOAuthToken(OAuthTokenEntity oAuthTokenEntity)
- Specified by:
saveOAuthToken
in interfaceOAuthService
-
revokeTokens
@Transactional public void revokeTokens(List<String> tokens) throws BasicDataServiceException
Description copied from interface:OAuthService
Revoke token.- Specified by:
revokeTokens
in interfaceOAuthService
- Parameters:
tokens
- if null throwsBasicDataServiceException
withResponseCode
.INVALID_TOKEN- Throws:
BasicDataServiceException
-
revokeIdTokens
@Transactional public void revokeIdTokens(List<String> idTokens) throws BasicDataServiceException
Revoke ID tokens.- Specified by:
revokeIdTokens
in interfaceOAuthService
- Parameters:
idTokens
- List of ID tokens to be revoked. If null, throwsBasicDataServiceException
- Throws:
BasicDataServiceException
- If an error occurs while revoking tokens.
-
-