org.apache.james.mime4j.message
Class MaximalBodyDescriptor

java.lang.Object
  extended by org.apache.james.mime4j.message.MaximalBodyDescriptor
All Implemented Interfaces:
BodyDescriptor, ContentDescriptor

public class MaximalBodyDescriptor
extends java.lang.Object
implements BodyDescriptor

Extended BodyDescriptor implementation with complete content details.


Method Summary
 java.lang.String getBoundary()
           
 java.lang.String getCharset()
           
 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()
           
 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()
           
 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()
           
 java.lang.String getSubType()
           
 java.lang.String getTransferEncoding()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getMimeType

public java.lang.String getMimeType()
Specified by:
getMimeType in interface ContentDescriptor

getBoundary

public java.lang.String getBoundary()
Specified by:
getBoundary in interface BodyDescriptor

getCharset

public java.lang.String getCharset()
Specified by:
getCharset in interface ContentDescriptor

getMediaType

public java.lang.String getMediaType()
Specified by:
getMediaType in interface ContentDescriptor

getSubType

public java.lang.String getSubType()
Specified by:
getSubType in interface ContentDescriptor

getContentTypeParameters

public java.util.Map<java.lang.String,java.lang.String> getContentTypeParameters()

getTransferEncoding

public java.lang.String getTransferEncoding()
Specified by:
getTransferEncoding in interface ContentDescriptor

getContentLength

public long getContentLength()
Specified by:
getContentLength in interface ContentDescriptor

getMimeMajorVersion

public int getMimeMajorVersion()
Gets the MIME major version as specified by the MIME-Version header. Defaults to one.

Returns:
positive integer

getMimeMinorVersion

public int getMimeMinorVersion()
Gets the MIME minor version as specified by the MIME-Version header. Defaults to zero.

Returns:
positive integer

getContentDescription

public java.lang.String getContentDescription()
Gets the value of the RFC Content-Description header.

Returns:
value of the Content-Description when present, null otherwise

getContentId

public java.lang.String getContentId()
Gets the value of the RFC Content-ID header.

Returns:
value of the Content-ID when present, null otherwise

getContentDispositionType

public java.lang.String getContentDispositionType()
Gets the disposition type of the content-disposition field. The value is case insensitive and will be converted to lower case. See RFC2183.

Returns:
content disposition type, or null when this has not been set

getContentDispositionParameters

public java.util.Map<java.lang.String,java.lang.String> getContentDispositionParameters()
Gets the parameters of the content-disposition field. See RFC2183.

Returns:
parameter value strings indexed by parameter name strings, not null

getContentDispositionFilename

public java.lang.String getContentDispositionFilename()
Gets the filename parameter value of the content-disposition field. See RFC2183.

Returns:
filename parameter value, or null when it is not present

getContentDispositionModificationDate

public java.util.Date getContentDispositionModificationDate()
Gets the modification-date parameter value of the content-disposition field. See RFC2183.

Returns:
modification-date parameter value, or null when this is not present

getContentDispositionCreationDate

public java.util.Date getContentDispositionCreationDate()
Gets the creation-date parameter value of the content-disposition field. See RFC2183.

Returns:
creation-date parameter value, or null when this is not present

getContentDispositionReadDate

public java.util.Date getContentDispositionReadDate()
Gets the read-date parameter value of the content-disposition field. See RFC2183.

Returns:
read-date parameter value, or null when this is not present

getContentDispositionSize

public long getContentDispositionSize()
Gets the size parameter value of the content-disposition field. See RFC2183.

Returns:
size parameter value, or -1 if this size has not been set

getContentLanguage

public java.util.List<java.lang.String> getContentLanguage()
Get the content-language header values. Each applicable language tag will be returned in order. See RFC4646 http://tools.ietf.org/html/rfc4646.

Returns:
list of language tag Strings, or null if no header exists

getContentLocation

public java.lang.String getContentLocation()
Get the content-location header value. See RFC2557

Returns:
the URL content-location or null if no header exists

getContentMD5Raw

public java.lang.String getContentMD5Raw()
Gets the raw, Base64 encoded value of the Content-MD5 field. See RFC1864.

Returns:
raw encoded content-md5 or null if no header exists

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2004-2011 The Apache Software Foundation. All Rights Reserved.