hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r764588 - in /httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http: conn/params/ conn/routing/ impl/client/ impl/conn/
Date Mon, 13 Apr 2009 19:53:26 GMT
Author: olegk
Date: Mon Apr 13 19:53:25 2009
New Revision: 764588

URL: http://svn.apache.org/viewvc?rev=764588&view=rev
Log:
Javadoc updates

Modified:
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/params/ConnConnectionPNames.java
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/BasicRouteDirector.java
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRoute.java
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRouteDirector.java
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRoutePlanner.java
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/RouteInfo.java
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/RouteTracker.java
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/AbstractPoolEntry.java

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/params/ConnConnectionPNames.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/params/ConnConnectionPNames.java?rev=764588&r1=764587&r2=764588&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/params/ConnConnectionPNames.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/params/ConnConnectionPNames.java
Mon Apr 13 19:53:25 2009
@@ -55,8 +55,7 @@
      * <p>
      * This parameter expects a value of type {@link Integer}.
      * 0 disallows all garbage/empty lines before the status line.
-     * Use {@link java.lang.Integer#MAX_VALUE} for unlimited
-     * (default in lenient mode).
+     * Use {@link java.lang.Integer#MAX_VALUE} for unlimited number.
      * </p>
      */
     public static final String MAX_STATUS_LINE_GARBAGE = "http.connection.max-status-line-garbage";

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/BasicRouteDirector.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/BasicRouteDirector.java?rev=764588&r1=764587&r2=764588&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/BasicRouteDirector.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/BasicRouteDirector.java
Mon Apr 13 19:53:25 2009
@@ -33,24 +33,15 @@
 
 import net.jcip.annotations.Immutable;
 
-
 /**
  * Basic implementation of an {@link HttpRouteDirector HttpRouteDirector}.
  * This implementation is stateless and therefore thread-safe.
- * 
- *
- *
- * <!-- empty lines to avoid svn diff problems -->
- * @version $Revision$
  *
  * @since 4.0
  */
 @Immutable
 public class BasicRouteDirector implements HttpRouteDirector {
 
-    // public default constructor
-
-
     /**
      * Provides the next step.
      *
@@ -178,5 +169,4 @@
         return COMPLETE;
     }
 
-
-} // class BasicRouteDirector
+}

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRoute.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRoute.java?rev=764588&r1=764587&r2=764588&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRoute.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRoute.java
Mon Apr 13 19:53:25 2009
@@ -41,11 +41,6 @@
  * The route for a request.
  * Instances of this class are unmodifiable and therefore suitable
  * for use as lookup keys.
- * 
- *
- *
- * <!-- empty lines to avoid svn diff problems -->
- * @version $Revision$
  *
  * @since 4.0
  */
@@ -274,13 +269,11 @@
     }
 
 
-    // non-JavaDoc, see interface RouteInfo
     public final int getHopCount() {
         return proxyChain.length+1;
     }
 
 
-    // non-JavaDoc, see interface RouteInfo
     public final HttpHost getHopTarget(int hop) {
         if (hop < 0)
             throw new IllegalArgumentException
@@ -301,37 +294,31 @@
     }
 
 
-    // non-JavaDoc, see interface RouteInfo
     public final HttpHost getProxyHost() {
         return (this.proxyChain.length == 0) ? null : this.proxyChain[0];
     }
 
 
-    // non-JavaDoc, see interface RouteInfo
     public final TunnelType getTunnelType() {
         return this.tunnelled;
     }
 
 
-    // non-JavaDoc, see interface RouteInfo
     public final boolean isTunnelled() {
         return (this.tunnelled == TunnelType.TUNNELLED);
     }
 
 
-    // non-JavaDoc, see interface RouteInfo
     public final LayerType getLayerType() {
         return this.layered;
     }
 
 
-    // non-JavaDoc, see interface RouteInfo
     public final boolean isLayered() {
         return (this.layered == LayerType.LAYERED);
     }
 
 
-    // non-JavaDoc, see interface RouteInfo
     public final boolean isSecure() {
         return this.secure;
     }
@@ -441,5 +428,4 @@
         return super.clone();
     }
 
-
-} // class HttpRoute
+}

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRouteDirector.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRouteDirector.java?rev=764588&r1=764587&r2=764588&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRouteDirector.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRouteDirector.java
Mon Apr 13 19:53:25 2009
@@ -31,17 +31,10 @@
 
 package org.apache.http.conn.routing;
 
-
-
 /**
  * Provides directions on establishing a route.
  * Implementations of this interface compare a planned route with
  * a tracked route and indicate the next step required.
- * 
- *
- *
- * <!-- empty lines to avoid svn diff problems -->
- * @version $Revision$
  *
  * @since 4.0
  */
@@ -80,8 +73,6 @@
      *          either the next step to perform, or success, or failure.
      *          0 is for success, a negative value for failure.
      */
-    public int nextStep(RouteInfo plan, RouteInfo fact)
-        ;
-
+    public int nextStep(RouteInfo plan, RouteInfo fact);
 
