public class HttpClient extends SocketPool
| Modifier and Type | Field and Description |
|---|---|
protected int |
bufferSize |
protected java.lang.String[] |
permanentHeaders |
connectTimeout, host, port, proxy, readTimeout, sslContext, thinLto, tosclosed, createdCount, fifo, initialCount, keepEmpty, maxCount, timeout, timeouts, waitingThreads| Constructor and Description |
|---|
HttpClient(ConnectionString conn) |
HttpClient(ConnectionString conn,
java.lang.String... permanentHeaders) |
| Modifier and Type | Method and Description |
|---|---|
Response |
connect(java.lang.String uri,
java.lang.String... headers) |
Request |
createRequest(int method,
java.lang.String uri,
java.lang.String... headers) |
Response |
delete(java.lang.String uri,
java.lang.String... headers) |
Response |
get(java.lang.String uri,
java.lang.String... headers) |
Response |
head(java.lang.String uri,
java.lang.String... headers) |
Response |
invoke(Request request) |
Response |
invoke(Request request,
int timeout) |
EventSourceResponse |
openEvents(Request request,
int timeout) |
EventSourceResponse |
openEvents(java.lang.String uri,
java.lang.String... headers) |
Response |
options(java.lang.String uri,
java.lang.String... headers) |
Response |
patch(java.lang.String uri,
byte[] body,
java.lang.String... headers) |
Response |
patch(java.lang.String uri,
java.lang.String... headers) |
Response |
post(java.lang.String uri,
byte[] body,
java.lang.String... headers) |
Response |
post(java.lang.String uri,
java.lang.String... headers) |
Response |
put(java.lang.String uri,
byte[] body,
java.lang.String... headers) |
Response |
put(java.lang.String uri,
java.lang.String... headers) |
EventSourceResponse |
reopenEvents(Request request,
java.lang.String lastId,
int timeout) |
protected void |
setProperties(ConnectionString conn) |
Response |
trace(java.lang.String uri,
java.lang.String... headers) |
createObject, destroyObject, getBusyCount, getConnectTimeout, getFifo, getIdleCount, getMaxCount, getProxy, getReadTimeout, getSslContext, getTimeout, getTimeouts, getWaitingThreads, name, setConnectTimeout, setFifo, setMaxCount, setProxy, setReadTimeout, setSslContext, setTimeoutborrowObject, close, initialize, invalidateAll, invalidateObject, isClosed, returnObjectadd, add, addAll, addAll, addFirst, addLast, clear, clone, contains, descendingIterator, element, get, getFirst, getLast, indexOf, lastIndexOf, listIterator, offer, offerFirst, offerLast, peek, peekFirst, peekLast, poll, pollFirst, pollLast, pop, push, remove, remove, remove, removeFirst, removeFirstOccurrence, removeLast, removeLastOccurrence, set, size, spliterator, toArray, toArrayequals, hashCode, listIterator, removeRange, subListcontainsAll, isEmpty, removeAll, retainAll, toStringfinalize, getClass, notify, notifyAll, wait, wait, waitinvalidateAll, isClosedprotected java.lang.String[] permanentHeaders
protected int bufferSize
public HttpClient(ConnectionString conn)
public HttpClient(ConnectionString conn, java.lang.String... permanentHeaders)
protected void setProperties(ConnectionString conn)
setProperties in class SocketPoolpublic Response invoke(Request request) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response invoke(Request request, int timeout) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response get(java.lang.String uri, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic EventSourceResponse openEvents(java.lang.String uri, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response delete(java.lang.String uri, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response post(java.lang.String uri, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response post(java.lang.String uri, byte[] body, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response put(java.lang.String uri, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response put(java.lang.String uri, byte[] body, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response patch(java.lang.String uri, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response patch(java.lang.String uri, byte[] body, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response head(java.lang.String uri, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response options(java.lang.String uri, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response trace(java.lang.String uri, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Response connect(java.lang.String uri, java.lang.String... headers) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic EventSourceResponse openEvents(Request request, int timeout) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic EventSourceResponse reopenEvents(Request request, java.lang.String lastId, int timeout) throws java.lang.InterruptedException, PoolException, java.io.IOException, HttpException
java.lang.InterruptedExceptionPoolExceptionjava.io.IOExceptionHttpExceptionpublic Request createRequest(int method, java.lang.String uri, java.lang.String... headers)