bucket.core.persistence.hibernate
Class HibernateEntityObjectQueue

java.lang.Object
  extended by bucket.core.persistence.hibernate.HibernateEntityObjectQueue
All Implemented Interfaces:
EntityObjectQueue

public class HibernateEntityObjectQueue
extends Object
implements EntityObjectQueue

Used for batch indexing.


Field Summary
static org.apache.log4j.Logger log
          Deprecated. 
 
Constructor Summary
HibernateEntityObjectQueue(List handles, net.sf.hibernate.SessionFactory sessionFactory)
           
 
Method Summary
 void clearCaches()
          Clear any underlying caches that might be kept as the queue is run through.
 void close()
          Release all resources (i.e.
 List getNextObjects()
          Get a collection of the next "group" of objects from the queue.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

@Deprecated
public static final org.apache.log4j.Logger log
Deprecated. 
Constructor Detail

HibernateEntityObjectQueue

public HibernateEntityObjectQueue(List handles,
                                  net.sf.hibernate.SessionFactory sessionFactory)
                           throws net.sf.hibernate.HibernateException
Throws:
net.sf.hibernate.HibernateException
Method Detail

getNextObjects

public List getNextObjects()
Description copied from interface: EntityObjectQueue
Get a collection of the next "group" of objects from the queue. The size of this group is determined by the queue itself, it's just a "reasonable" size for the underlying implementation. If there are no more objects available, an empty list will be returned.

Specified by:
getNextObjects in interface EntityObjectQueue
Returns:
the next "group" of objects from the queue, or the empty list if there are no more objects available.

clearCaches

public void clearCaches()
Description copied from interface: EntityObjectQueue
Clear any underlying caches that might be kept as the queue is run through. This is an efficiency measure for when an operation is running through a large number of objects, and the underlying DAO implementation hangs on to memory for the entire session.

Specified by:
clearCaches in interface EntityObjectQueue

close

public void close()
Description copied from interface: EntityObjectQueue
Release all resources (i.e. database connections) held by the queue. Anyone who retrieves a queue is responsible for closing it when they are done.

Specified by:
close in interface EntityObjectQueue


Copyright © 2003-2010 Atlassian. All Rights Reserved.