public class ExceptionConverterImpl extends Object implements ExceptionConverter
Constructor and Description |
---|
ExceptionConverterImpl(SharedSessionContractImplementor sharedSessionContract) |
Modifier and Type | Method and Description |
---|---|
RuntimeException |
convert(HibernateException e)
Converts a Hibernate-specific exception into a JPA-specified exception; note that the JPA sepcification 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 sepcification makes use
of exceptions outside its exception hierarchy, though they are all runtime exceptions.
|
RuntimeException |
convert(RuntimeException e) |
RuntimeException |
convert(RuntimeException e,
LockOptions lockOptions) |
JDBCException |
convert(SQLException e,
String message) |
RuntimeException |
convertCommitException(RuntimeException e)
Converts the exception thrown during the transaction commit phase
|
protected PersistenceException |
wrapLockException(HibernateException e,
LockOptions lockOptions) |
protected PersistenceException |
wrapStaleStateException(StaleStateException e) |
public ExceptionConverterImpl(SharedSessionContractImplementor sharedSessionContract)
public RuntimeException convertCommitException(RuntimeException e)
ExceptionConverter
convertCommitException
in interface ExceptionConverter
e
- The exception being handledpublic RuntimeException convert(HibernateException e, LockOptions lockOptions)
ExceptionConverter
convert
in interface ExceptionConverter
e
- The Hibernate excepton.lockOptions
- The lock options in effect at the time of exception (can be null)public RuntimeException convert(HibernateException e)
ExceptionConverter
convert
in interface ExceptionConverter
e
- The Hibernate excepton.public RuntimeException convert(RuntimeException e)
convert
in interface ExceptionConverter
public RuntimeException convert(RuntimeException e, LockOptions lockOptions)
convert
in interface ExceptionConverter
public JDBCException convert(SQLException e, String message)
convert
in interface ExceptionConverter
protected PersistenceException wrapStaleStateException(StaleStateException e)
protected PersistenceException wrapLockException(HibernateException e, LockOptions lockOptions)
Copyright © 2019 JBoss by Red Hat. All rights reserved.