hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r369242 - in /jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote: ./ impl/
Date Sun, 15 Jan 2006 18:00:50 GMT
Author: olegk
Date: Sun Jan 15 10:00:30 2006
New Revision: 369242

URL: http://svn.apache.org/viewcvs?rev=369242&view=rev
Log:
Made CoyoteHttpConnection an interface backed by a default impl class

Added:
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CommitTrigger.java
      - copied, changed from r369238, jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CommitTrigger.java
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CoyoteHttpConnection.java
  (with props)
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CoyoteHttpConnectionImpl.java
      - copied, changed from r369238, jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CoyoteHttpConnection.java
Removed:
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CommitTrigger.java
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CoyoteHttpConnection.java
Modified:
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/HttpConnectionFactory.java
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/HttpConnectionManager.java
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultConnectionListener.java
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionFactory.java
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionManager.java
  (contents, props changed)
    jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/HttpConnectionProcessor.java

Copied: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CommitTrigger.java
(from r369238, jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CommitTrigger.java)
URL: http://svn.apache.org/viewcvs/jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CommitTrigger.java?p2=jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CommitTrigger.java&p1=jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CommitTrigger.java&r1=369238&r2=369242&rev=369242&view=diff
==============================================================================
--- jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CommitTrigger.java
(original)
+++ jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CommitTrigger.java
Sun Jan 15 10:00:30 2006
@@ -27,7 +27,7 @@
  *
  */
 
-package org.apache.http.coyote.impl;
+package org.apache.http.coyote;
 
 import java.io.IOException;
 

Added: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CoyoteHttpConnection.java
URL: http://svn.apache.org/viewcvs/jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CoyoteHttpConnection.java?rev=369242&view=auto
==============================================================================
--- jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CoyoteHttpConnection.java
(added)
+++ jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CoyoteHttpConnection.java
Sun Jan 15 10:00:30 2006
@@ -0,0 +1,70 @@
+/*
+ * $HeadURL$
+ * $Revision$
+ * $Date$
+ *
+ * ====================================================================
+ *
+ *  Copyright 1999-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ * ====================================================================
+ *
+ * This software consists of voluntary contributions made by many
+ * individuals on behalf of the Apache Software Foundation.  For more
+ * information on the Apache Software Foundation, please see
+ * <http://www.apache.org/>.
+ *
+ */
+
+package org.apache.http.coyote;
+
+import java.io.IOException;
+
+import org.apache.coyote.InputBuffer;
+import org.apache.coyote.OutputBuffer;
+import org.apache.http.HttpConnection;
+import org.apache.http.HttpException;
+import org.apache.http.HttpMutableRequest;
+import org.apache.http.HttpResponse;
+import org.apache.http.params.HttpParams;
+
+/**
+ * <p>
+ * </p>
+ * @author <a href="mailto:oleg at ural.ru">Oleg Kalnichevski</a>
+ *
+ * @version $Revision$
+ */
+public interface CoyoteHttpConnection extends HttpConnection, InputBuffer, OutputBuffer {
+
+    CommitTrigger getCommitTrigger();
+
+    void setCommitTrigger(CommitTrigger commitTrigger);
+
+    HttpMutableRequest readRequest(HttpParams params)
+            throws HttpException, IOException; 
+    
+    void closeInput() 
+            throws IOException;
+    
+    void sendResponse(HttpResponse response) 
+            throws HttpException, IOException;
+    
+    void flush() 
+            throws IOException;
+
+    void closeOutput() 
+            throws IOException;
+    
+}

Propchange: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CoyoteHttpConnection.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CoyoteHttpConnection.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/CoyoteHttpConnection.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/HttpConnectionFactory.java
URL: http://svn.apache.org/viewcvs/jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/HttpConnectionFactory.java?rev=369242&r1=369241&r2=369242&view=diff
==============================================================================
--- jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/HttpConnectionFactory.java
(original)
+++ jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/HttpConnectionFactory.java
Sun Jan 15 10:00:30 2006
@@ -32,8 +32,6 @@
 import java.io.IOException;
 import java.net.Socket;
 
