org.jboss.ejb.txtimer
Interface DatabasePersistencePlugin

All Known Implementing Classes:
GeneralPurposeDatabasePersistencePlugin, OracleDatabasePersistencePlugin

public interface DatabasePersistencePlugin

An implementation of of this interface provides database specific JDBC access that is not portable accros RDBMS systems.

Since:
23-Sep-2004
Version:
$Revision: 57209 $
Author:
Thomas.Diesler@jboss.org

Method Summary
 void clearTimers()
          Clear all persisted timers
 void createTableIfNotExists()
          Create the timers table if it does not exist already
 void deleteTimer(String timerId, TimedObjectId timedObjectId)
          Delete a timer.
 String getColumnInfo()
          Get the info column name
 String getColumnInitialDate()
          Get the initial date column name
 String getColumnInstancePK()
          Get the instance PK column name
 String getColumnTargetID()
          Get the target ID column name
 String getColumnTimerID()
          Get the timer ID column name
 String getColumnTimerInterval()
          Get the timer interval column name
 String getTableName()
          Get the timer table name
 void init(javax.management.MBeanServer server, javax.management.ObjectName dataSource)
          Initialize the plugin
 void insertTimer(String timerId, TimedObjectId timedObjectId, Date initialExpiration, long intervalDuration, Serializable info)
          Insert a timer object
 List selectTimers(javax.management.ObjectName containerId)
          Select a list of currently persisted timer handles
 

Method Detail

init

void init(javax.management.MBeanServer server,
          javax.management.ObjectName dataSource)
          throws SQLException
Initialize the plugin

Throws:
SQLException

createTableIfNotExists

void createTableIfNotExists()
                            throws SQLException
Create the timers table if it does not exist already

Throws:
SQLException

insertTimer

void insertTimer(String timerId,
                 TimedObjectId timedObjectId,
                 Date initialExpiration,
                 long intervalDuration,
                 Serializable info)
                 throws SQLException
Insert a timer object

Throws:
SQLException

selectTimers

List selectTimers(javax.management.ObjectName containerId)
                  throws SQLException
Select a list of currently persisted timer handles

Returns:
List
Throws:
SQLException

deleteTimer

void deleteTimer(String timerId,
                 TimedObjectId timedObjectId)
                 throws SQLException
Delete a timer.

Throws:
SQLException

clearTimers

void clearTimers()
                 throws SQLException
Clear all persisted timers

Throws:
SQLException

getTableName

String getTableName()
Get the timer table name


getColumnTimerID

String getColumnTimerID()
Get the timer ID column name


getColumnTargetID

String getColumnTargetID()
Get the target ID column name


getColumnInitialDate

String getColumnInitialDate()
Get the initial date column name


getColumnTimerInterval

String getColumnTimerInterval()
Get the timer interval column name


getColumnInstancePK

String getColumnInstancePK()
Get the instance PK column name


getColumnInfo

String getColumnInfo()
Get the info column name



Copyright © 2002 JBoss Group, LLC. All Rights Reserved.