< prev index next >

src/com/sun/javatest/util/Debug.java

Print this page
rev 145 : 7902237: Fixing raw use of parameterized class
Reviewed-by: jjg

@@ -130,11 +130,11 @@
      *
      * @param c Class whose name should be used to lookup the setting, null results in
      *    a return value of zero.
      * @return the debugging setting for the specified class
      */
-    public static boolean getBoolean(Class c) {
+    public static boolean getBoolean(Class<?> c) {
         init(false);
 
         if (!masterSwitch)
             return false;
 

@@ -154,11 +154,11 @@
      *    a return value of zero.
      * @param suffix String to append to the classname, null will result in a lookup
      *    of just the classname.
      * @return the debugging setting for the specified class
      */
-    public static boolean getBoolean(Class c, String suffix) {
+    public static boolean getBoolean(Class<?> c, String suffix) {
         init(false);
 
         if (!masterSwitch)
             return false;
 

@@ -198,11 +198,11 @@
      *
      * @param c the class whose name should be used to lookup the setting
      * @return the debugging setting for the given class, or 0 if no class
      *    was specified
      */
-    public static int getInt(Class c) {
+    public static int getInt(Class<?> c) {
         init(false);
 
         if (!masterSwitch || c == null)
             return 0;
 

@@ -222,11 +222,11 @@
      *    null results in a return value of zero.
      * @param suffix a string to append to the classname;
      *    null will result in a lookup of just the classname.
      * @return the debugging setting for the class
      */
-    public static int getInt(Class c, String suffix) {
+    public static int getInt(Class<?> c, String suffix) {
         init(false);
 
         if (!masterSwitch || c == null)
             return 0;
 

@@ -315,11 +315,11 @@
             // we're stuck, must disable debugging
             masterSwitch = false;
             return;
         }
 
-        Enumeration keys = props.propertyNames();
+        Enumeration<?> keys = props.propertyNames();
 
         dProps = new Properties();
         wildProps = new WildcardProperties();
 
         while (keys.hasMoreElements()) {

@@ -346,11 +346,11 @@
     /**
      * Convert a class object into a string appropriate for lookup.
      *
      * @param c Must not be null.
      */
-    private static String getName(Class c) {
+    private static String getName(Class<?> c) {
         // null checking skipped
 
         String name = c.getName();
 
         // compensate for inner classes for which getName() return the internal name

@@ -453,11 +453,11 @@
          */
         public String search(String key) {
             String lowerKey = key.toLowerCase();
             String target = trimTarget(lowerKey);
 
-            Enumeration keys = propertyNames();
+            Enumeration<?> keys = propertyNames();
             while (keys.hasMoreElements()) {
                 String k = (String)(keys.nextElement());
                 String lowerK = k.toLowerCase();
 
                 if (lowerK.startsWith(target)) {
< prev index next >