|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.http.impl.nio.NHttpConnectionBase
public class NHttpConnectionBase
| Field Summary | |
|---|---|
protected org.apache.http.impl.HttpConnectionMetricsImpl |
connMetrics
|
protected ContentDecoder |
contentDecoder
|
protected ContentEncoder |
contentEncoder
|
protected org.apache.http.protocol.HttpContext |
context
|
protected boolean |
hasBufferedInput
|
protected boolean |
hasBufferedOutput
|
protected SessionInputBufferImpl |
inbuf
|
protected org.apache.http.entity.ContentLengthStrategy |
incomingContentStrategy
|
protected org.apache.http.impl.io.HttpTransportMetricsImpl |
inTransportMetrics
|
protected SessionOutputBufferImpl |
outbuf
|
protected org.apache.http.entity.ContentLengthStrategy |
outgoingContentStrategy
|
protected org.apache.http.impl.io.HttpTransportMetricsImpl |
outTransportMetrics
|
protected org.apache.http.HttpRequest |
request
|
protected org.apache.http.HttpResponse |
response
|
protected IOSession |
session
|
protected int |
status
|
| Fields inherited from interface org.apache.http.nio.NHttpConnection |
|---|
ACTIVE, CLOSED, CLOSING |
| Constructor Summary | |
|---|---|
NHttpConnectionBase(IOSession session,
ByteBufferAllocator allocator,
org.apache.http.params.HttpParams params)
|
|
| Method Summary | |
|---|---|
protected void |
assertNotClosed()
|
void |
close()
|
org.apache.http.protocol.HttpContext |
getContext()
Returns an HTTP execution context associated with this connection. |
org.apache.http.HttpRequest |
getHttpRequest()
Returns the current HTTP request if one is being received / transmitted. |
org.apache.http.HttpResponse |
getHttpResponse()
Returns the current HTTP response if one is being received / transmitted. |
java.net.InetAddress |
getLocalAddress()
|
int |
getLocalPort()
|
org.apache.http.HttpConnectionMetrics |
getMetrics()
|
java.net.InetAddress |
getRemoteAddress()
|
int |
getRemotePort()
|
int |
getSocketTimeout()
|
int |
getStatus()
|
boolean |
hasBufferedInput()
|
boolean |
hasBufferedOutput()
|
boolean |
isOpen()
|
boolean |
isStale()
|
protected org.apache.http.HttpEntity |
prepareDecoder(org.apache.http.HttpMessage message)
|
protected void |
prepareEncoder(org.apache.http.HttpMessage message)
|
void |
requestInput()
Requests event notifications to be triggered when the underlying channel is ready for input oprtations. |
void |
requestOutput()
Requests event notifications to be triggered when the underlying channel is ready for output oprtations. |
void |
setSocketTimeout(int timeout)
|
void |
shutdown()
Shuts down the underlying channel. |
void |
suspendInput()
Suspends event notifications about the underlying channel being ready for input operations. |
void |
suspendOutput()
Suspends event notifications about the underlying channel being ready for output operations. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final org.apache.http.protocol.HttpContext context
protected final org.apache.http.entity.ContentLengthStrategy incomingContentStrategy
protected final org.apache.http.entity.ContentLengthStrategy outgoingContentStrategy
protected final SessionInputBufferImpl inbuf
protected final SessionOutputBufferImpl outbuf
protected final org.apache.http.impl.io.HttpTransportMetricsImpl inTransportMetrics
protected final org.apache.http.impl.io.HttpTransportMetricsImpl outTransportMetrics
protected final org.apache.http.impl.HttpConnectionMetricsImpl connMetrics
protected IOSession session
protected volatile ContentDecoder contentDecoder
protected volatile boolean hasBufferedInput
protected volatile ContentEncoder contentEncoder
protected volatile boolean hasBufferedOutput
protected volatile org.apache.http.HttpRequest request
protected volatile org.apache.http.HttpResponse response
protected volatile int status
| Constructor Detail |
|---|
public NHttpConnectionBase(IOSession session,
ByteBufferAllocator allocator,
org.apache.http.params.HttpParams params)
| Method Detail |
|---|
public int getStatus()
getStatus in interface NHttpConnectionpublic org.apache.http.protocol.HttpContext getContext()
NHttpConnection
getContext in interface NHttpConnectionpublic org.apache.http.HttpRequest getHttpRequest()
NHttpConnection
getHttpRequest in interface NHttpConnectionpublic org.apache.http.HttpResponse getHttpResponse()
NHttpConnection
getHttpResponse in interface NHttpConnectionpublic void requestInput()
IOControl
requestInput in interface IOControlpublic void requestOutput()
IOControl
requestOutput in interface IOControlpublic void suspendInput()
IOControl
suspendInput in interface IOControlpublic void suspendOutput()
IOControl
suspendOutput in interface IOControl
protected org.apache.http.HttpEntity prepareDecoder(org.apache.http.HttpMessage message)
throws org.apache.http.HttpException
org.apache.http.HttpException
protected void prepareEncoder(org.apache.http.HttpMessage message)
throws org.apache.http.HttpException
org.apache.http.HttpExceptionpublic boolean hasBufferedInput()
hasBufferedInput in interface SessionBufferStatuspublic boolean hasBufferedOutput()
hasBufferedOutput in interface SessionBufferStatus
protected void assertNotClosed()
throws java.io.IOException
java.io.IOException
public void close()
throws java.io.IOException
close in interface org.apache.http.HttpConnectionjava.io.IOExceptionpublic boolean isOpen()
isOpen in interface org.apache.http.HttpConnectionpublic boolean isStale()
isStale in interface org.apache.http.HttpConnectionpublic java.net.InetAddress getLocalAddress()
getLocalAddress in interface org.apache.http.HttpInetConnectionpublic int getLocalPort()
getLocalPort in interface org.apache.http.HttpInetConnectionpublic java.net.InetAddress getRemoteAddress()
getRemoteAddress in interface org.apache.http.HttpInetConnectionpublic int getRemotePort()
getRemotePort in interface org.apache.http.HttpInetConnectionpublic void setSocketTimeout(int timeout)
setSocketTimeout in interface org.apache.http.HttpConnectionpublic int getSocketTimeout()
getSocketTimeout in interface org.apache.http.HttpConnection
public void shutdown()
throws java.io.IOException
IOControl
shutdown in interface org.apache.http.HttpConnectionshutdown in interface IOControljava.io.IOExceptionpublic org.apache.http.HttpConnectionMetrics getMetrics()
getMetrics in interface org.apache.http.HttpConnection
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||