org.openid4java.server
Class JdbcServerAssociationStore
java.lang.Object
org.springframework.dao.support.DaoSupport
org.springframework.jdbc.core.support.JdbcDaoSupport
org.openid4java.server.JdbcServerAssociationStore
- All Implemented Interfaces:
- ServerAssociationStore, org.springframework.beans.factory.InitializingBean
public class JdbcServerAssociationStore
- extends org.springframework.jdbc.core.support.JdbcDaoSupport
- implements ServerAssociationStore
JDBC implementation for the ServerAssociationStore interface.
The JdbcServerAssociation store requires a javax.sql.DataSource to be
configured and passed in to it with the setDataSource setter method.
The table name also needs to be specified, either through the constructor,
or through the setTableName setter.
The specified table must have the following structure:
- handle : string : primary key
- type : string
- mackey : string
- expdate : date
- Author:
- Marius Scurtescu, Johnny Bufu
Fields inherited from class org.springframework.dao.support.DaoSupport |
logger |
Methods inherited from class org.springframework.jdbc.core.support.JdbcDaoSupport |
checkDaoConfig, createJdbcTemplate, getConnection, getDataSource, getExceptionTranslator, getJdbcTemplate, initTemplateConfig, releaseConnection, setDataSource, setJdbcTemplate |
Methods inherited from class org.springframework.dao.support.DaoSupport |
afterPropertiesSet, initDao |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_log
private static org.apache.commons.logging.Log _log
DEBUG
private static final boolean DEBUG
_random
private static java.util.Random _random
CLEANUP_INTERVAL
private static final int CLEANUP_INTERVAL
- See Also:
- Constant Field Values
_lastCleanup
private static long _lastCleanup
_tableName
private java.lang.String _tableName
JdbcServerAssociationStore
public JdbcServerAssociationStore()
JdbcServerAssociationStore
public JdbcServerAssociationStore(java.lang.String tableName)
getTableName
public java.lang.String getTableName()
setTableName
public void setTableName(java.lang.String tableName)
generate
public Association generate(java.lang.String type,
int expiryIn)
throws AssociationException
- Specified by:
generate
in interface ServerAssociationStore
- Throws:
AssociationException
load
public Association load(java.lang.String handle)
- Specified by:
load
in interface ServerAssociationStore
remove
public void remove(java.lang.String handle)
- Specified by:
remove
in interface ServerAssociationStore
cleanupExpired
private void cleanupExpired()
Copyright 2006-2008 Sxip Identity Corporation