/// <exception cref="System.IO.IOException"></exception>
        public virtual void Connect(HttpClientConnection conn, HttpRoute route, int connectTimeout
                                    , HttpContext context)
        {
            Args.NotNull(conn, "Connection");
            Args.NotNull(route, "HTTP route");
            Asserts.Check(conn == this.conn, "Connection not obtained from this manager");
            HttpHost host;

            if (route.GetProxyHost() != null)
            {
                host = route.GetProxyHost();
            }
            else
            {
                host = route.GetTargetHost();
            }
            IPEndPoint localAddress = route.GetLocalSocketAddress();

            this.connectionOperator.Connect(this.conn, host, localAddress, connectTimeout, this
                                            .socketConfig, context);
        }