org.apache.jmeter.protocol.http.sampler.hc

## Class ManagedClientConnectionImpl

- java.lang.Object
- - org.apache.jmeter.protocol.http.sampler.hc.ManagedClientConnectionImpl

- All Implemented Interfaces:
    Closeable, AutoCloseable, org.apache.http.conn.ConnectionReleaseTrigger, org.apache.http.conn.HttpRoutedConnection, org.apache.http.conn.ManagedClientConnection, org.apache.http.conn.ManagedHttpClientConnection, org.apache.http.HttpClientConnection, org.apache.http.HttpConnection, org.apache.http.HttpInetConnection

      public class ManagedClientConnectionImpl
      extends Object
      implements org.apache.http.conn.ManagedClientConnection

  Implementation of `ManagedClientConnection`
  Since:
    3.2

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ManagedClientConnectionImpl(org.apache.http.conn.ClientConnectionManager manager, org.apache.http.conn.ClientConnectionOperator operator, HttpPoolEntry entry)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `abortConnection()`
    `void` | `bind(Socket socket)`
    `void` | `close()`
    `HttpPoolEntry` | `detach()`
    `void` | `flush()`
    `Object` | `getAttribute(String id)`
    `String` | `getId()`
    `InetAddress` | `getLocalAddress()`
    `int` | `getLocalPort()`
    `org.apache.http.conn.ClientConnectionManager` | `getManager()`
    `org.apache.http.HttpConnectionMetrics` | `getMetrics()`
    `InetAddress` | `getRemoteAddress()`
    `int` | `getRemotePort()`
    `org.apache.http.conn.routing.HttpRoute` | `getRoute()`
    `Socket` | `getSocket()`
    `int` | `getSocketTimeout()`
    `SSLSession` | `getSSLSession()`
    `Object` | `getState()`
    `boolean` | `isMarkedReusable()`
    `boolean` | `isOpen()`
    `boolean` | `isResponseAvailable(int timeout)`
    `boolean` | `isSecure()`
    `boolean` | `isStale()`
    `void` | `layerProtocol(org.apache.http.protocol.HttpContext context, org.apache.http.params.HttpParams params)`
    `void` | `markReusable()`
    `void` | `open(org.apache.http.conn.routing.HttpRoute route, org.apache.http.protocol.HttpContext context, org.apache.http.params.HttpParams params)`
    `void` | `receiveResponseEntity(org.apache.http.HttpResponse response)`
    `org.apache.http.HttpResponse` | `receiveResponseHeader()`
    `void` | `releaseConnection()`
    `Object` | `removeAttribute(String id)`
    `void` | `sendRequestEntity(org.apache.http.HttpEntityEnclosingRequest request)`
    `void` | `sendRequestHeader(org.apache.http.HttpRequest request)`
    `void` | `setAttribute(String id, Object obj)`
    `void` | `setIdleDuration(long duration, TimeUnit unit)`
    `void` | `setSocketTimeout(int timeout)`
    `void` | `setState(Object state)`
    `void` | `shutdown()`
    `void` | `tunnelProxy(org.apache.http.HttpHost next, boolean secure, org.apache.http.params.HttpParams params)`
    `void` | `tunnelTarget(boolean secure, org.apache.http.params.HttpParams params)`
    `void` | `unmarkReusable()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ManagedClientConnectionImpl

          public ManagedClientConnectionImpl(org.apache.http.conn.ClientConnectionManager manager,
                                             org.apache.http.conn.ClientConnectionOperator operator,
                                             HttpPoolEntry entry)

  - ### Method Detail

    - #### getId

          public String getId()

      Specified by:
        `getId` in interface `org.apache.http.conn.ManagedHttpClientConnection`

    - #### detach

          public HttpPoolEntry detach()

    - #### getManager

          public org.apache.http.conn.ClientConnectionManager getManager()

    - #### close

          public void close()
                     throws IOException

      Specified by:
        `close` in interface `Closeable`
      Specified by:
        `close` in interface `AutoCloseable`
      Specified by:
        `close` in interface `org.apache.http.HttpConnection`
      Throws:
        `IOException`

    - #### shutdown

          public void shutdown()
                        throws IOException

      Specified by:
        `shutdown` in interface `org.apache.http.HttpConnection`
      Throws:
        `IOException`

    - #### isOpen

          public boolean isOpen()

      Specified by:
        `isOpen` in interface `org.apache.http.HttpConnection`

    - #### isStale

          public boolean isStale()

      Specified by:
        `isStale` in interface `org.apache.http.HttpConnection`

    - #### setSocketTimeout

          public void setSocketTimeout(int timeout)

      Specified by:
        `setSocketTimeout` in interface `org.apache.http.HttpConnection`

    - #### getSocketTimeout

          public int getSocketTimeout()

      Specified by:
        `getSocketTimeout` in interface `org.apache.http.HttpConnection`

    - #### getMetrics

          public org.apache.http.HttpConnectionMetrics getMetrics()

      Specified by:
        `getMetrics` in interface `org.apache.http.HttpConnection`

    - #### flush

          public void flush()
                     throws IOException

      Specified by:
        `flush` in interface `org.apache.http.HttpClientConnection`
      Throws:
        `IOException`

    - #### isResponseAvailable

          public boolean isResponseAvailable(int timeout)
                                      throws IOException

      Specified by:
        `isResponseAvailable` in interface `org.apache.http.HttpClientConnection`
      Throws:
        `IOException`

    - #### receiveResponseEntity

          public void receiveResponseEntity(org.apache.http.HttpResponse response)
                                     throws org.apache.http.HttpException,
                                            IOException

      Specified by:
        `receiveResponseEntity` in interface `org.apache.http.HttpClientConnection`
      Throws:
        `org.apache.http.HttpException`
        `IOException`

    - #### receiveResponseHeader

          public org.apache.http.HttpResponse receiveResponseHeader()
                                                             throws org.apache.http.HttpException,
                                                                    IOException

      Specified by:
        `receiveResponseHeader` in interface `org.apache.http.HttpClientConnection`
      Throws:
        `org.apache.http.HttpException`
        `IOException`

    - #### sendRequestEntity

          public void sendRequestEntity(org.apache.http.HttpEntityEnclosingRequest request)
                                 throws org.apache.http.HttpException,
                                        IOException

      Specified by:
        `sendRequestEntity` in interface `org.apache.http.HttpClientConnection`
      Throws:
        `org.apache.http.HttpException`
        `IOException`

    - #### sendRequestHeader

          public void sendRequestHeader(org.apache.http.HttpRequest request)
                                 throws org.apache.http.HttpException,
                                        IOException

      Specified by:
        `sendRequestHeader` in interface `org.apache.http.HttpClientConnection`
      Throws:
        `org.apache.http.HttpException`
        `IOException`

    - #### getLocalAddress

          public InetAddress getLocalAddress()

      Specified by:
        `getLocalAddress` in interface `org.apache.http.HttpInetConnection`

    - #### getLocalPort

          public int getLocalPort()

      Specified by:
        `getLocalPort` in interface `org.apache.http.HttpInetConnection`

    - #### getRemoteAddress

          public InetAddress getRemoteAddress()

      Specified by:
        `getRemoteAddress` in interface `org.apache.http.HttpInetConnection`

    - #### getRemotePort

          public int getRemotePort()

      Specified by:
        `getRemotePort` in interface `org.apache.http.HttpInetConnection`

    - #### isSecure

          public boolean isSecure()

      Specified by:
        `isSecure` in interface `org.apache.http.conn.HttpRoutedConnection`
      Specified by:
        `isSecure` in interface `org.apache.http.conn.ManagedClientConnection`

    - #### bind

          public void bind(Socket socket)
                    throws IOException

      Specified by:
        `bind` in interface `org.apache.http.conn.ManagedHttpClientConnection`
      Throws:
        `IOException`

    - #### getSocket

          public Socket getSocket()

      Specified by:
        `getSocket` in interface `org.apache.http.conn.ManagedHttpClientConnection`

    - #### getSSLSession

          public SSLSession getSSLSession()

      Specified by:
        `getSSLSession` in interface `org.apache.http.conn.HttpRoutedConnection`
      Specified by:
        `getSSLSession` in interface `org.apache.http.conn.ManagedClientConnection`
      Specified by:
        `getSSLSession` in interface `org.apache.http.conn.ManagedHttpClientConnection`

    - #### getAttribute

          public Object getAttribute(String id)

    - #### removeAttribute

          public Object removeAttribute(String id)

    - #### setAttribute

          public void setAttribute(String id,
                                   Object obj)

    - #### getRoute

          public org.apache.http.conn.routing.HttpRoute getRoute()

      Specified by:
        `getRoute` in interface `org.apache.http.conn.HttpRoutedConnection`
      Specified by:
        `getRoute` in interface `org.apache.http.conn.ManagedClientConnection`

    - #### open

          public void open(org.apache.http.conn.routing.HttpRoute route,
                           org.apache.http.protocol.HttpContext context,
                           org.apache.http.params.HttpParams params)
                    throws IOException

      Specified by:
        `open` in interface `org.apache.http.conn.ManagedClientConnection`
      Throws:
        `IOException`

    - #### tunnelTarget

          public void tunnelTarget(boolean secure,
                                   org.apache.http.params.HttpParams params)
                            throws IOException

      Specified by:
        `tunnelTarget` in interface `org.apache.http.conn.ManagedClientConnection`
      Throws:
        `IOException`

    - #### tunnelProxy

          public void tunnelProxy(org.apache.http.HttpHost next,
                                  boolean secure,
                                  org.apache.http.params.HttpParams params)
                           throws IOException

      Specified by:
        `tunnelProxy` in interface `org.apache.http.conn.ManagedClientConnection`
      Throws:
        `IOException`

    - #### layerProtocol

          public void layerProtocol(org.apache.http.protocol.HttpContext context,
                                    org.apache.http.params.HttpParams params)
                             throws IOException

      Specified by:
        `layerProtocol` in interface `org.apache.http.conn.ManagedClientConnection`
      Throws:
        `IOException`

    - #### getState

          public Object getState()

      Specified by:
        `getState` in interface `org.apache.http.conn.ManagedClientConnection`

    - #### setState

          public void setState(Object state)

      Specified by:
        `setState` in interface `org.apache.http.conn.ManagedClientConnection`

    - #### markReusable

          public void markReusable()

      Specified by:
        `markReusable` in interface `org.apache.http.conn.ManagedClientConnection`

    - #### unmarkReusable

          public void unmarkReusable()

      Specified by:
        `unmarkReusable` in interface `org.apache.http.conn.ManagedClientConnection`

    - #### isMarkedReusable

          public boolean isMarkedReusable()

      Specified by:
        `isMarkedReusable` in interface `org.apache.http.conn.ManagedClientConnection`

    - #### setIdleDuration

          public void setIdleDuration(long duration,
                                      TimeUnit unit)

      Specified by:
        `setIdleDuration` in interface `org.apache.http.conn.ManagedClientConnection`

    - #### releaseConnection

          public void releaseConnection()

      Specified by:
        `releaseConnection` in interface `org.apache.http.conn.ConnectionReleaseTrigger`

    - #### abortConnection

          public void abortConnection()

      Specified by:
        `abortConnection` in interface `org.apache.http.conn.ConnectionReleaseTrigger`

Copyright © 1998-2017 Apache Software Foundation. All Rights Reserved.