-import org.apache.http.coyote.impl.CoyoteHttpConnection;
-
 /**
  * <p>
  * </p>

Modified: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/HttpConnectionManager.java
URL: http://svn.apache.org/viewcvs/jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/HttpConnectionManager.java?rev=369242&r1=369241&r2=369242&view=diff
==============================================================================
--- jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/HttpConnectionManager.java
(original)
+++ jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/HttpConnectionManager.java
Sun Jan 15 10:00:30 2006
@@ -29,8 +29,6 @@
 
 package org.apache.http.coyote;
 
-import org.apache.http.coyote.impl.CoyoteHttpConnection;
-
 /**
  * <p>
  * </p>

Copied: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CoyoteHttpConnectionImpl.java
(from r369238, jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CoyoteHttpConnection.java)
URL: http://svn.apache.org/viewcvs/jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CoyoteHttpConnectionImpl.java?p2=jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CoyoteHttpConnectionImpl.java&p1=jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CoyoteHttpConnection.java&r1=369238&r2=369242&rev=369242&view=diff
==============================================================================
--- jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CoyoteHttpConnection.java
(original)
+++ jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/CoyoteHttpConnectionImpl.java
Sun Jan 15 10:00:30 2006
@@ -35,14 +35,11 @@
 import java.net.Socket;
 import java.net.SocketAddress;
 
-import org.apache.coyote.InputBuffer;
-import org.apache.coyote.OutputBuffer;
 import org.apache.coyote.Request;
 import org.apache.coyote.Response;
 import org.apache.http.ConnectionClosedException;
 import org.apache.http.Header;
 import org.apache.http.HeaderElement;
-import org.apache.http.HttpConnection;
 import org.apache.http.HttpEntity;
 import org.apache.http.HttpEntityEnclosingRequest;
 import org.apache.http.HttpException;
@@ -53,6 +50,8 @@
 import org.apache.http.ProtocolException;
 import org.apache.http.RequestLine;
 import org.apache.http.StatusLine;
+import org.apache.http.coyote.CommitTrigger;
+import org.apache.http.coyote.CoyoteHttpConnection;
 import org.apache.http.impl.DefaultHttpRequestFactory;
 import org.apache.http.impl.io.SocketHttpDataReceiver;
 import org.apache.http.impl.io.SocketHttpDataTransmitter;
@@ -77,7 +76,7 @@
  *
  * @version $Revision$
  */
-public class CoyoteHttpConnection implements HttpConnection, InputBuffer, OutputBuffer {
+public class CoyoteHttpConnectionImpl implements CoyoteHttpConnection {
 
     private final Socket socket;
     private final HttpDataTransmitter datatransmitter;
@@ -90,7 +89,7 @@
     private OutputStream out = null;
     private InputStream in = null;
     
-    public CoyoteHttpConnection(final Socket socket, final HttpParams params) 
+    public CoyoteHttpConnectionImpl(final Socket socket, final HttpParams params) 
             throws IOException {
         super();
         if (socket == null) {

Modified: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultConnectionListener.java
URL: http://svn.apache.org/viewcvs/jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultConnectionListener.java?rev=369242&r1=369241&r2=369242&view=diff
==============================================================================
--- jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultConnectionListener.java
(original)
+++ jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultConnectionListener.java
Sun Jan 15 10:00:30 2006
@@ -35,6 +35,7 @@
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.apache.http.coyote.CoyoteHttpConnection;
 import org.apache.http.coyote.HttpConnectionFactory;
 import org.apache.http.coyote.HttpConnectionManager;
 import org.apache.http.coyote.IOProcessor;

Modified: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionFactory.java
URL: http://svn.apache.org/viewcvs/jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionFactory.java?rev=369242&r1=369241&r2=369242&view=diff
==============================================================================
--- jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionFactory.java
(original)
+++ jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionFactory.java
Sun Jan 15 10:00:30 2006
@@ -32,6 +32,7 @@
 import java.io.IOException;
 import java.net.Socket;
 
+import org.apache.http.coyote.CoyoteHttpConnection;
 import org.apache.http.coyote.HttpConnectionFactory;
 import org.apache.http.params.HttpParams;
 
@@ -56,7 +57,7 @@
     
     public CoyoteHttpConnection newConnection(final Socket socket)
             throws IOException {
-        return new CoyoteHttpConnection(socket, this.params);
+        return new CoyoteHttpConnectionImpl(socket, this.params);
     }
     
 }

Modified: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionManager.java
URL: http://svn.apache.org/viewcvs/jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionManager.java?rev=369242&r1=369241&r2=369242&view=diff
==============================================================================
--- jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionManager.java
(original)
+++ jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionManager.java
Sun Jan 15 10:00:30 2006
@@ -37,6 +37,7 @@
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.apache.coyote.Adapter;
+import org.apache.http.coyote.CoyoteHttpConnection;
 import org.apache.http.coyote.HttpConnectionManager;
 import org.apache.http.coyote.IOProcessingListener;
 import org.apache.http.coyote.IOProcessor;

Propchange: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/DefaultHttpConnectionManager.java
            ('svn:executable' removed)

Modified: jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/HttpConnectionProcessor.java
URL: http://svn.apache.org/viewcvs/jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/HttpConnectionProcessor.java?rev=369242&r1=369241&r2=369242&view=diff
==============================================================================
--- jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/HttpConnectionProcessor.java
(original)
+++ jakarta/httpcomponents/trunk/coyote-httpconnector/src/java/org/apache/http/coyote/impl/HttpConnectionProcessor.java
Sun Jan 15 10:00:30 2006
@@ -59,6 +59,8 @@
 import org.apache.http.ProtocolException;
 import org.apache.http.RequestLine;
 import org.apache.http.StatusLine;
+import org.apache.http.coyote.CommitTrigger;
+import org.apache.http.coyote.CoyoteHttpConnection;
 import org.apache.http.coyote.IOProcessingListener;
 import org.apache.http.coyote.IOProcessor;
 import org.apache.http.coyote.MalformedURIException;



Mime
View raw message