public interface HTTPConnector
Modifier and Type | Field and Description |
---|---|
static int |
ACTION_DELETE |
static int |
ACTION_GET |
static int |
ACTION_HEAD |
static int |
ACTION_POST |
static int |
ACTION_PUT |
Modifier and Type | Method and Description |
---|---|
void |
close() |
int |
doDelete(java.lang.String urlStr,
java.util.Map extra,
java.lang.StringBuffer response)
It sends a DELETE request to the HTTP server with urlStr and loads the
response header to the provided StringBuffer.
|
int |
doDelete(java.lang.String urlStr,
java.lang.StringBuffer response) |
int |
doGet(java.lang.String urlStr,
java.util.Map extra,
java.lang.StringBuffer response,
java.io.OutputStream out)
It sends a GET request to the HTTP server with the urlStr and the extra
request headers stored in the Map.
|
int |
doGet(java.lang.String urlStr,
java.lang.StringBuffer response)
It sends a GET request to the HTTP server with the urlStr.
|
int |
doGet(java.lang.String urlStr,
java.lang.StringBuffer response,
java.io.OutputStream out) |
int |
doHead(java.lang.String urlStr,
java.util.Map extra,
java.lang.StringBuffer response)
It sends a HEAD request to the HTTP server with the urlStr and loads the
response header to the provided StringBuffer.
|
int |
doHead(java.lang.String urlStr,
java.lang.StringBuffer response) |
int |
doPost(java.lang.String urlStr,
BytesBuffer buf,
java.lang.StringBuffer response)
It sends a POST request to the HTTP server with the urlStr and the
request content stored in the byte buffer.
|
int |
doPost(java.lang.String urlStr,
BytesBuffer buf,
java.lang.StringBuffer response,
java.io.OutputStream out) |
int |
doPost(java.lang.String urlStr,
java.util.Map extra,
BytesBuffer buf,
java.lang.StringBuffer response) |
int |
doPost(java.lang.String urlStr,
java.util.Map extra,
BytesBuffer buf,
java.lang.StringBuffer response,
java.io.OutputStream out)
It sends a POST request to the HTTP server with the urlStr and the extra
request headers, as well as the content stored in the BytesBuffer.
|
int |
doPost(java.lang.String urlStr,
java.util.Map extra,
java.lang.String line,
java.lang.StringBuffer response) |
int |
doPost(java.lang.String urlStr,
java.lang.String line,
java.lang.StringBuffer response) |
int |
doPut(java.lang.String urlStr,
BytesBuffer buf,
java.lang.StringBuffer response,
java.io.OutputStream out) |
int |
doPut(java.lang.String urlStr,
java.util.Map extra,
BytesBuffer buf,
java.lang.StringBuffer response,
java.io.OutputStream out)
It sends a PUT request to the HTTP server with the urlStr and the extra
request headers, as well as the content stored in the BytesBuffer.
|
java.lang.String |
getURI() |
boolean |
isConnected() |
boolean |
isHTTPS() |
boolean |
isPost() |
java.lang.String |
reconnect()
reconnects and returns null upon success or error msg otherwise
|
static final int ACTION_HEAD
static final int ACTION_GET
static final int ACTION_PUT
static final int ACTION_POST
static final int ACTION_DELETE
int doGet(java.lang.String urlStr, java.util.Map extra, java.lang.StringBuffer response, java.io.OutputStream out) throws java.io.IOException
java.io.IOException
int doGet(java.lang.String urlStr, java.lang.StringBuffer response, java.io.OutputStream out) throws java.io.IOException
java.io.IOException
int doGet(java.lang.String urlStr, java.lang.StringBuffer response) throws java.io.IOException
java.io.IOException
int doPost(java.lang.String urlStr, java.util.Map extra, BytesBuffer buf, java.lang.StringBuffer response, java.io.OutputStream out) throws java.io.IOException
java.io.IOException
int doPost(java.lang.String urlStr, BytesBuffer buf, java.lang.StringBuffer response, java.io.OutputStream out) throws java.io.IOException
java.io.IOException
int doPost(java.lang.String urlStr, BytesBuffer buf, java.lang.StringBuffer response) throws java.io.IOException
java.io.IOException
int doPost(java.lang.String urlStr, java.lang.String line, java.lang.StringBuffer response) throws java.io.IOException
java.io.IOException
int doPost(java.lang.String urlStr, java.util.Map extra, BytesBuffer buf, java.lang.StringBuffer response) throws java.io.IOException
java.io.IOException
int doPost(java.lang.String urlStr, java.util.Map extra, java.lang.String line, java.lang.StringBuffer response) throws java.io.IOException
java.io.IOException
int doPut(java.lang.String urlStr, java.util.Map extra, BytesBuffer buf, java.lang.StringBuffer response, java.io.OutputStream out) throws java.io.IOException
java.io.IOException
int doPut(java.lang.String urlStr, BytesBuffer buf, java.lang.StringBuffer response, java.io.OutputStream out) throws java.io.IOException
java.io.IOException
int doHead(java.lang.String urlStr, java.util.Map extra, java.lang.StringBuffer response) throws java.io.IOException
java.io.IOException
int doHead(java.lang.String urlStr, java.lang.StringBuffer response) throws java.io.IOException
java.io.IOException
int doDelete(java.lang.String urlStr, java.util.Map extra, java.lang.StringBuffer response) throws java.io.IOException
java.io.IOException
int doDelete(java.lang.String urlStr, java.lang.StringBuffer response) throws java.io.IOException
java.io.IOException
boolean isPost()
boolean isHTTPS()
java.lang.String reconnect()
boolean isConnected()
java.lang.String getURI()
void close()