< prev index next >

src/java.desktop/share/classes/java/beans/Introspector.java

Print this page

        

@@ -1281,12 +1281,13 @@
     static Object instantiate(Class<?> sibling, String className)
                  throws InstantiationException, IllegalAccessException,
                                                 ClassNotFoundException {
         // First check with sibling's classloader (if any).
         ClassLoader cl = sibling.getClassLoader();
-        Class<?> cls = ClassFinder.findClass(className, cl);
-        return cls.newInstance();
+        @SuppressWarnings("deprecation")
+        Object result = ClassFinder.findClass(className, cl).newInstance();
+        return result;
     }
 
 } // end class Introspector
 
 //===========================================================================
< prev index next >