use of org.jooq.tools.LoggerListener in project jOOQ by jOOQ.
the class ExecuteListeners method listeners.
/**
* Provide delegate listeners from an <code>ExecuteContext</code>
*/
private static ExecuteListener[] listeners(ExecuteContext ctx) {
List<ExecuteListener> result = new ArrayList<ExecuteListener>();
for (ExecuteListenerProvider provider : ctx.configuration().executeListenerProviders()) // Could be null after deserialisation
if (provider != null)
result.add(provider.provide());
if (!FALSE.equals(ctx.configuration().settings().isExecuteLogging())) {
result.add(new LoggerListener());
result.add(new StopWatchListener());
}
return result.toArray(EMPTY_EXECUTE_LISTENER);
}
Aggregations