Package org.hibernate.internal
Class ExceptionConverterImpl
java.lang.Object
org.hibernate.internal.ExceptionConverterImpl
- All Implemented Interfaces:
ExceptionConverter
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionconvert
(RuntimeException exception) convert
(RuntimeException exception, LockOptions lockOptions) convert
(SQLException e, String message) convert
(HibernateException exception) 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.convert
(HibernateException exception, 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.convertCommitException
(RuntimeException exception) Converts the exception thrown during the transaction commit phaseprotected PersistenceException
wrapLockException
(HibernateException exception, LockOptions lockOptions) protected PersistenceException
wrapStaleStateException
(StaleStateException exception)
-
Constructor Details
-
Method Details
-
convertCommitException
Description copied from interface:ExceptionConverter
Converts the exception thrown during the transaction commit phase- Specified by:
convertCommitException
in interfaceExceptionConverter
- Parameters:
exception
- The exception being handled- Returns:
- The converted exception
-
convert
Description copied from interface:ExceptionConverter
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.- Specified by:
convert
in interfaceExceptionConverter
- Parameters:
exception
- The Hibernate exception.lockOptions
- The lock options in effect at the time of exception (can be null)- Returns:
- The JPA-specified exception
-
convert
Description copied from interface:ExceptionConverter
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.- Specified by:
convert
in interfaceExceptionConverter
- Parameters:
exception
- The Hibernate exception.- Returns:
- The JPA-specified exception
-
convert
- Specified by:
convert
in interfaceExceptionConverter
-
convert
- Specified by:
convert
in interfaceExceptionConverter
-
convert
- Specified by:
convert
in interfaceExceptionConverter
-
wrapStaleStateException
-
wrapLockException
protected PersistenceException wrapLockException(HibernateException exception, LockOptions lockOptions)
-