@ClassPreamble(author="Maksym Novozhylov <mnovozhilov@upwork.com>", date="5/31/2014", currentRevision=2, lastModified="6/3/2014", lastModifiedBy="Maksym Novozhylov", reviewers="Yiota Tsakiri") public class UpworkRestClient extends java.lang.Object
| Constructor and Description |
|---|
UpworkRestClient() |
| Modifier and Type | Method and Description |
|---|---|
static JSONObject |
getJSONObject(HttpGet request)
Get JSON response for GET
|
static JSONObject |
getJSONObject(HttpGet request,
java.lang.Integer method)
Get JSON response for GET
|
static JSONObject |
getJSONObject(HttpGet request,
java.lang.Integer method,
java.util.HashMap<java.lang.String,java.lang.String> params)
Get JSON response for GET
|
static JSONObject |
getJSONObject(HttpPost request,
java.lang.Integer method,
java.util.HashMap<java.lang.String,java.lang.String> params)
Get JSON response for POST
|
public static JSONObject getJSONObject(HttpGet request)
throws JSONException
request - Request object for GETJSONObjectJSONExceptionpublic static JSONObject getJSONObject(HttpGet request,
java.lang.Integer method)
throws JSONException
request - Request object for GETmethod - HTTP MethodJSONObjectJSONExceptionpublic static JSONObject getJSONObject(HttpGet request,
java.lang.Integer method,
java.util.HashMap<java.lang.String,java.lang.String> params)
throws JSONException
request - Request object for GETmethod - HTTP methodparams - POST parametersJSONObjectJSONExceptionpublic static JSONObject getJSONObject(HttpPost request,
java.lang.Integer method,
java.util.HashMap<java.lang.String,java.lang.String> params)
throws JSONException
request - Request object for POSTmethod - HTTP methodparams - POST parametersJSONObjectJSONException