@Deprecated public class MockHttpClientConnection extends Object implements org.apache.http.HttpClientConnection
HttpClientConnection
specifically for use in mocked connections using the MockHttpConnection
class.
Constructor and Description |
---|
MockHttpClientConnection(MockHttpConnection c)
Deprecated.
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Deprecated.
|
void |
flush()
Deprecated.
|
org.apache.http.HttpConnectionMetrics |
getMetrics()
Deprecated.
|
int |
getSocketTimeout()
Deprecated.
|
boolean |
isOpen()
Deprecated.
|
boolean |
isResponseAvailable(int timeout)
Deprecated.
|
boolean |
isStale()
Deprecated.
|
void |
receiveResponseEntity(org.apache.http.HttpResponse response)
Deprecated.
|
org.apache.http.HttpResponse |
receiveResponseHeader()
Deprecated.
|
void |
sendRequestEntity(org.apache.http.HttpEntityEnclosingRequest request)
Deprecated.
|
void |
sendRequestHeader(org.apache.http.HttpRequest request)
Deprecated.
|
void |
setSocketTimeout(int timeout)
Deprecated.
|
void |
shutdown()
Deprecated.
|
public MockHttpClientConnection(MockHttpConnection c)
c
- The API for performing the connections.public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in interface org.apache.http.HttpConnection
IOException
public boolean isOpen()
isOpen
in interface org.apache.http.HttpConnection
public boolean isStale()
isStale
in interface org.apache.http.HttpConnection
public void setSocketTimeout(int timeout)
setSocketTimeout
in interface org.apache.http.HttpConnection
public int getSocketTimeout()
getSocketTimeout
in interface org.apache.http.HttpConnection
public void shutdown() throws IOException
shutdown
in interface org.apache.http.HttpConnection
IOException
public org.apache.http.HttpConnectionMetrics getMetrics()
getMetrics
in interface org.apache.http.HttpConnection
public boolean isResponseAvailable(int timeout) throws IOException
isResponseAvailable
in interface org.apache.http.HttpClientConnection
IOException
public void sendRequestHeader(org.apache.http.HttpRequest request) throws org.apache.http.HttpException, IOException
sendRequestHeader
in interface org.apache.http.HttpClientConnection
org.apache.http.HttpException
IOException
public void sendRequestEntity(org.apache.http.HttpEntityEnclosingRequest request) throws org.apache.http.HttpException, IOException
sendRequestEntity
in interface org.apache.http.HttpClientConnection
org.apache.http.HttpException
IOException
public org.apache.http.HttpResponse receiveResponseHeader() throws org.apache.http.HttpException, IOException
receiveResponseHeader
in interface org.apache.http.HttpClientConnection
org.apache.http.HttpException
IOException
public void receiveResponseEntity(org.apache.http.HttpResponse response) throws org.apache.http.HttpException, IOException
receiveResponseEntity
in interface org.apache.http.HttpClientConnection
org.apache.http.HttpException
IOException
public void flush() throws IOException
flush
in interface org.apache.http.HttpClientConnection
IOException
Copyright © 2016–2020 The Apache Software Foundation. All rights reserved.