FileDocCategorySizeDatePackage
DefaultHttpClientConnection.javaAPI DocAndroid 1.5 API2984Wed May 06 22:41:10 BST 2009org.apache.http.impl

DefaultHttpClientConnection

public class DefaultHttpClientConnection extends SocketHttpClientConnection
Default implementation of a client-side HTTP connection.
author
Oleg Kalnichevski
version
$Revision: 561083 $
since
4.0

Fields Summary
Constructors Summary
public DefaultHttpClientConnection()

        super();
    
Methods Summary
public voidbind(java.net.Socket socket, org.apache.http.params.HttpParams params)

        if (socket == null) {
            throw new IllegalArgumentException("Socket may not be null");
        }
        if (params == null) {
            throw new IllegalArgumentException("HTTP parameters may not be null");
        }
        assertNotOpen();
        socket.setTcpNoDelay(HttpConnectionParams.getTcpNoDelay(params));
        socket.setSoTimeout(HttpConnectionParams.getSoTimeout(params));
        
        int linger = HttpConnectionParams.getLinger(params);
        if (linger >= 0) {
            socket.setSoLinger(linger > 0, linger);
        }
        super.bind(socket, params);
    
public java.lang.StringtoString()

        StringBuffer buffer = new StringBuffer();
        buffer.append("[");
        if (isOpen()) {
            buffer.append(getRemotePort());
        } else {
            buffer.append("closed");
        }
        buffer.append("]");
        return buffer.toString();