Author: david.lloyd(a)jboss.com
Date: 2009-10-01 16:18:15 -0400 (Thu, 01 Oct 2009)
New Revision: 5552
Modified:
remoting3/trunk/jboss-remoting/src/main/java/org/jboss/remoting3/spi/AbstractHandleableCloseable.java
Log:
Carlo reminds us that we should not have private instance methods on abstract classes.
Modified:
remoting3/trunk/jboss-remoting/src/main/java/org/jboss/remoting3/spi/AbstractHandleableCloseable.java
===================================================================
---
remoting3/trunk/jboss-remoting/src/main/java/org/jboss/remoting3/spi/AbstractHandleableCloseable.java 2009-09-22
16:43:04 UTC (rev 5551)
+++
remoting3/trunk/jboss-remoting/src/main/java/org/jboss/remoting3/spi/AbstractHandleableCloseable.java 2009-10-01
20:18:15 UTC (rev 5552)
@@ -115,7 +115,7 @@
log.trace("Closed %s", this);
if (closeHandlers != null) {
for (final CloseHandler<? super T> handler :
closeHandlers.values()) {
- runCloseTask(new CloseHandlerTask<T>(handler));
+ runCloseTask(executor, new CloseHandlerTask<T>(handler));
}
}
closeAction();
@@ -143,11 +143,11 @@
return key;
}
}
- runCloseTask(new CloseHandlerTask<T>(handler));
+ runCloseTask(executor, new CloseHandlerTask<T>(handler));
return new NullKey();
}
- private void runCloseTask(final CloseHandlerTask<T> task) {
+ private static <T extends HandleableCloseable<T>> void runCloseTask(final
Executor executor, final CloseHandlerTask<T> task) {
try {
executor.execute(task);
} catch (RejectedExecutionException ree) {