< prev index next >

src/java.base/share/classes/java/net/InetAddress.java

Print this page

        

*** 1643,1653 **** * property can vary across implementations of the java. * classes. The default is an empty String "". */ String prefix = GetPropertyAction.getProperty("impl.prefix", ""); try { ! impl = Class.forName("java.net." + prefix + implName).newInstance(); } catch (ClassNotFoundException e) { System.err.println("Class not found: java.net." + prefix + implName + ":\ncheck impl.prefix property " + "in your properties file."); } catch (InstantiationException e) { --- 1643,1655 ---- * property can vary across implementations of the java. * classes. The default is an empty String "". */ String prefix = GetPropertyAction.getProperty("impl.prefix", ""); try { ! @SuppressWarnings("deprecation") ! Object tmp = Class.forName("java.net." + prefix + implName).newInstance(); ! impl = tmp; } catch (ClassNotFoundException e) { System.err.println("Class not found: java.net." + prefix + implName + ":\ncheck impl.prefix property " + "in your properties file."); } catch (InstantiationException e) {
*** 1660,1670 **** "in your properties file."); } if (impl == null) { try { ! impl = Class.forName(implName).newInstance(); } catch (Exception e) { throw new Error("System property impl.prefix incorrect"); } } --- 1662,1674 ---- "in your properties file."); } if (impl == null) { try { ! @SuppressWarnings("deprecation") ! Object tmp = Class.forName(implName).newInstance(); ! impl = tmp; } catch (Exception e) { throw new Error("System property impl.prefix incorrect"); } }
< prev index next >