|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.http.impl.AbstractHttpServerConnection
org.apache.http.impl.SocketHttpServerConnection
public class SocketHttpServerConnection
Implementation of a server-side HTTP connection that can be bound to a network Socket in order to receive and transmit data.
| Constructor Summary | |
|---|---|
SocketHttpServerConnection()
|
|
| Method Summary | |
|---|---|
protected void |
assertNotOpen()
|
protected void |
assertOpen()
|
protected void |
bind(java.net.Socket socket,
HttpParams params)
|
void |
close()
Closes this connection gracefully. |
protected SessionInputBuffer |
createHttpDataReceiver(java.net.Socket socket,
int buffersize,
HttpParams params)
|
protected SessionOutputBuffer |
createHttpDataTransmitter(java.net.Socket socket,
int buffersize,
HttpParams params)
|
java.net.InetAddress |
getLocalAddress()
|
int |
getLocalPort()
|
java.net.InetAddress |
getRemoteAddress()
|
int |
getRemotePort()
|
protected java.net.Socket |
getSocket()
|
int |
getSocketTimeout()
Returns the socket timeout value. |
boolean |
isOpen()
Checks if this connection is open. |
void |
setSocketTimeout(int timeout)
Sets the socket timeout value. |
void |
shutdown()
Force-closes this connection. |
| Methods inherited from class org.apache.http.impl.AbstractHttpServerConnection |
|---|
createEntityDeserializer, createEntitySerializer, createHttpRequestFactory, createRequestParser, createResponseWriter, doFlush, flush, getMetrics, init, isStale, receiveRequestEntity, receiveRequestHeader, sendResponseEntity, sendResponseHeader |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.apache.http.HttpConnection |
|---|
getMetrics, isStale |
| Constructor Detail |
|---|
public SocketHttpServerConnection()
| Method Detail |
|---|
protected void assertNotOpen()
protected void assertOpen()
assertOpen in class AbstractHttpServerConnection
protected SessionInputBuffer createHttpDataReceiver(java.net.Socket socket,
int buffersize,
HttpParams params)
throws java.io.IOException
java.io.IOException
protected SessionOutputBuffer createHttpDataTransmitter(java.net.Socket socket,
int buffersize,
HttpParams params)
throws java.io.IOException
java.io.IOException
protected void bind(java.net.Socket socket,
HttpParams params)
throws java.io.IOException
java.io.IOExceptionprotected java.net.Socket getSocket()
public boolean isOpen()
HttpConnection
isOpen in interface HttpConnectionpublic java.net.InetAddress getLocalAddress()
getLocalAddress in interface HttpInetConnectionpublic int getLocalPort()
getLocalPort in interface HttpInetConnectionpublic java.net.InetAddress getRemoteAddress()
getRemoteAddress in interface HttpInetConnectionpublic int getRemotePort()
getRemotePort in interface HttpInetConnectionpublic void setSocketTimeout(int timeout)
HttpConnection
setSocketTimeout in interface HttpConnectiontimeout - timeout value in millisecondspublic int getSocketTimeout()
HttpConnection
getSocketTimeout in interface HttpConnection0 if timeout is disabled or -1 if
timeout is undefined.
public void shutdown()
throws java.io.IOException
HttpConnection
shutdown in interface HttpConnectionjava.io.IOException
public void close()
throws java.io.IOException
HttpConnectionshutdown instead.
close in interface HttpConnectionjava.io.IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||