public class HttpConst
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
GET
Defines get http method
|
static java.lang.String |
HTTP
Defines a http prefix
|
static java.lang.String |
HTTPCONN
Defines a http socket connection
|
static java.lang.String |
HTTPS
Defines a https prefix
|
static java.lang.String |
POST
Defines post http method
|
static java.lang.String |
URLCONN
Defines a url web connection
|
Constructor and Description |
---|
HttpConst() |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
getHttp(java.lang.String uri)
Get the http part if the uri starts with that.
|
static java.lang.String |
removeHttp(java.lang.String uri)
Remove the http part if the uri starts with it and return the rest.
|
static boolean |
startsWithHttp(java.lang.String uri)
Return true if the URI starts with the http or https address.
|
public static final java.lang.String HTTPCONN
public static final java.lang.String URLCONN
public static final java.lang.String HTTP
public static final java.lang.String HTTPS
public static final java.lang.String GET
public static final java.lang.String POST
public static boolean startsWithHttp(java.lang.String uri)
uri
- the uri address.public static java.lang.String getHttp(java.lang.String uri)
uri
- the uri address.public static java.lang.String removeHttp(java.lang.String uri)
uri
- the uri address.