Interface ExceptionTranslatorExecuteListener
- All Superinterfaces:
EventListener,org.jooq.ExecuteListener,Serializable
public interface ExceptionTranslatorExecuteListener
extends org.jooq.ExecuteListener
An
ExecuteListener used by the auto-configured
DefaultExecuteListenerProvider to translate exceptions in the
ExecuteContext. Most commonly used to translate SQLExceptions to Spring-specific DataAccessExceptions by
adapting an existing SQLExceptionTranslator.- Since:
- 3.3.0
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ExceptionTranslatorExecuteListenerDefaultExceptionTranslatorExecuteListenersuitable for most applications. -
Method Summary
Static MethodsModifier and TypeMethodDescriptionof(Function<org.jooq.ExecuteContext, org.springframework.jdbc.support.SQLExceptionTranslator> translatorFactory) Creates a newExceptionTranslatorExecuteListenerbacked by anSQLExceptionTranslator.Methods inherited from interface org.jooq.ExecuteListener
bindEnd, bindStart, end, exception, executeEnd, executeStart, fetchEnd, fetchStart, outEnd, outStart, prepareEnd, prepareStart, recordEnd, recordStart, renderEnd, renderStart, resultEnd, resultStart, start, warning
-
Field Details
-
DEFAULT
DefaultExceptionTranslatorExecuteListenersuitable for most applications.
-
-
Method Details
-
of
static ExceptionTranslatorExecuteListener of(Function<org.jooq.ExecuteContext, org.springframework.jdbc.support.SQLExceptionTranslator> translatorFactory) Creates a newExceptionTranslatorExecuteListenerbacked by anSQLExceptionTranslator.- Parameters:
translatorFactory- factory function used to create theSQLExceptionTranslator- Returns:
- a new
ExceptionTranslatorExecuteListenerinstance
-