org.eclipse.higgins.sync.auth.ehcache
Class AuthenticateServiceBean

java.lang.Object
  extended by org.eclipse.higgins.sync.auth.ehcache.AuthenticateServiceBean
All Implemented Interfaces:
org.eclipse.higgins.sync.auth.IAuthenticateService

public class AuthenticateServiceBean
extends Object
implements org.eclipse.higgins.sync.auth.IAuthenticateService

Implements IAuthenticateService by using ehcache for storing access token.

Author:
Alexander Yuhimenko

Field Summary
 
Fields inherited from interface org.eclipse.higgins.sync.auth.IAuthenticateService
AUTHENTICATE_HEADER_NAME, AUTHENTICATE_HEADER_PREFIX
 
Constructor Summary
AuthenticateServiceBean()
           
 
Method Summary
 void deleteAccessToken(String id)
           
 org.eclipse.higgins.sync.auth.entity.AccessTokenEntity getAccessToken(String id)
           
static Context getContext()
          Return JNDI environment.
 org.eclipse.higgins.sync.auth.entity.AccessTokenEntity persistAccessToken(org.eclipse.higgins.sync.auth.entity.AccessTokenEntity accessTokenEntity)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AuthenticateServiceBean

public AuthenticateServiceBean()
Method Detail

getContext

public static Context getContext()
                          throws NamingException
Return JNDI environment.

Returns:
Throws:
NamingException

deleteAccessToken

public void deleteAccessToken(String id)
Specified by:
deleteAccessToken in interface org.eclipse.higgins.sync.auth.IAuthenticateService

getAccessToken

public org.eclipse.higgins.sync.auth.entity.AccessTokenEntity getAccessToken(String id)
                                                                      throws org.eclipse.higgins.sync.auth.exceptions.AuthenticationException
Specified by:
getAccessToken in interface org.eclipse.higgins.sync.auth.IAuthenticateService
Throws:
org.eclipse.higgins.sync.auth.exceptions.AuthenticationException

persistAccessToken

public org.eclipse.higgins.sync.auth.entity.AccessTokenEntity persistAccessToken(org.eclipse.higgins.sync.auth.entity.AccessTokenEntity accessTokenEntity)
                                                                          throws org.eclipse.higgins.sync.auth.exceptions.AuthenticationException
Specified by:
persistAccessToken in interface org.eclipse.higgins.sync.auth.IAuthenticateService
Throws:
org.eclipse.higgins.sync.auth.exceptions.AuthenticationException