This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
FYI: Patch: gnu.java.net.protocol.*.Handler
- From: Michael Koch <konqueror at gmx dot de>
- To: java-patches at gcc dot gnu dot org
- Date: Wed, 26 Nov 2003 11:21:20 +0100
- Subject: FYI: Patch: gnu.java.net.protocol.*.Handler
Hi list,
I commited the attached obvious patch top add API documentation to two
Handler classes.
Michael
Index: ChangeLog
===================================================================
RCS file: /cvs/gcc/gcc/libjava/ChangeLog,v
retrieving revision 1.2360
diff -u -b -B -r1.2360 ChangeLog
--- ChangeLog 26 Nov 2003 10:11:44 -0000 1.2360
+++ ChangeLog 26 Nov 2003 10:17:34 -0000
@@ -1,5 +1,14 @@
2003-11-26 Michael Koch <konqueror@gmx.de>
+ * gnu/java/net/protocol/file/Handler.java
+ (Handler): New explicit constructor.
+ (openConnection): Added documentation.
+ * gnu/java/net/protocol/jar/Handler.java
+ (Handler): New explicit constructor.
+ (openConnection): Added documentation.
+
+2003-11-26 Michael Koch <konqueror@gmx.de>
+
* java/net/DatagramPacket.java
(DatagramPacket): Fixed documentation to become legal HTML.
Index: gnu/java/net/protocol/file/Handler.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/gnu/java/net/protocol/file/Handler.java,v
retrieving revision 1.2
diff -u -b -B -r1.2 Handler.java
--- gnu/java/net/protocol/file/Handler.java 18 Oct 2003 12:24:56 -0000 1.2
+++ gnu/java/net/protocol/file/Handler.java 26 Nov 2003 10:17:34 -0000
@@ -53,6 +53,22 @@
*/
public class Handler extends URLStreamHandler
{
+ /**
+ * A do nothing constructor
+ */
+ public Handler()
+ {
+ }
+
+ /**
+ * This method returs a new FileURLConnection for the specified URL
+ *
+ * @param url The URL to return a connection for
+ *
+ * @return The URLConnection
+ *
+ * @exception IOException If an error occurs
+ */
protected URLConnection openConnection(URL url) throws IOException
{
// If a hostname is set, then we need to switch protocols to ftp
Index: gnu/java/net/protocol/jar/Handler.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/gnu/java/net/protocol/jar/Handler.java,v
retrieving revision 1.2
diff -u -b -B -r1.2 Handler.java
--- gnu/java/net/protocol/jar/Handler.java 18 Oct 2003 12:24:57 -0000 1.2
+++ gnu/java/net/protocol/jar/Handler.java 26 Nov 2003 10:17:34 -0000
@@ -45,10 +45,25 @@
/**
* @author Kresten Krab Thorup <krab@gnu.org>
- * @date August 13, 1999.
*/
public class Handler extends URLStreamHandler
{
+ /**
+ * A do nothing constructor
+ */
+ public Handler()
+ {
+ }
+
+ /**
+ * This method returs a new JarURLConnection for the specified URL
+ *
+ * @param url The URL to return a connection for
+ *
+ * @return The URLConnection
+ *
+ * @exception IOException If an error occurs
+ */
protected URLConnection openConnection(URL url) throws IOException
{
return new Connection(url);