-} // interface HttpRouteDirector
+}

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRoutePlanner.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRoutePlanner.java?rev=764588&r1=764587&r2=764588&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRoutePlanner.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/HttpRoutePlanner.java
Mon Apr 13 19:53:25 2009
@@ -36,8 +36,6 @@
 import org.apache.http.HttpRequest;
 import org.apache.http.protocol.HttpContext;
 
-
-
 /**
  * Encapsulates logic to compute a {@link HttpRoute} to a target host.
  * Implementations may for example be based on parameters, or on the
@@ -64,8 +62,6 @@
      */        
     public HttpRoute determineRoute(HttpHost target,
                                     HttpRequest request,
-                                    HttpContext context)
-        throws HttpException
-        ;
+                                    HttpContext context) throws HttpException;
     
 }

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/RouteInfo.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/RouteInfo.java?rev=764588&r1=764587&r2=764588&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/RouteInfo.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/RouteInfo.java
Mon Apr 13 19:53:25 2009
@@ -35,22 +35,16 @@
 
 import org.apache.http.HttpHost;
 
-
 /**
  * Read-only interface for route information.
  * 
- *
- *
- * <!-- empty lines to avoid svn diff problems -->
- * @version $Revision$
- *
  * @since 4.0
  */
 public interface RouteInfo {
 
     /**
      * The tunnelling type of a route.
-     * Plain routes are established by connecting to the target or
+     * Plain routes are established by   connecting to the target or
      * the first proxy.
      * Tunnelled routes are established by connecting to the first proxy
      * and tunnelling through all proxies to the target.
@@ -73,16 +67,12 @@
      */
     public enum LayerType  { PLAIN, LAYERED }
 
-
-
     /**
      * Obtains the target host.
      * 
      * @return the target host
      */
-    HttpHost getTargetHost()
-        ;
-
+    HttpHost getTargetHost();
 
     /**
      * Obtains the local address to connect from.
@@ -90,9 +80,7 @@
      * @return  the local address,
      *          or <code>null</code>
      */
-    InetAddress getLocalAddress()
-        ;
-
+    InetAddress getLocalAddress();
 
     /**
      * Obtains the number of hops in this route.
@@ -101,9 +89,7 @@
      *
      * @return  the number of hops in this route
      */
-    int getHopCount()
-        ;
-
+    int getHopCount();
 
     /**
      * Obtains the target of a hop in this route.
@@ -121,9 +107,7 @@
      *  if the argument is negative or not less than
      *  {@link #getHopCount getHopCount()}
      */
-    HttpHost getHopTarget(int hop)
-        ;
-
+    HttpHost getHopTarget(int hop);
 
     /**
      * Obtains the first proxy host.
@@ -131,9 +115,7 @@
      * @return the first proxy in the proxy chain, or
      *         <code>null</code> if this route is direct
      */
-    HttpHost getProxyHost()
-        ;
-
+    HttpHost getProxyHost();
 
     /**
      * Obtains the tunnel type of this route.
@@ -141,9 +123,7 @@
      *
      * @return  the tunnelling type
      */
-    TunnelType getTunnelType()
-        ;
-
+    TunnelType getTunnelType();
 
     /**
      * Checks whether this route is tunnelled through a proxy.
@@ -153,9 +133,7 @@
      *          one proxy,
      *          <code>false</code> otherwise
      */
-    boolean isTunnelled()
-        ;
-
+    boolean isTunnelled();
 
     /**
      * Obtains the layering type of this route.
@@ -164,9 +142,7 @@
      *
      * @return  the layering type
      */
-    LayerType getLayerType()
-        ;
-
+    LayerType getLayerType();
 
     /**
      * Checks whether this route includes a layered protocol.
@@ -176,9 +152,7 @@
      * @return  <code>true</code> if layered,
      *          <code>false</code> otherwise
      */
-    boolean isLayered()
-        ;
-
+    boolean isLayered();
 
     /**
      * Checks whether this route is secure.
@@ -186,8 +160,6 @@
      * @return  <code>true</code> if secure,
      *          <code>false</code> otherwise
      */
-    boolean isSecure()
-        ;
-
+    boolean isSecure();
 
-} // interface RouteInfo
+}

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/RouteTracker.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/RouteTracker.java?rev=764588&r1=764587&r2=764588&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/RouteTracker.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/conn/routing/RouteTracker.java
Mon Apr 13 19:53:25 2009
@@ -37,15 +37,9 @@
 
 import org.apache.http.HttpHost;
 
-
 /**
  * Helps tracking the steps in establishing a route.
  * 
- *
- *
- * <!-- empty lines to avoid svn diff problems -->
- * @version $Revision$
- *
  * @since 4.0
  */
 @NotThreadSafe
@@ -78,7 +72,6 @@
     /** Whether the route is secure. */
     private boolean secure;
 
