org.springframework.security.oauth2.client.token
类 JdbcClientTokenServices

java.lang.Object
  继承者 org.springframework.security.oauth2.client.token.JdbcClientTokenServices
所有已实现的接口:
ClientTokenServices

public class JdbcClientTokenServices
extends Object
implements ClientTokenServices

Implementation of token services that stores tokens in a database for retrieval by client applications.

作者:
Dave Syer

构造方法摘要
JdbcClientTokenServices(DataSource dataSource)
           
 
方法摘要
 OAuth2AccessToken getAccessToken(OAuth2ProtectedResourceDetails resource, org.springframework.security.core.Authentication authentication)
          Retrieve the access token for a given resource and user authentication (my be null).
 void removeAccessToken(OAuth2ProtectedResourceDetails resource, org.springframework.security.core.Authentication authentication)
          Remove the token (if any) that is stored with the provided resource and authentication.
 void saveAccessToken(OAuth2ProtectedResourceDetails resource, org.springframework.security.core.Authentication authentication, OAuth2AccessToken accessToken)
          Save or update the access token for this resource and authentication (may be null).
 void setClientKeyGenerator(ClientKeyGenerator keyGenerator)
           
 void setDeleteAccessTokenSql(String deleteAccessTokenSql)
           
 void setInsertAccessTokenSql(String insertAccessTokenSql)
           
 void setSelectAccessTokenSql(String selectAccessTokenSql)
           
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

构造方法详细信息

JdbcClientTokenServices

public JdbcClientTokenServices(DataSource dataSource)
方法详细信息

setClientKeyGenerator

public void setClientKeyGenerator(ClientKeyGenerator keyGenerator)

getAccessToken

public OAuth2AccessToken getAccessToken(OAuth2ProtectedResourceDetails resource,
                                        org.springframework.security.core.Authentication authentication)
从接口 ClientTokenServices 复制的描述
Retrieve the access token for a given resource and user authentication (my be null).

指定者:
接口 ClientTokenServices 中的 getAccessToken
参数:
resource - the resource to be accessed
authentication - the current user authentication (or null if there is none)
返回:
an access token if one has been stored, null otherwise

saveAccessToken

public void saveAccessToken(OAuth2ProtectedResourceDetails resource,
                            org.springframework.security.core.Authentication authentication,
                            OAuth2AccessToken accessToken)
从接口 ClientTokenServices 复制的描述
Save or update the access token for this resource and authentication (may be null).

指定者:
接口 ClientTokenServices 中的 saveAccessToken
参数:
resource - the resource to be accessed
authentication - the current user authentication (or null if there is none)
accessToken - an access token to be stored

removeAccessToken

public void removeAccessToken(OAuth2ProtectedResourceDetails resource,
                              org.springframework.security.core.Authentication authentication)
从接口 ClientTokenServices 复制的描述
Remove the token (if any) that is stored with the provided resource and authentication. If there is no such token do nothing.

指定者:
接口 ClientTokenServices 中的 removeAccessToken
参数:
resource - the resource to be accessed
authentication - the current user authentication (or null if there is none)

setInsertAccessTokenSql

public void setInsertAccessTokenSql(String insertAccessTokenSql)

setSelectAccessTokenSql

public void setSelectAccessTokenSql(String selectAccessTokenSql)

setDeleteAccessTokenSql

public void setDeleteAccessTokenSql(String deleteAccessTokenSql)


Copyright © 2013. All rights reserved.