Example usage for Java org.apache.commons.httpclient HttpConnection fields, constructors, methods, implement or subclass
The text is from its open source code.
boolean | isOpen Whether or not the connection is connected. |
HttpConnection(HostConfiguration hostConfiguration) Creates a new HTTP connection for the given host configuration. | |
HttpConnection(String host, int port) Creates a new HTTP connection for the given host and port. | |
HttpConnection(String host, String virtualHost, int port, Protocol protocol) Creates a new HTTP connection for the given host with the virtual alias and port using given protocol. | |
HttpConnection(String proxyHost, int proxyPort, String host, int port) Creates a new HTTP connection for the given host and port via the given proxy host and port using the default protocol. | |
HttpConnection(String proxyHost, int proxyPort, String host, String virtualHost, int port, Protocol protocol) Creates a new HTTP connection for the given host with the virtual alias and port via the given proxy host and port using the given protocol. | |
HttpConnection(String host, int port, Protocol protocol) Creates a new HTTP connection for the given host and port using the given protocol. |
void | close() Closes the socket and streams. |
void | flushRequestOutputStream() Flushes the output request stream. |
String | getHost() Returns the host. |
InputStream | getLastResponseInputStream() Returns the stream used to read the last response's body. |
InetAddress | getLocalAddress() Return the local address used when creating the connection. |
HttpConnectionParams | getParams() Returns HttpConnectionParams HTTP protocol parameters associated with this method. |
int | getPort() Returns the port of the host. |
Protocol | getProtocol() Returns the protocol used to establish the connection. |
String | getProxyHost() Returns the proxy host. |
int | getProxyPort() Returns the port of the proxy host. |
OutputStream | getRequestOutputStream() Returns an OutputStream suitable for writing the request. |
InputStream | getResponseInputStream() Return a InputStream suitable for reading the response. |
boolean | isTransparent() Indicates if the connection is completely transparent from end to end. |
void | open() Establishes a connection to the specified host and port (via a proxy if specified). |
void | releaseConnection() Releases the connection. |
void | setConnectionTimeout(int timeout) Sets the connection timeout. |
void | setHost(String host) Sets the host to connect to. |
void | setHttpConnectionManager(HttpConnectionManager httpConnectionManager) Sets the httpConnectionManager. |
void | setLastResponseInputStream(InputStream inStream) Set the state to keep track of the last response for the last request. |
void | setLocalAddress(InetAddress localAddress) Set the local address used when creating the connection. |
void | setParams(final HttpConnectionParams params) Assigns HttpConnectionParams HTTP protocol parameters for this method. |
void | setPort(int port) Sets the port to connect to. |
void | setProtocol(Protocol protocol) Sets the protocol used to establish the connection |
void | setProxyHost(String host) Sets the host to proxy through. |
void | setProxyPort(int port) Sets the port of the host to proxy through. |
void | setSocketTimeout(int timeout) Sets SO_TIMEOUT value directly on the underlying Socket socket . |
void | setSoTimeout(int timeout) Set the Socket 's timeout, via Socket#setSoTimeout . |
void | write(byte[] data) Writes the specified bytes to the output stream. |
void | writeLine() Writes "\r\n".getBytes() to the output stream. |