-
     /**
      * Creates a new route tracker.
      * The target and origin need to be specified at creation time.
@@ -109,7 +102,6 @@
         this(route.getTargetHost(), route.getLocalAddress());
     }
 
-
     /**
      * Tracks connecting to the target.
      *
@@ -124,7 +116,6 @@
         this.secure = secure;
     }
 
-
     /**
      * Tracks connecting to the first proxy.
      *
@@ -144,7 +135,6 @@
         this.secure     = secure;
     }
 
-
     /**
      * Tracks tunnelling to the target.
      *
@@ -162,7 +152,6 @@
         this.secure    = secure;
     }
 
-
     /**
      * Tracks tunnelling to a proxy in a proxy chain.
      * This will extend the tracked proxy chain, but it does not mark
@@ -193,7 +182,6 @@
         this.secure     = secure;
     }
 
-
     /**
      * Tracks layering a protocol.
      *
@@ -211,21 +199,14 @@
         this.secure  = secure;
     }
 
-
-
-    // non-JavaDoc, see interface RouteInfo
     public final HttpHost getTargetHost() {
         return this.targetHost;
     }
 
-
-    // non-JavaDoc, see interface RouteInfo
     public final InetAddress getLocalAddress() {
         return this.localAddress;
     }
 
-
-    // non-JavaDoc, see interface RouteInfo
     public final int getHopCount() {
         int hops = 0;
         if (this.connected) {
@@ -237,8 +218,6 @@
         return hops;
     }
 
-
-    // non-JavaDoc, see interface RouteInfo
     public final HttpHost getHopTarget(int hop) {
         if (hop < 0)
             throw new IllegalArgumentException
@@ -259,49 +238,34 @@
         return result;
     }
 
-
-    // non-JavaDoc, see interface RouteInfo
     public final HttpHost getProxyHost() {
         return (this.proxyChain == null) ? null : this.proxyChain[0];
     }
 
-
-    // non-JavaDoc, see interface RouteInfo
     public final boolean isConnected() {
         return this.connected;
     }
 
-
-    // non-JavaDoc, see interface RouteInfo
     public final TunnelType getTunnelType() {
         return this.tunnelled;
     }
 
-
-    // non-JavaDoc, see interface RouteInfo
     public final boolean isTunnelled() {
         return (this.tunnelled == TunnelType.TUNNELLED);
     }
 
-
-    // non-JavaDoc, see interface RouteInfo
     public final LayerType getLayerType() {
         return this.layered;
     }
 
-
-    // non-JavaDoc, see interface RouteInfo
     public final boolean isLayered() {
         return (this.layered == LayerType.LAYERED);
     }
 
-
-    // non-JavaDoc, see interface RouteInfo
     public final boolean isSecure() {
         return this.secure;
     }
 
-
     /**
      * Obtains the tracked route.
      * If a route has been tracked, it is {@link #isConnected connected}.
@@ -317,7 +281,6 @@
                                  this.tunnelled, this.layered);
     }
 
-
     /**
      * Compares this tracked route to another.
      *
@@ -360,7 +323,6 @@
         return equal;
     }
 
-
     /**
      * Generates a hash code for this tracked route.
      * Route trackers are modifiable and should therefore not be used
@@ -393,7 +355,6 @@
         return hc;
     }
 
-
     /**
      * Obtains a description of the tracked route.
      *
@@ -437,5 +398,4 @@
         return super.clone();
     }
 
-
-} // class RouteTracker
+}

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java?rev=764588&r1=764587&r2=764588&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java
Mon Apr 13 19:53:25 2009
@@ -599,15 +599,6 @@
     protected void establishRoute(HttpRoute route, HttpContext context)
         throws HttpException, IOException {
 
-        //@@@ how to handle CONNECT requests for tunnelling?
-        //@@@ refuse to send external CONNECT via director? special handling?
-
-        //@@@ should the request parameters already be used below?
-        //@@@ probably yes, but they're not linked yet
-        //@@@ will linking above cause problems with linking in reqExec?
-        //@@@ probably not, because the parent is replaced
-        //@@@ just make sure we don't link parameters to themselves
-
         HttpRouteDirector rowdy = new BasicRouteDirector();
         int step;
         do {

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/AbstractPoolEntry.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/AbstractPoolEntry.java?rev=764588&r1=764587&r2=764588&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/AbstractPoolEntry.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/AbstractPoolEntry.java
Mon Apr 13 19:53:25 2009
@@ -139,7 +139,6 @@
             throw new IllegalArgumentException
                 ("Route must not be null.");
         }
-        //@@@ is context allowed to be null? depends on operator?
         if (params == null) {
             throw new IllegalArgumentException
                 ("Parameters must not be null.");
@@ -154,8 +153,6 @@
         // In this order, we can be sure that only a successful
         // opening of the connection will be tracked.
 
-        //@@@ verify route against planned route?
-
         this.tracker = new RouteTracker(route);
         final HttpHost proxy  = route.getProxyHost();
 
@@ -201,7 +198,6 @@
                 ("Parameters must not be null.");
         }
 
-        //@@@ check for proxy in planned route?
         if ((this.tracker == null) || !this.tracker.isConnected()) {
             throw new IllegalStateException("Connection not open.");
         }
@@ -210,8 +206,6 @@
                 ("Connection is already tunnelled.");
         }
 
-        // LOG.debug?
-
         this.connection.update(null, tracker.getTargetHost(),
                                secure, params);
         this.tracker.tunnelTarget(secure);



Mime
View raw message