tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1360470 - in /tomcat/trunk/java/org/apache/catalina: core/AsyncContextImpl.java startup/Tomcat.java
Date Wed, 11 Jul 2012 23:15:00 GMT
Author: markt
Date: Wed Jul 11 23:15:00 2012
New Revision: 1360470

URL: http://svn.apache.org/viewvc?rev=1360470&view=rev
Log:
Fix a few Eclipse warnings

Modified:
    tomcat/trunk/java/org/apache/catalina/core/AsyncContextImpl.java
    tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java

Modified: tomcat/trunk/java/org/apache/catalina/core/AsyncContextImpl.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/core/AsyncContextImpl.java?rev=1360470&r1=1360469&r2=1360470&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/core/AsyncContextImpl.java (original)
+++ tomcat/trunk/java/org/apache/catalina/core/AsyncContextImpl.java Wed Jul 11 23:15:00 2012
@@ -64,7 +64,7 @@ public class AsyncContextImpl implements
 
     private ServletRequest servletRequest = null;
     private ServletResponse servletResponse = null;
-    private List<AsyncListenerWrapper> listeners = new ArrayList<AsyncListenerWrapper>();
+    private final List<AsyncListenerWrapper> listeners = new ArrayList<AsyncListenerWrapper>();
     private boolean hasOriginalRequestAndResponse = true;
     private volatile Runnable dispatch = null;
     private Context context = null;
@@ -122,7 +122,7 @@ public class AsyncContextImpl implements
         return true;
     }
 
-    public boolean canWrite() throws IOException {
+    public boolean canWrite() {
         if (request.getResponse().getCoyoteResponse().getWriteListener()==null) return false;
         ClassLoader oldCL = Thread.currentThread().getContextClassLoader();
         ClassLoader newCL = request.getContext().getLoader().getClassLoader();

Modified: tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java?rev=1360470&r1=1360469&r2=1360470&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java (original)
+++ tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java Wed Jul 11 23:15:00 2012
@@ -812,9 +812,9 @@ public class Tomcat {
         public boolean hasAsync() {
             if (isAsyncSupported()) return true;
             boolean result = false;
-            Class clazz = existing.getClass();
+            Class<?> clazz = existing.getClass();
             if (clazz.isAnnotationPresent(WebServlet.class)) {
-                WebServlet ws = (WebServlet)clazz.getAnnotation(WebServlet.class);
+                WebServlet ws = clazz.getAnnotation(WebServlet.class);
                 result = ws.asyncSupported();
             }
             return result;



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message