You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by te...@apache.org on 2009/10/06 14:08:32 UTC
svn commit: r822234 - in
/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol:
http/ https/ jar/
Author: tellison
Date: Tue Oct 6 12:08:32 2009
New Revision: 822234
URL: http://svn.apache.org/viewvc?rev=822234&view=rev
Log:
Rename {Http|Https|Jar}URLConnection types to show they are impls of abstract types with same name.
Added:
harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnectionImpl.java
- copied, changed from r821752, harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnection.java
harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/HttpsURLConnectionImpl.java
- copied, changed from r821752, harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/HttpsURLConnection.java
harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnectionImpl.java
- copied, changed from r821752, harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnection.java
Removed:
harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnection.java
harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/HttpsURLConnection.java
harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnection.java
Modified:
harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Handler.java
harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/Handler.java
harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/Handler.java
Modified: harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Handler.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Handler.java?rev=822234&r1=822233&r2=822234&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Handler.java (original)
+++ harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Handler.java Tue Oct 6 12:08:32 2009
@@ -44,7 +44,7 @@
*/
@Override
protected URLConnection openConnection(URL u) throws IOException {
- return new HttpURLConnection(u, getDefaultPort());
+ return new HttpURLConnectionImpl(u, getDefaultPort());
}
/**
@@ -72,7 +72,7 @@
if (null == u || null == proxy) {
throw new IllegalArgumentException(Msg.getString("K034b")); //$NON-NLS-1$
}
- return new HttpURLConnection(u, getDefaultPort(), proxy);
+ return new HttpURLConnectionImpl(u, getDefaultPort(), proxy);
}
/**
Copied: harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnectionImpl.java (from r821752, harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnection.java)
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnectionImpl.java?p2=harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnectionImpl.java&p1=harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnection.java&r1=821752&r2=822234&rev=822234&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnection.java (original)
+++ harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnectionImpl.java Tue Oct 6 12:08:32 2009
@@ -25,6 +25,7 @@
import java.net.Authenticator;
import java.net.CacheRequest;
import java.net.CacheResponse;
+import java.net.HttpURLConnection;
import java.net.InetAddress;
import java.net.InetSocketAddress;
import java.net.PasswordAuthentication;
@@ -58,7 +59,7 @@
* such as connecting, sending request and getting the content from the remote
* server.
*/
-public class HttpURLConnection extends java.net.HttpURLConnection {
+public class HttpURLConnectionImpl extends HttpURLConnection {
private static final String POST = "POST"; //$NON-NLS-1$
private static final String GET = "GET"; //$NON-NLS-1$
@@ -542,7 +543,7 @@
* @param url
* URL The URL this connection is connecting
*/
- protected HttpURLConnection(URL url) {
+ protected HttpURLConnectionImpl(URL url) {
this(url, 80);
}
@@ -554,7 +555,7 @@
* @param port
* int The default connection port
*/
- protected HttpURLConnection(URL url, int port) {
+ protected HttpURLConnectionImpl(URL url, int port) {
super(url);
defaultPort = port;
reqHeader = (Header) defaultReqHeader.clone();
@@ -582,7 +583,7 @@
* @param proxy
* Proxy The proxy which is used to make the connection
*/
- protected HttpURLConnection(URL url, int port, Proxy proxy) {
+ protected HttpURLConnectionImpl(URL url, int port, Proxy proxy) {
this(url, port);
this.proxy = proxy;
}
Modified: harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/Handler.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/Handler.java?rev=822234&r1=822233&r2=822234&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/Handler.java (original)
+++ harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/Handler.java Tue Oct 6 12:08:32 2009
@@ -32,7 +32,7 @@
@Override
protected URLConnection openConnection(URL url) throws IOException {
- return new HttpsURLConnection(url, getDefaultPort());
+ return new HttpsURLConnectionImpl(url, getDefaultPort());
}
@Override
@@ -42,7 +42,7 @@
// K034b=url and proxy can not be null
throw new IllegalArgumentException(Msg.getString("K034b")); //$NON-NLS-1$
}
- return new HttpsURLConnection(url, getDefaultPort(), proxy);
+ return new HttpsURLConnectionImpl(url, getDefaultPort(), proxy);
}
@Override
Copied: harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/HttpsURLConnectionImpl.java (from r821752, harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/HttpsURLConnection.java)
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/HttpsURLConnectionImpl.java?p2=harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/HttpsURLConnectionImpl.java&p1=harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/HttpsURLConnection.java&r1=821752&r2=822234&rev=822234&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/HttpsURLConnection.java (original)
+++ harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/https/HttpsURLConnectionImpl.java Tue Oct 6 12:08:32 2009
@@ -28,16 +28,17 @@
import java.util.List;
import java.util.Map;
+import javax.net.ssl.HttpsURLConnection;
import javax.net.ssl.SSLPeerUnverifiedException;
import javax.net.ssl.SSLSocket;
-import org.apache.harmony.luni.internal.net.www.protocol.http.HttpURLConnection;
+import org.apache.harmony.luni.internal.net.www.protocol.http.HttpURLConnectionImpl;
import org.apache.harmony.luni.internal.nls.Messages;
/**
* HttpsURLConnection implementation.
*/
-public class HttpsURLConnection extends javax.net.ssl.HttpsURLConnection {
+public class HttpsURLConnectionImpl extends HttpsURLConnection {
// Https engine to be wrapped
private final HttpsEngine httpsEngine;
@@ -45,12 +46,12 @@
// SSLSocket to be used for connection
private SSLSocket sslSocket;
- protected HttpsURLConnection(URL url, int port) {
+ protected HttpsURLConnectionImpl(URL url, int port) {
super(url);
httpsEngine = new HttpsEngine(url, port);
}
- protected HttpsURLConnection(URL url, int port, Proxy proxy) {
+ protected HttpsURLConnectionImpl(URL url, int port, Proxy proxy) {
super(url);
httpsEngine = new HttpsEngine(url, port, proxy);
}
@@ -345,7 +346,7 @@
/**
* HttpsEngine
*/
- private class HttpsEngine extends HttpURLConnection {
+ private class HttpsEngine extends HttpURLConnectionImpl {
// In case of using proxy this field indicates
// if it is a SSL Tunnel establishing stage
Modified: harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/Handler.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/Handler.java?rev=822234&r1=822233&r2=822234&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/Handler.java (original)
+++ harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/Handler.java Tue Oct 6 12:08:32 2009
@@ -42,7 +42,7 @@
*/
@Override
protected URLConnection openConnection(URL u) throws IOException {
- return new JarURLConnection(u);
+ return new JarURLConnectionImpl(u);
}
/**
Copied: harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnectionImpl.java (from r821752, harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnection.java)
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnectionImpl.java?p2=harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnectionImpl.java&p1=harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnection.java&r1=821752&r2=822234&rev=822234&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnection.java (original)
+++ harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnectionImpl.java Tue Oct 6 12:08:32 2009
@@ -25,6 +25,7 @@
import java.io.InputStream;
import java.net.ContentHandler;
import java.net.ContentHandlerFactory;
+import java.net.JarURLConnection;
import java.net.MalformedURLException;
import java.net.URL;
import java.security.AccessController;
@@ -46,9 +47,9 @@
* <p>
*
* This class is responsible for connecting and retrieving resources from a Jar
- * file which can be anywhere that can be refered to by an URL.
+ * file which can be anywhere that can be referred to by an URL.
*/
-public class JarURLConnection extends java.net.JarURLConnection {
+public class JarURLConnectionImpl extends JarURLConnection {
static HashMap<URL, JarFile> jarCache = new HashMap<URL, JarFile>();
@@ -69,7 +70,7 @@
* @throws java.net.MalformedURLException
* if the URL is malformed
*/
- public JarURLConnection(java.net.URL url) throws MalformedURLException, IOException {
+ public JarURLConnectionImpl(java.net.URL url) throws MalformedURLException, IOException {
super(url);
jarFileURL = getJarFileURL();
jarFileURLConnection = jarFileURL.openConnection();