public class MaximalBodyDescriptor extends java.lang.Object implements BodyDescriptor
BodyDescriptor implementation with complete content details.| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
boundary |
private java.lang.String |
charset |
private static java.lang.String |
CONTENT_DESCRIPTION |
private static java.lang.String |
CONTENT_DISPOSITION |
private static java.lang.String |
CONTENT_ID |
private static java.lang.String |
CONTENT_LANGUAGE |
private static java.lang.String |
CONTENT_LENGTH |
private static java.lang.String |
CONTENT_LOCATION |
private static java.lang.String |
CONTENT_MD5 |
private static java.lang.String |
CONTENT_TRANSFER_ENCODING |
private static java.lang.String |
CONTENT_TYPE |
private java.util.Map<java.lang.String,ParsedField> |
fields |
private java.lang.String |
mediaType |
private static java.lang.String |
MIME_VERSION |
private java.lang.String |
mimeType |
private java.lang.String |
subType |
| Constructor and Description |
|---|
MaximalBodyDescriptor(java.lang.String mimeType,
java.lang.String mediaType,
java.lang.String subType,
java.lang.String boundary,
java.lang.String charset,
java.util.Map<java.lang.String,ParsedField> fields) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getBoundary()
Returns the body descriptors boundary.
|
java.lang.String |
getCharset()
The body descriptors character set, defaulted appropriately for the MIME type.
|
java.lang.String |
getContentDescription()
Gets the value of the RFC
Content-Description header. |
java.util.Date |
getContentDispositionCreationDate()
Gets the
creation-date parameter value of the content-disposition field. |
java.lang.String |
getContentDispositionFilename()
Gets the
filename parameter value of the content-disposition field. |
java.util.Date |
getContentDispositionModificationDate()
Gets the
modification-date parameter value of the content-disposition field. |
java.util.Map<java.lang.String,java.lang.String> |
getContentDispositionParameters()
Gets the parameters of the
content-disposition field. |
java.util.Date |
getContentDispositionReadDate()
Gets the
read-date parameter value of the content-disposition field. |
long |
getContentDispositionSize()
Gets the
size parameter value of the content-disposition field. |
java.lang.String |
getContentDispositionType()
Gets the disposition type of the
content-disposition field. |
java.lang.String |
getContentId()
Gets the value of the RFC
Content-ID header. |
java.util.List<java.lang.String> |
getContentLanguage()
Get the
content-language header values. |
long |
getContentLength()
Returns the body descriptors content-length.
|
java.lang.String |
getContentLocation()
Get the
content-location header value. |
java.lang.String |
getContentMD5Raw()
Gets the raw, Base64 encoded value of the
Content-MD5 field. |
java.util.Map<java.lang.String,java.lang.String> |
getContentTypeParameters() |
java.lang.String |
getMediaType()
Gets the defaulted MIME media type for this content.
|
int |
getMimeMajorVersion()
Gets the MIME major version
as specified by the
MIME-Version
header. |
int |
getMimeMinorVersion()
Gets the MIME minor version
as specified by the
MIME-Version
header. |
java.lang.String |
getMimeType()
Returns the body descriptors MIME type.
|
java.lang.String |
getSubType()
Gets the defaulted MIME sub type for this content.
|
java.lang.String |
getTransferEncoding()
Returns the body descriptors transfer encoding.
|
java.lang.String |
toString() |
private static final java.lang.String CONTENT_TYPE
private static final java.lang.String CONTENT_LENGTH
private static final java.lang.String CONTENT_TRANSFER_ENCODING
private static final java.lang.String CONTENT_DISPOSITION
private static final java.lang.String CONTENT_ID
private static final java.lang.String CONTENT_MD5
private static final java.lang.String CONTENT_DESCRIPTION
private static final java.lang.String CONTENT_LANGUAGE
private static final java.lang.String CONTENT_LOCATION
private static final java.lang.String MIME_VERSION
private final java.lang.String mediaType
private final java.lang.String subType
private final java.lang.String mimeType
private final java.lang.String boundary
private final java.lang.String charset
private final java.util.Map<java.lang.String,ParsedField> fields
MaximalBodyDescriptor(java.lang.String mimeType,
java.lang.String mediaType,
java.lang.String subType,
java.lang.String boundary,
java.lang.String charset,
java.util.Map<java.lang.String,ParsedField> fields)
public java.lang.String getMimeType()
ContentDescriptorgetMimeType in interface ContentDescriptorContentDescriptor.getMediaType(),
ContentDescriptor.getSubType()public java.lang.String getBoundary()
BodyDescriptorgetBoundary in interface BodyDescriptorpublic java.lang.String getCharset()
ContentDescriptorThe body descriptors character set, defaulted appropriately for the MIME type.
For TEXT types, this will be defaulted to us-ascii.
For other types, when the charset parameter is missing this property will be null.
getCharset in interface ContentDescriptorTEXT types, when unset will
be set to default us-ascii. For other types, when unset,
null will be returned.public java.lang.String getMediaType()
ContentDescriptorTEXT, IMAGE, MULTIPARTgetMediaType in interface ContentDescriptorTEXT)ContentDescriptor.getMimeType()public java.lang.String getSubType()
ContentDescriptorgetSubType in interface ContentDescriptorPLAIN)ContentDescriptor.getMimeType()public java.util.Map<java.lang.String,java.lang.String> getContentTypeParameters()
public java.lang.String getTransferEncoding()
ContentDescriptorgetTransferEncoding in interface ContentDescriptorpublic long getContentLength()
ContentDescriptorgetContentLength in interface ContentDescriptorpublic int getMimeMajorVersion()
MIME-Version
header.
Defaults to one.public int getMimeMinorVersion()
MIME-Version
header.
Defaults to zero.public java.lang.String getContentDescription()
Content-Description header.Content-Description when present,
null otherwisepublic java.lang.String getContentId()
Content-ID header.Content-ID when present,
null otherwisepublic java.lang.String getContentDispositionType()
content-disposition field.
The value is case insensitive and will be converted to lower case.
See RFC2183.public java.util.Map<java.lang.String,java.lang.String> getContentDispositionParameters()
content-disposition field.
See RFC2183.public java.lang.String getContentDispositionFilename()
public java.util.Date getContentDispositionModificationDate()
public java.util.Date getContentDispositionCreationDate()
public java.util.Date getContentDispositionReadDate()
public long getContentDispositionSize()
public java.util.List<java.lang.String> getContentLanguage()
content-language header values.
Each applicable language tag will be returned in order.
See RFC4646
http://tools.ietf.org/html/rfc4646.public java.lang.String getContentLocation()
content-location header value.
See RFC2557public java.lang.String getContentMD5Raw()
Content-MD5 field.
See RFC1864.public java.lang.String toString()
toString in class java.lang.Object