org.infoglue.cms.util.workflow
Class InfoGlueJDBCWorkflowStore

java.lang.Object
  extended by com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
      extended by org.infoglue.cms.util.workflow.InfoGlueJDBCWorkflowStore
All Implemented Interfaces:
com.opensymphony.workflow.spi.WorkflowStore
Direct Known Subclasses:
InfoGlueMySQLJDBCWorkflowStore

public class InfoGlueJDBCWorkflowStore
extends com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore

JDBC implementation just overiding the init-method of the default JDBCWorkflowStore as it demanded DataStores. The following properties are all required:

Author:
Mattias Bogeblad

Field Summary
 
Fields inherited from class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
closeConnWhenDone, currentPrevTable, currentTable, ds, entryId, entryName, entrySequence, entryState, entryTable, historyPrevTable, historyTable, stepActionId, stepCaller, stepDueDate, stepEntryId, stepFinishDate, stepId, stepOwner, stepPreviousId, stepSequence, stepStartDate, stepStatus, stepStepId
 
Constructor Summary
InfoGlueJDBCWorkflowStore()
           
 
Method Summary
 com.opensymphony.workflow.spi.Step createCurrentStep(long entryId, int wfStepId, java.lang.String owner, java.util.Date startDate, java.util.Date dueDate, java.lang.String status, long[] previousIds)
           
 com.opensymphony.workflow.spi.WorkflowEntry createEntry(java.lang.String workflowName)
           
 java.util.List findCurrentSteps(long entryId)
           
 com.opensymphony.workflow.spi.WorkflowEntry findEntry(long theEntryId)
           
 java.util.List findHistorySteps(long entryId)
           
protected  java.sql.Connection getConnection()
           
 void init(java.util.Map props)
           
 com.opensymphony.workflow.spi.Step markFinished(com.opensymphony.workflow.spi.Step step, int actionId, java.util.Date finishDate, java.lang.String status, java.lang.String caller)
           
 void moveToHistory(com.opensymphony.workflow.spi.Step step)
           
 java.util.List query(com.opensymphony.workflow.query.WorkflowQuery query)
           
 void setEntryState(long id, int state)
           
 
Methods inherited from class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
addPreviousSteps, checkIfORExists, cleanup, createCurrentStep, getNextEntrySequence, getNextStepSequence, getPropertySet, query
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InfoGlueJDBCWorkflowStore

public InfoGlueJDBCWorkflowStore()
Method Detail

init

public void init(java.util.Map props)
          throws com.opensymphony.workflow.StoreException
Specified by:
init in interface com.opensymphony.workflow.spi.WorkflowStore
Overrides:
init in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
com.opensymphony.workflow.StoreException

getConnection

protected java.sql.Connection getConnection()
                                     throws java.sql.SQLException
Overrides:
getConnection in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
java.sql.SQLException

setEntryState

public void setEntryState(long id,
                          int state)
                   throws com.opensymphony.workflow.StoreException
Specified by:
setEntryState in interface com.opensymphony.workflow.spi.WorkflowStore
Overrides:
setEntryState in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
com.opensymphony.workflow.StoreException

createCurrentStep

public com.opensymphony.workflow.spi.Step createCurrentStep(long entryId,
                                                            int wfStepId,
                                                            java.lang.String owner,
                                                            java.util.Date startDate,
                                                            java.util.Date dueDate,
                                                            java.lang.String status,
                                                            long[] previousIds)
                                                     throws com.opensymphony.workflow.StoreException
Specified by:
createCurrentStep in interface com.opensymphony.workflow.spi.WorkflowStore
Overrides:
createCurrentStep in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
com.opensymphony.workflow.StoreException

createEntry

public com.opensymphony.workflow.spi.WorkflowEntry createEntry(java.lang.String workflowName)
                                                        throws com.opensymphony.workflow.StoreException
Specified by:
createEntry in interface com.opensymphony.workflow.spi.WorkflowStore
Overrides:
createEntry in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
com.opensymphony.workflow.StoreException

findCurrentSteps

public java.util.List findCurrentSteps(long entryId)
                                throws com.opensymphony.workflow.StoreException
Specified by:
findCurrentSteps in interface com.opensymphony.workflow.spi.WorkflowStore
Overrides:
findCurrentSteps in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
com.opensymphony.workflow.StoreException

findEntry

public com.opensymphony.workflow.spi.WorkflowEntry findEntry(long theEntryId)
                                                      throws com.opensymphony.workflow.StoreException
Specified by:
findEntry in interface com.opensymphony.workflow.spi.WorkflowStore
Overrides:
findEntry in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
com.opensymphony.workflow.StoreException

findHistorySteps

public java.util.List findHistorySteps(long entryId)
                                throws com.opensymphony.workflow.StoreException
Specified by:
findHistorySteps in interface com.opensymphony.workflow.spi.WorkflowStore
Overrides:
findHistorySteps in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
com.opensymphony.workflow.StoreException

markFinished

public com.opensymphony.workflow.spi.Step markFinished(com.opensymphony.workflow.spi.Step step,
                                                       int actionId,
                                                       java.util.Date finishDate,
                                                       java.lang.String status,
                                                       java.lang.String caller)
                                                throws com.opensymphony.workflow.StoreException
Specified by:
markFinished in interface com.opensymphony.workflow.spi.WorkflowStore
Overrides:
markFinished in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
com.opensymphony.workflow.StoreException

moveToHistory

public void moveToHistory(com.opensymphony.workflow.spi.Step step)
                   throws com.opensymphony.workflow.StoreException
Specified by:
moveToHistory in interface com.opensymphony.workflow.spi.WorkflowStore
Overrides:
moveToHistory in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
com.opensymphony.workflow.StoreException

query

public java.util.List query(com.opensymphony.workflow.query.WorkflowQuery query)
                     throws com.opensymphony.workflow.StoreException
Specified by:
query in interface com.opensymphony.workflow.spi.WorkflowStore
Overrides:
query in class com.opensymphony.workflow.spi.jdbc.JDBCWorkflowStore
Throws:
com.opensymphony.workflow.StoreException


Copyright © 2005 InfoGlue.org All Rights Reserved.