From: markt Date: Thu, 20 Nov 2008 00:10:48 +0000 (+0000) Subject: Relax generics checks otherwise an call with a Properties object will not compile. X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=8019b2997cc900e070e7915a5e0f3b1aea444dbf;p=tomcat7.0 Relax generics checks otherwise an call with a Properties object will not compile. git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@719136 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/java/org/apache/tomcat/util/IntrospectionUtils.java b/java/org/apache/tomcat/util/IntrospectionUtils.java index d333934bb..2a46bcbff 100644 --- a/java/org/apache/tomcat/util/IntrospectionUtils.java +++ b/java/org/apache/tomcat/util/IntrospectionUtils.java @@ -472,7 +472,7 @@ public final class IntrospectionUtils { * Replace ${NAME} with the property value */ public static String replaceProperties(String value, - Hashtable staticProp, PropertySource dynamicProp[]) { + Hashtable staticProp, PropertySource dynamicProp[]) { if (value.indexOf("$") < 0) { return value; } @@ -500,7 +500,7 @@ public final class IntrospectionUtils { String n = value.substring(pos + 2, endName); String v = null; if (staticProp != null) { - v = staticProp.get(n); + v = (String) staticProp.get(n); } if (v == null && dynamicProp != null) { for (int i = 0; i < dynamicProp.length; i++) { @@ -716,10 +716,10 @@ public final class IntrospectionUtils { //args0=findVoidSetters(proxy.getClass()); args0 = findBooleanSetters(proxy.getClass()); } - Hashtable h = null; + Hashtable h = null; if (null != findMethod(proxy.getClass(), "getOptionAliases", new Class[] {})) { - h = (Hashtable) callMethod0(proxy, + h = (Hashtable) callMethod0(proxy, "getOptionAliases"); } return processArgs(proxy, args, args0, null, h); @@ -727,13 +727,13 @@ public final class IntrospectionUtils { public static boolean processArgs(Object proxy, String args[], String args0[], String args1[], - Hashtable aliases) throws Exception { + Hashtable aliases) throws Exception { for (int i = 0; i < args.length; i++) { String arg = args[i]; if (arg.startsWith("-")) arg = arg.substring(1); if (aliases != null && aliases.get(arg) != null) - arg = aliases.get(arg); + arg = (String) aliases.get(arg); if (args0 != null) { boolean set = false;