1 16 17 package org.springframework.orm.jpa; 18 19 import java.sql.SQLException ; 20 21 import javax.persistence.EntityManager; 22 import javax.persistence.EntityManagerFactory; 23 import javax.persistence.PersistenceException; 24 25 import org.springframework.dao.support.PersistenceExceptionTranslator; 26 import org.springframework.jdbc.datasource.ConnectionHandle; 27 import org.springframework.transaction.TransactionDefinition; 28 import org.springframework.transaction.TransactionException; 29 30 55 public interface JpaDialect extends PersistenceExceptionTranslator { 56 57 61 67 boolean supportsEntityManagerFactoryPlusOperations(); 68 69 75 boolean supportsEntityManagerPlusOperations(); 76 77 85 EntityManagerFactoryPlusOperations getEntityManagerFactoryPlusOperations(EntityManagerFactory rawEntityManager); 86 87 95 EntityManagerPlusOperations getEntityManagerPlusOperations(EntityManager rawEntityManager); 96 97 98 102 127 Object beginTransaction(EntityManager entityManager, TransactionDefinition definition) 128 throws PersistenceException, SQLException , TransactionException; 129 130 141 void cleanupTransaction(Object transactionData); 142 143 174 ConnectionHandle getJdbcConnection(EntityManager entityManager, boolean readOnly) 175 throws PersistenceException, SQLException ; 176 177 190 void releaseJdbcConnection(ConnectionHandle conHandle, EntityManager entityManager) 191 throws PersistenceException, SQLException ; 192 193 } 194 | Popular Tags |