[http] Additional methods
This commit is contained in:
parent
f9782a1ef5
commit
97d86d35be
|
@ -56,7 +56,10 @@ public class HttpUtils {
|
|||
|
||||
private enum Method {
|
||||
GET,
|
||||
POST
|
||||
POST,
|
||||
PUT,
|
||||
PATCH,
|
||||
DELETE
|
||||
}
|
||||
|
||||
public static class Request {
|
||||
|
@ -201,4 +204,16 @@ public class HttpUtils {
|
|||
public static Request post(String url) throws URISyntaxException {
|
||||
return new Request(Method.POST, url);
|
||||
}
|
||||
|
||||
public static Request put(String url) throws URISyntaxException {
|
||||
return new Request(Method.PUT, url);
|
||||
}
|
||||
|
||||
public static Request patch(String url) throws URISyntaxException {
|
||||
return new Request(Method.PATCH, url);
|
||||
}
|
||||
|
||||
public static Request delete(String url) throws URISyntaxException {
|
||||
return new Request(Method.DELETE, url);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user