Package org.apache.openjpa.persistence
Class PersistenceExceptions
java.lang.Object
org.apache.openjpa.util.Exceptions
org.apache.openjpa.persistence.PersistenceExceptions
Converts from OpenJPA to persistence exception types.
- Author:
- Abe White, Marc Prud'hommeaux
-
Field Summary
Fields inherited from class org.apache.openjpa.util.Exceptions
EMPTY_THROWABLES
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic RuntimeExceptionTranslator
Returns aRuntimeExceptionTranslator
that will perform the correct exception translation as well as roll back the current transaction when for all butNoResultException
andNonUniqueResultException
in accordance with section 3.7 of the EJB 3.0 specification.static RuntimeException
Convert the given throwable to the proper persistence exception.Methods inherited from class org.apache.openjpa.util.Exceptions
printNestedThrowables, printNestedThrowables, replaceFailedObject, replaceNestedThrowables, toClassName, toClassNames, toString, toString, toString
-
Field Details
-
TRANSLATOR
-
-
Constructor Details
-
PersistenceExceptions
public PersistenceExceptions()
-
-
Method Details
-
getRollbackTranslator
Returns aRuntimeExceptionTranslator
that will perform the correct exception translation as well as roll back the current transaction when for all butNoResultException
andNonUniqueResultException
in accordance with section 3.7 of the EJB 3.0 specification. -
toPersistenceException
Convert the given throwable to the proper persistence exception.
-