org.springframework.orm.hibernate4
Class SpringFlushSynchronization

java.lang.Object
  extended by org.springframework.transaction.support.TransactionSynchronizationAdapter
      extended by org.springframework.orm.hibernate4.SpringFlushSynchronization
All Implemented Interfaces:
Ordered, TransactionSynchronization

 class SpringFlushSynchronization
extends TransactionSynchronizationAdapter

Simple synchronization adapter that propagates a flush() call to the underlying Hibernate Session. Used in combination with JTA.

Since:
3.1
Author:
Juergen Hoeller

Field Summary
private  Session session
           
 
Fields inherited from interface org.springframework.transaction.support.TransactionSynchronization
STATUS_COMMITTED, STATUS_ROLLED_BACK, STATUS_UNKNOWN
 
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
 
Constructor Summary
SpringFlushSynchronization(Session session)
           
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 void flush()
          Flush the underlying session to the datastore, if applicable: for example, a Hibernate/JPA session.
 int hashCode()
           
 
Methods inherited from class org.springframework.transaction.support.TransactionSynchronizationAdapter
afterCommit, afterCompletion, beforeCommit, beforeCompletion, getOrder, resume, suspend
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

session

private final Session session
Constructor Detail

SpringFlushSynchronization

public SpringFlushSynchronization(Session session)
Method Detail

flush

public void flush()
Description copied from interface: TransactionSynchronization
Flush the underlying session to the datastore, if applicable: for example, a Hibernate/JPA session.

Specified by:
flush in interface TransactionSynchronization
Overrides:
flush in class TransactionSynchronizationAdapter
See Also:
TransactionStatus.flush()

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object