Some small refactoring
This commit is contained in:
parent
aa173ce092
commit
65b47d0755
1 changed files with 2 additions and 6 deletions
|
|
@ -73,12 +73,8 @@ public class RESTClientInvocationHandler implements InvocationHandler {
|
||||||
HttpURL url = generateRESTRequest(methodDef, args);
|
HttpURL url = generateRESTRequest(methodDef, args);
|
||||||
|
|
||||||
String requestType = "GET";
|
String requestType = "GET";
|
||||||
switch (methodDef.getRequestType()) {
|
if (methodDef.getRequestType() != null)
|
||||||
case GET: requestType = "GET"; break;
|
requestType = methodDef.getRequestType().toString();
|
||||||
case PUT: requestType = "PUT"; break;
|
|
||||||
case POST: requestType = "POST"; break;
|
|
||||||
case DELETE: requestType = "DELETE"; break;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Send request
|
// Send request
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue