org.ikasan.framework.event.wiretap.dao
Class HibernateWiretapDao

java.lang.Object
  extended by org.springframework.dao.support.DaoSupport
      extended by org.springframework.orm.hibernate3.support.HibernateDaoSupport
          extended by org.ikasan.framework.event.wiretap.dao.HibernateWiretapDao
All Implemented Interfaces:
WiretapDao, org.springframework.beans.factory.InitializingBean

public class HibernateWiretapDao
extends org.springframework.orm.hibernate3.support.HibernateDaoSupport
implements WiretapDao

Hibernate implementation of the WiretapDao

Author:
Ikasan Development Team

Field Summary
 
Fields inherited from class org.springframework.dao.support.DaoSupport
logger
 
Constructor Summary
HibernateWiretapDao()
          Constructor
HibernateWiretapDao(boolean batchHousekeepDelete, Integer housekeepingBatchSize)
          Constructor
 
Method Summary
 void deleteAllExpired()
          Delete all of the expired wiretaps
 WiretapEvent findById(Long id)
          Find the Wiretap by its Id
 PagedWiretapSearchResult findPaging(Set<String> moduleNames, String moduleFlow, String componentName, String eventId, String payloadId, Date fromDate, Date untilDate, String payloadContent, int maxResults, int firstResult)
          Deprecated. - Use findWiretapEvents instead
 PagedSearchResult<WiretapEvent> findWiretapEvents(int pageNo, int pageSize, String orderBy, boolean orderAscending, Set<String> moduleNames, String moduleFlow, String componentName, String eventId, String payloadId, Date fromDate, Date untilDate, String payloadContent)
          Perform a paged search for WiretapEvents
 void save(WiretapEvent wiretapEvent)
          Save the wiretapEvent
 
Methods inherited from class org.springframework.orm.hibernate3.support.HibernateDaoSupport
checkDaoConfig, convertHibernateAccessException, createHibernateTemplate, getHibernateTemplate, getSession, getSession, getSessionFactory, releaseSession, setHibernateTemplate, setSessionFactory
 
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
 

Constructor Detail

HibernateWiretapDao

public HibernateWiretapDao()
Constructor


HibernateWiretapDao

public HibernateWiretapDao(boolean batchHousekeepDelete,
                           Integer housekeepingBatchSize)
Constructor

Parameters:
batchHousekeepDelete - - pass true if you want to use batch deleting
housekeepingBatchSize - - batch size, only respected if set to use batching
Method Detail

save

public void save(WiretapEvent wiretapEvent)
Save the wiretapEvent

Specified by:
save in interface WiretapDao
Parameters:
wiretapEvent - - The wiretap event to save
See Also:
WiretapDao.save( org.ikasan.framework.event.wiretap.model.WiretapEvent)

findById

public WiretapEvent findById(Long id)
Find the Wiretap by its Id

Specified by:
findById in interface WiretapDao
Parameters:
id - - The id to search on
Returns:
WiretapEvent
See Also:
org.ikasan.framework.event.wiretap.dao.WiretapDao#findById(java.lang. Long)

findPaging

@Deprecated
public PagedWiretapSearchResult findPaging(Set<String> moduleNames,
                                                      String moduleFlow,
                                                      String componentName,
                                                      String eventId,
                                                      String payloadId,
                                                      Date fromDate,
                                                      Date untilDate,
                                                      String payloadContent,
                                                      int maxResults,
                                                      int firstResult)
                                    throws org.springframework.dao.DataAccessException
Deprecated. - Use findWiretapEvents instead

Find paging list of wiretaps

Specified by:
findPaging in interface WiretapDao
Parameters:
moduleNames - - The list of module names
moduleFlow - - The name of Flow internal to the Module
componentName - - The component name
eventId - - The event id
payloadId - - The payload id
fromDate - - The from date
untilDate - - The to date
payloadContent - - The payload content
maxResults - - Max Results to bring back
firstResult - - The first result
Returns:
PagedWiretapSearchResult
Throws:
org.springframework.dao.DataAccessException - - Exception if we can't get the data

findWiretapEvents

public PagedSearchResult<WiretapEvent> findWiretapEvents(int pageNo,
                                                         int pageSize,
                                                         String orderBy,
                                                         boolean orderAscending,
                                                         Set<String> moduleNames,
                                                         String moduleFlow,
                                                         String componentName,
                                                         String eventId,
                                                         String payloadId,
                                                         Date fromDate,
                                                         Date untilDate,
                                                         String payloadContent)
Perform a paged search for WiretapEvents

Specified by:
findWiretapEvents in interface WiretapDao
Parameters:
pageNo - - The page number to retrieve
pageSize - - The size of the page
orderBy - - order by field
orderAscending - - ascending flag
moduleNames - - The list of module names
moduleFlow - - The name of Flow internal to the Module
componentName - - The component name
eventId - - The event id
payloadId - - The payload id
fromDate - - The from date
untilDate - - The to date
payloadContent - - The payload content
Returns:
PagedSearchResult

deleteAllExpired

public void deleteAllExpired()
Delete all of the expired wiretaps

Specified by:
deleteAllExpired in interface WiretapDao


Copyright © 2007-2012 Ikasan. All Rights Reserved.