Class ContentType
java.lang.Object
ch.autumo.commons.cache.ContentType
Class to handle HTML content types headers and their encodings.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet boundary.Get content type.Get content type header.Get encoding.booleanIs multipart?tryUTF8()Create an UTF8 content type if this encoding is not set, otherwise this content type is returned.
-
Field Details
-
MULTIPART_FORM_DATA_HEADER
-
-
Constructor Details
-
ContentType
Create a content type.- Parameters:
contentTypeHeader- Content type header
-
-
Method Details
-
getContentTypeHeader
-
getContentType
-
getEncoding
-
getBoundary
-
isMultipart
public boolean isMultipart()Is multipart?- Returns:
- true if so
-
tryUTF8
Create an UTF8 content type if this encoding is not set, otherwise this content type is returned.- Returns:
- UTF8 content type if this encoding is not set
-