From 0a93660d96d498b717cc3fc22771b2968ccbe0d5 Mon Sep 17 00:00:00 2001 From: Oleg Kalnichevski Date: Mon, 12 May 2014 11:12:48 +0000 Subject: [PATCH] Use a separate setter for shared connection manager flag git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1593923 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/http/impl/client/HttpClientBuilder.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/httpclient/src/main/java/org/apache/http/impl/client/HttpClientBuilder.java b/httpclient/src/main/java/org/apache/http/impl/client/HttpClientBuilder.java index 3722b4deb..aff837d74 100644 --- a/httpclient/src/main/java/org/apache/http/impl/client/HttpClientBuilder.java +++ b/httpclient/src/main/java/org/apache/http/impl/client/HttpClientBuilder.java @@ -334,25 +334,25 @@ public class HttpClientBuilder { */ public final HttpClientBuilder setConnectionManager( final HttpClientConnectionManager connManager) { - return setConnectionManager(connManager, false); + this.connManager = connManager; + return this; } /** - * Assigns {@link HttpClientConnectionManager} instance. + * Defines the connection manager is to be shared by multiple + * client instances. *

* If the connection manager is shared its life-cycle is expected * to be managed by the caller and it will not be shut down * if the client is closed. * - * @param connManager connection manager * @param shared defines whether or not the connection manager can be shared * by multiple clients. * * @since 4.4 */ - public final HttpClientBuilder setConnectionManager( - final HttpClientConnectionManager connManager, final boolean shared) { - this.connManager = connManager; + public final HttpClientBuilder setConnectionManagerShared( + final boolean shared) { this.connManagerShared = shared; return this; }