org.apache.james.mime4j.descriptor
public class MaximalBodyDescriptor extends DefaultBodyDescriptor
Modifier | Constructor and Description |
---|---|
protected |
MaximalBodyDescriptor() |
|
MaximalBodyDescriptor(BodyDescriptor parent) |
Modifier and Type | Method and Description |
---|---|
void |
addField(Field field)
Should be called for each
Content- header field of
a MIME message or part. |
java.lang.String |
getContentDescription()
Gets the value of the RFC
Content-Description header. |
DateTime |
getContentDispositionCreationDate()
Gets the
creation-date parameter value of the content-disposition field. |
MimeException |
getContentDispositionCreationDateParseException()
Gets any exception thrown during the parsing of
getContentDispositionCreationDate() |
java.lang.String |
getContentDispositionFilename()
Gets the
filename parameter value of the content-disposition field. |
DateTime |
getContentDispositionModificationDate()
Gets the
modification-date parameter value of the content-disposition field. |
MimeException |
getContentDispositionModificationDateParseException()
Gets any exception thrown during the parsing of
getContentDispositionModificationDate() |
java.util.Map<java.lang.String,java.lang.String> |
getContentDispositionParameters()
Gets the parameters of the
content-disposition field. |
DateTime |
getContentDispositionReadDate()
Gets the
read-date parameter value of the content-disposition field. |
MimeException |
getContentDispositionReadDateParseException()
Gets any exception thrown during the parsing of
getContentDispositionReadDate() |
long |
getContentDispositionSize()
Gets the
size parameter value of the content-disposition field. |
MimeException |
getContentDispositionSizeParseException()
Gets any exception thrown during the parsing of
getContentDispositionSize() |
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. |
MimeException |
getContentLanguageParseException()
Gets any exception thrown during the parsing of
getContentLanguage() |
java.lang.String |
getContentLocation()
Get the
content-location header value. |
MimeException |
getContentLocationParseException()
Gets any exception thrown during the parsing of
getContentLocation() |
java.lang.String |
getContentMD5Raw()
Gets the raw, Base64 encoded value of the
Content-MD5 field. |
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. |
MimeException |
getMimeVersionParseException()
When the MIME version header exists but cannot be parsed
this field will be contain the exception.
|
getBoundary, getCharset, getContentLength, getContentTypeParameters, getMediaType, getMimeType, getSubType, getTransferEncoding, toString
protected MaximalBodyDescriptor()
public MaximalBodyDescriptor(BodyDescriptor parent)
public void addField(Field field)
DefaultBodyDescriptor
Content-
header field of
a MIME message or part.addField
in interface MutableBodyDescriptor
addField
in class DefaultBodyDescriptor
field
- the MIME field.public int getMimeMajorVersion()
MIME-Version
header.
Defaults to one.public int getMimeMinorVersion()
MIME-Version
header.
Defaults to zero.public MimeException getMimeVersionParseException()
MimeException
if the mime header cannot
be parsed, null otherwisepublic 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 DateTime getContentDispositionModificationDate()
public MimeException getContentDispositionModificationDateParseException()
getContentDispositionModificationDate()
ParseException
when the modification-date parse fails,
null otherwisepublic DateTime getContentDispositionCreationDate()
public MimeException getContentDispositionCreationDateParseException()
getContentDispositionCreationDate()
ParseException
when the creation-date parse fails,
null otherwisepublic DateTime getContentDispositionReadDate()
public MimeException getContentDispositionReadDateParseException()
getContentDispositionReadDate()
ParseException
when the read-date parse fails,
null otherwisepublic long getContentDispositionSize()
public MimeException getContentDispositionSizeParseException()
getContentDispositionSize()
ParseException
when the read-date parse fails,
null otherwisepublic 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 MimeException getContentLanguageParseException()
getContentLanguage()
ParseException
when the content-language parse fails,
null otherwisepublic java.lang.String getContentLocation()
content-location
header value.
See RFC2557public MimeException getContentLocationParseException()
getContentLocation()
ParseException
when the content-language parse fails,
null otherwisepublic java.lang.String getContentMD5Raw()
Content-MD5
field.
See RFC1864.Copyright © 2004-2016. All Rights Reserved.