8031326: Use Class<?> rather than Class in java.net method signatures
authordarcy
Tue, 07 Jan 2014 09:58:16 -0800
changeset 22119 da8b8a10483f
parent 22118 02c4fd429df0
child 22120 3ec2fa1035de
8031326: Use Class<?> rather than Class in java.net method signatures Reviewed-by: alanb, chegar
jdk/src/share/classes/java/net/URL.java
jdk/src/share/classes/java/net/URLConnection.java
--- a/jdk/src/share/classes/java/net/URL.java	Tue Jan 07 11:50:15 2014 -0500
+++ b/jdk/src/share/classes/java/net/URL.java	Tue Jan 07 09:58:16 2014 -0800
@@ -1055,7 +1055,7 @@
     /**
      * Gets the contents of this URL. This method is a shorthand for:
      * <blockquote><pre>
-     *     openConnection().getContent(Class[])
+     *     openConnection().getContent(classes)
      * </pre></blockquote>
      *
      * @param classes an array of Java types
@@ -1066,7 +1066,7 @@
      * @see        java.net.URLConnection#getContent(Class[])
      * @since 1.3
      */
-    public final Object getContent(Class[] classes)
+    public final Object getContent(Class<?>[] classes)
     throws java.io.IOException {
         return openConnection().getContent(classes);
     }
--- a/jdk/src/share/classes/java/net/URLConnection.java	Tue Jan 07 11:50:15 2014 -0500
+++ b/jdk/src/share/classes/java/net/URLConnection.java	Tue Jan 07 09:58:16 2014 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2014, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -760,7 +760,7 @@
      * @see        java.net.URLConnection#setContentHandlerFactory(java.net.ContentHandlerFactory)
      * @since 1.3
      */
-    public Object getContent(Class[] classes) throws IOException {
+    public Object getContent(Class<?>[] classes) throws IOException {
         // Must call getInputStream before GetHeaderField gets called
         // so that FileNotFoundException has a chance to be thrown up
         // from here without being caught.