public class

JDBCContext

extends Object
implements Serializable ConnectionManager.Callback
java.lang.Object
   ↳ org.hibernate.jdbc.JDBCContext

Class Overview

Acts as the mediary between "entity-mode related" sessions in terms of their interaction with the JDBC data store.

Summary

Nested Classes
interface JDBCContext.Context  
Public Constructors
JDBCContext(JDBCContext.Context owner, Connection connection, Interceptor interceptor)
Public Methods
void afterNontransactionalQuery(boolean success)
Called after executing a query outside the scope of a Hibernate or JTA transaction
void afterTransactionBegin(Transaction tx)
We cannot rely upon this method being called! It is only called if we are using Hibernate Transaction API.
void afterTransactionCompletion(boolean success, Transaction tx)
void beforeTransactionCompletion(Transaction tx)
Connection borrowConnection()
void cleanUpJtaSynchronizationCallbackCoordinator()
Connection connection()
void connectionCleanedUp()
void connectionOpened()
static JDBCContext deserialize(ObjectInputStream ois, JDBCContext.Context context, Interceptor interceptor)
Custom deserialization routine used during deserialization of a Session/PersistenceContext for increased performance.
ConnectionManager getConnectionManager()
SessionFactoryImplementor getFactory()
CallbackCoordinator getJtaSynchronizationCallbackCoordinator()
CallbackCoordinator getJtaSynchronizationCallbackCoordinator(javax.transaction.Transaction jtaTransaction)
Transaction getTransaction()
boolean isTransactionInProgress()
boolean registerCallbackIfNecessary()
boolean registerSynchronizationIfPossible()
void serialize(ObjectOutputStream oos)
Custom serialization routine used during serialization of a Session/PersistenceContext for increased performance.
[Expand]
Inherited Methods
From class java.lang.Object
From interface org.hibernate.jdbc.ConnectionManager.Callback

Public Constructors

public JDBCContext (JDBCContext.Context owner, Connection connection, Interceptor interceptor)

Public Methods

public void afterNontransactionalQuery (boolean success)

Called after executing a query outside the scope of a Hibernate or JTA transaction

public void afterTransactionBegin (Transaction tx)

We cannot rely upon this method being called! It is only called if we are using Hibernate Transaction API.

public void afterTransactionCompletion (boolean success, Transaction tx)

public void beforeTransactionCompletion (Transaction tx)

public Connection borrowConnection ()

public void cleanUpJtaSynchronizationCallbackCoordinator ()

public Connection connection ()

public void connectionCleanedUp ()

public void connectionOpened ()

public static JDBCContext deserialize (ObjectInputStream ois, JDBCContext.Context context, Interceptor interceptor)

Custom deserialization routine used during deserialization of a Session/PersistenceContext for increased performance.

Parameters
ois The stream from which to read the entry.
Throws
IOException

public ConnectionManager getConnectionManager ()

public SessionFactoryImplementor getFactory ()

public CallbackCoordinator getJtaSynchronizationCallbackCoordinator ()

public CallbackCoordinator getJtaSynchronizationCallbackCoordinator (javax.transaction.Transaction jtaTransaction)

public Transaction getTransaction ()

public boolean isTransactionInProgress ()

public boolean registerCallbackIfNecessary ()

public boolean registerSynchronizationIfPossible ()

public void serialize (ObjectOutputStream oos)

Custom serialization routine used during serialization of a Session/PersistenceContext for increased performance.

Parameters
oos The stream to which we should write the serial data.
Throws
IOException