public class HttpUtil
extends Object
Constructor and Description |
---|
HttpUtil() |
Modifier and Type | Method and Description |
---|---|
static javax.servlet.http.Cookie[] |
getCookies() |
static Http |
getHttp() |
static boolean |
hasProxyConfig() |
static boolean |
isNonProxyHost(String host) |
static boolean |
isProxyHost(String host) |
static byte[] |
URLtoByteArray(Http.Options options) |
static byte[] |
URLtoByteArray(String location) |
static byte[] |
URLtoByteArray(String location,
boolean post) |
static InputStream |
URLtoInputStream(Http.Options options) |
static InputStream |
URLtoInputStream(String location) |
static InputStream |
URLtoInputStream(String location,
boolean post) |
static String |
URLtoString(Http.Options options) |
static String |
URLtoString(String location) |
static String |
URLtoString(String location,
boolean post) |
static String |
URLtoString(URL url)
This method only uses the default Commons HttpClient implementation when
the URL object represents a HTTP resource.
|
public static javax.servlet.http.Cookie[] getCookies()
public static Http getHttp()
public static boolean hasProxyConfig()
public static boolean isNonProxyHost(String host)
public static boolean isProxyHost(String host)
public static byte[] URLtoByteArray(Http.Options options) throws IOException
IOException
public static byte[] URLtoByteArray(String location) throws IOException
IOException
public static byte[] URLtoByteArray(String location, boolean post) throws IOException
IOException
public static InputStream URLtoInputStream(Http.Options options) throws IOException
IOException
public static InputStream URLtoInputStream(String location) throws IOException
IOException
public static InputStream URLtoInputStream(String location, boolean post) throws IOException
IOException
public static String URLtoString(Http.Options options) throws IOException
IOException
public static String URLtoString(String location) throws IOException
IOException
public static String URLtoString(String location, boolean post) throws IOException
IOException
public static String URLtoString(URL url) throws IOException
url
- the URLIOException
- if an IO Exception occurred