Class SocketHttpClientConnection

    • Field Detail

      • open

        private volatile boolean open
        Deprecated.
      • socket

        private volatile java.net.Socket socket
        Deprecated.
    • Constructor Detail

      • SocketHttpClientConnection

        public SocketHttpClientConnection()
        Deprecated.
    • Method Detail

      • assertNotOpen

        protected void assertNotOpen()
        Deprecated.
      • createSessionInputBuffer

        protected SessionInputBuffer createSessionInputBuffer​(java.net.Socket socket,
                                                              int bufferSize,
                                                              HttpParams params)
                                                       throws java.io.IOException
        Deprecated.
        Creates an instance of SocketInputBuffer to be used for receiving data from the given Socket.

        This method can be overridden in a super class in order to provide a custom implementation of SessionInputBuffer interface.

        Parameters:
        socket - the socket.
        bufferSize - the buffer size.
        params - HTTP parameters.
        Returns:
        session input buffer.
        Throws:
        java.io.IOException - in case of an I/O error.
        See Also:
        SocketInputBuffer(Socket, int, HttpParams)
      • createSessionOutputBuffer

        protected SessionOutputBuffer createSessionOutputBuffer​(java.net.Socket socket,
                                                                int bufferSize,
                                                                HttpParams params)
                                                         throws java.io.IOException
        Deprecated.
        Creates an instance of SessionOutputBuffer to be used for sending data to the given Socket.

        This method can be overridden in a super class in order to provide a custom implementation of SocketOutputBuffer interface.

        Parameters:
        socket - the socket.
        bufferSize - the buffer size.
        params - HTTP parameters.
        Returns:
        session output buffer.
        Throws:
        java.io.IOException - in case of an I/O error.
        See Also:
        SocketOutputBuffer(Socket, int, HttpParams)
      • isOpen

        public boolean isOpen()
        Deprecated.
        Description copied from interface: HttpConnection
        Checks if this connection is open.
        Specified by:
        isOpen in interface HttpConnection
        Returns:
        true if it is open, false if it is closed.
      • getSocket

        protected java.net.Socket getSocket()
        Deprecated.
      • setSocketTimeout

        public void setSocketTimeout​(int timeout)
        Deprecated.
        Description copied from interface: HttpConnection
        Sets the socket timeout value.
        Specified by:
        setSocketTimeout in interface HttpConnection
        Parameters:
        timeout - timeout value in milliseconds
      • getSocketTimeout

        public int getSocketTimeout()
        Deprecated.
        Description copied from interface: HttpConnection
        Returns the socket timeout value.
        Specified by:
        getSocketTimeout in interface HttpConnection
        Returns:
        positive value in milliseconds if a timeout is set, 0 if timeout is disabled or -1 if timeout is undefined.
      • shutdown

        public void shutdown()
                      throws java.io.IOException
        Deprecated.
        Description copied from interface: HttpConnection
        Force-closes this connection. This is the only method of a connection which may be called from a different thread to terminate the connection. This method will not attempt to flush the transmitter's internal buffer prior to closing the underlying socket.
        Specified by:
        shutdown in interface HttpConnection
        Throws:
        java.io.IOException
      • close

        public void close()
                   throws java.io.IOException
        Deprecated.
        Description copied from interface: HttpConnection
        Closes this connection gracefully. This method will attempt to flush the internal output buffer prior to closing the underlying socket. This method MUST NOT be called from a different thread to force shutdown of the connection. Use shutdown instead.
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface java.io.Closeable
        Specified by:
        close in interface HttpConnection
        Throws:
        java.io.IOException
      • formatAddress

        private static void formatAddress​(java.lang.StringBuilder buffer,
                                          java.net.SocketAddress socketAddress)
        Deprecated.
      • toString

        public java.lang.String toString()
        Deprecated.
        Overrides:
        toString in class java.lang.Object