org.yelong.http.request.HttpRequestFactory Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of yelong-http Show documentation
Show all versions of yelong-http Show documentation
简单封装java对http的请求,实现便捷的发送http请求(可以发送携带文件的请求)
The newest version!
/**
*
*/
package org.yelong.http.request;
/**
* http 请求工厂
*
* @since 1.0
*/
public class HttpRequestFactory {
/**
* 创建默认的http请求
*
* @param url url (http://www.baidu.com)
* @param method 请求method (GET、POST)
* @return request
*/
public static HttpRequest create(String url, String method) {
return new DefaultHttpRequest(url, method);
}
}