Author: markt
Date: Tue Dec 16 16:03:30 2014
New Revision: 1645993

URL: http://svn.apache.org/r1645993
Log:
Fix various IDE warnings

Modified:
    tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java
    tomcat/trunk/test/org/apache/coyote/ajp/TestAbstractAjpProcessor.java

Modified: tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java?rev=1645993&r1=1645992&r2=1645993&view=diff
==============================================================================
--- tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java (original)
+++ tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java Tue Dec 
16 16:03:30 2014
@@ -239,20 +239,13 @@ public abstract class TomcatBaseTest ext
 
     public static final class RequestDescriptor {
 
-        private final Map<String, String> requestInfo =
-            new HashMap<String, String>();
-        private final Map<String, String> contextInitParameters =
-            new HashMap<String, String>();
-        private final Map<String, String> contextAttributes =
-            new HashMap<String, String>();
-        private final Map<String, String> headers =
-            new HashMap<String, String>();
-        private final Map<String, String> attributes =
-            new HashMap<String, String>();
-        private final Map<String, String> params =
-            new HashMap<String, String>();
-        private final Map<String, String> sessionAttributes =
-            new HashMap<String, String>();
+        private final Map<String, String> requestInfo = new HashMap<>();
+        private final Map<String, String> contextInitParameters = new 
HashMap<>();
+        private final Map<String, String> contextAttributes = new HashMap<>();
+        private final Map<String, String> headers = new HashMap<>();
+        private final Map<String, String> attributes = new HashMap<>();
+        private final Map<String, String> params = new HashMap<>();
+        private final Map<String, String> sessionAttributes = new HashMap<>();
 
         public Map<String, String> getRequestInfo() {
             return requestInfo;
@@ -435,6 +428,7 @@ public abstract class TomcatBaseTest ext
 
         private static final long serialVersionUID = 1L;
 
+        @SuppressWarnings("deprecation")
         @Override
         public void service(HttpServletRequest request,
                             HttpServletResponse response)

Modified: tomcat/trunk/test/org/apache/coyote/ajp/TestAbstractAjpProcessor.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/ajp/TestAbstractAjpProcessor.java?rev=1645993&r1=1645992&r2=1645993&view=diff
==============================================================================
--- tomcat/trunk/test/org/apache/coyote/ajp/TestAbstractAjpProcessor.java 
(original)
+++ tomcat/trunk/test/org/apache/coyote/ajp/TestAbstractAjpProcessor.java Tue 
Dec 16 16:03:30 2014
@@ -90,7 +90,7 @@ public class TestAbstractAjpProcessor ex
         }
 
         String value;
-        Map<String, String> savedRequestInfo = new HashMap<String, String>();
+        Map<String, String> savedRequestInfo = new HashMap<>();
         for (String name: requestInfo.keySet()) {
             value = requestInfo.get(name);
             switch (name) {
@@ -116,7 +116,7 @@ public class TestAbstractAjpProcessor ex
                     ajpClient.setServerName(value);
                     break;
                 case "REQUEST-SERVER-PORT":
-                    ajpClient.setServerPort(Integer.valueOf(value));
+                    ajpClient.setServerPort(Integer.valueOf(value).intValue());
                     break;
                 case "REQUEST-IS-SECURE":
                     ajpClient.setSsl(Boolean.parseBoolean(value));



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

Reply via email to