Package org.hibernate.engine.spi
Interface ExceptionConverter
-
- All Known Implementing Classes:
ExceptionConverterImpl
public interface ExceptionConverter
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description RuntimeException
convert(RuntimeException e)
RuntimeException
convert(RuntimeException e, LockOptions lockOptions)
JDBCException
convert(SQLException e, String message)
RuntimeException
convert(HibernateException e)
Converts a Hibernate-specific exception into a JPA-specified exception; note that the JPA specification makes use of exceptions outside its exception hierarchy, though they are all runtime exceptions.RuntimeException
convert(HibernateException e, LockOptions lockOptions)
Converts a Hibernate-specific exception into a JPA-specified exception; note that the JPA specification makes use of exceptions outside its exception hierarchy, though they are all runtime exceptions.RuntimeException
convertCommitException(RuntimeException e)
Converts the exception thrown during the transaction commit phase
-
-
-
Method Detail
-
convertCommitException
RuntimeException convertCommitException(RuntimeException e)
Converts the exception thrown during the transaction commit phase- Parameters:
e
- The exception being handled- Returns:
- The converted exception
-
convert
RuntimeException convert(HibernateException e, LockOptions lockOptions)
Converts a Hibernate-specific exception into a JPA-specified exception; note that the JPA specification makes use of exceptions outside its exception hierarchy, though they are all runtime exceptions.- Parameters:
e
- The Hibernate exception.lockOptions
- The lock options in effect at the time of exception (can be null)- Returns:
- The JPA-specified exception
-
convert
RuntimeException convert(HibernateException e)
Converts a Hibernate-specific exception into a JPA-specified exception; note that the JPA specification makes use of exceptions outside its exception hierarchy, though they are all runtime exceptions.- Parameters:
e
- The Hibernate exception.- Returns:
- The JPA-specified exception
-
convert
RuntimeException convert(RuntimeException e)
-
convert
RuntimeException convert(RuntimeException e, LockOptions lockOptions)
-
convert
JDBCException convert(SQLException e, String message)
-
-