static ContentType |
ContentType.create(java.lang.String mimeType) |
Creates a new instance of ContentType without a charset.
|
static ContentType |
ContentType.create(java.lang.String mimeType,
java.lang.String charset) |
|
static ContentType |
ContentType.create(java.lang.String mimeType,
java.nio.charset.Charset charset) |
|
static ContentType |
ContentType.create(java.lang.String mimeType,
NameValuePair... params) |
Creates a new instance of ContentType with the given parameters.
|
static ContentType |
ContentType.get(HttpEntity entity) |
Extracts Content-Type value from HttpEntity exactly as
specified by the Content-Type header of the entity.
|
static ContentType |
ContentType.getByMimeType(java.lang.String mimeType) |
Returns Content-Type for the given MIME type.
|
static ContentType |
ContentType.getLenient(HttpEntity entity) |
|
static ContentType |
ContentType.getLenientOrDefault(HttpEntity entity) |
Extracts Content-Type value from HttpEntity or returns the default value
DEFAULT_TEXT if not explicitly specified or incorrect (could not be parsed).
|
static ContentType |
ContentType.getOrDefault(HttpEntity entity) |
Extracts Content-Type value from HttpEntity or returns the default value
DEFAULT_TEXT if not explicitly specified.
|
static ContentType |
ContentType.parse(java.lang.String s) |
Parses textual representation of Content-Type value.
|
ContentType |
ContentType.withCharset(java.lang.String charset) |
Creates a new instance with this MIME type and the given Charset name.
|
ContentType |
ContentType.withCharset(java.nio.charset.Charset charset) |
Creates a new instance with this MIME type and the given Charset.
|
ContentType |
ContentType.withParameters(NameValuePair... params) |
Creates a new instance with this MIME type and the given parameters.
|