|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.mail.BodyPart
javax.mail.internet.MimeBodyPart
org.apache.geronimo.javamail.store.imap.IMAPMimeBodyPart
public class IMAPMimeBodyPart
| Field Summary | |
|---|---|
protected IMAPBodyStructure |
bodyStructure
|
protected IMAPMessage |
message
|
protected String |
section
|
| Fields inherited from class javax.mail.internet.MimeBodyPart |
|---|
content, contentStream, dh, headers |
| Fields inherited from class javax.mail.BodyPart |
|---|
parent |
| Fields inherited from interface javax.mail.Part |
|---|
ATTACHMENT, INLINE |
| Constructor Summary | |
|---|---|
IMAPMimeBodyPart(IMAPMessage message,
IMAPBodyStructure bodyStructure,
String section)
Create an instance of a MimeBodyPart within an IMAP message. |
|
| Method Summary | |
|---|---|
void |
addHeader(String name,
String value)
|
void |
addHeaderLine(String line)
|
Enumeration |
getAllHeaderLines()
|
Enumeration |
getAllHeaders()
|
String |
getContentID()
|
String |
getContentMD5()
|
protected InputStream |
getContentStream()
|
String |
getContentType()
Get the content type for the body part. |
DataHandler |
getDataHandler()
Create the DataHandler object for this message. |
String |
getDescription()
|
String |
getDisposition()
Retrieve the disposition information about this body part. |
String |
getEncoding()
|
String |
getFileName()
|
String[] |
getHeader(String name)
Following is a set of methods that deal with headers These methods are just overrides on the superclass methods to allow lazy loading of the header information. |
String |
getHeader(String name,
String delimiter)
|
int |
getLineCount()
Get the estimated line count for the body part. |
Enumeration |
getMatchingHeaderLines(String[] names)
|
Enumeration |
getMatchingHeaders(String[] names)
|
Enumeration |
getNonMatchingHeaderLines(String[] names)
|
Enumeration |
getNonMatchingHeaders(String[] names)
|
int |
getSize()
Get the size of the message part. |
boolean |
isMimeType(String type)
Test if the body part is of a particular MIME type. |
protected void |
loadContent()
Load the message content into the BodyPart object. |
protected void |
loadHeaders()
Load the mime part headers into this body part. |
void |
removeHeader(String name)
|
void |
setContent(Multipart mp)
|
void |
setContent(Object o,
String type)
|
void |
setContentID(String id)
|
void |
setContentMD5(String id)
|
void |
setDataHandler(DataHandler content)
|
void |
setDescription(String d,
String charset)
|
void |
setDisposition(String disposition)
Set the disposition information. |
void |
setFileName(String name)
|
void |
setHeader(String name,
String value)
|
| Methods inherited from class javax.mail.internet.MimeBodyPart |
|---|
attachFile, attachFile, getContent, getContentLanguage, getInputStream, getRawInputStream, saveFile, saveFile, setContentLanguage, setDescription, setText, setText, setText, updateHeaders, writeTo |
| Methods inherited from class javax.mail.BodyPart |
|---|
getParent |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected IMAPMessage message
protected IMAPBodyStructure bodyStructure
protected String section
| Constructor Detail |
|---|
public IMAPMimeBodyPart(IMAPMessage message,
IMAPBodyStructure bodyStructure,
String section)
message - The parent Message instance containing this part.bodyStructure - The IMAPBodyStructure information describing the part.section - The numeric section identifier string for this part.
This is a hierarchical set of numbers describing
how to navigate to the message part on the IMAP
server. For example, "2.1.3" would be the third
subpart of the first subpart of the second main
message part.| Method Detail |
|---|
public int getSize()
throws MessagingException
getSize in interface PartgetSize in class MimeBodyPartMessagingException
public int getLineCount()
throws MessagingException
getLineCount in interface PartgetLineCount in class MimeBodyPartMessagingException
public String getContentType()
throws MessagingException
getContentType in interface PartgetContentType in class MimeBodyPartMessagingException
public boolean isMimeType(String type)
throws MessagingException
isMimeType in interface PartisMimeType in class MimeBodyParttype - The string MIME-type name. A wild card * can be
specified for the subpart type.
MessagingException
public String getDisposition()
throws MessagingException
getDisposition in interface PartgetDisposition in class MimeBodyPartMessagingException
public void setDisposition(String disposition)
throws MessagingException
setDisposition in interface PartsetDisposition in class MimeBodyPartdisposition - The disposition string.
MessagingException
public String getEncoding()
throws MessagingException
getEncoding in interface MimePartgetEncoding in class MimeBodyPartMessagingException
public String getContentID()
throws MessagingException
getContentID in interface MimePartgetContentID in class MimeBodyPartMessagingException
public void setContentID(String id)
throws MessagingException
setContentID in class MimeBodyPartMessagingException
public String getContentMD5()
throws MessagingException
getContentMD5 in interface MimePartgetContentMD5 in class MimeBodyPartMessagingException
public void setContentMD5(String id)
throws MessagingException
setContentMD5 in interface MimePartsetContentMD5 in class MimeBodyPartMessagingException
public String getDescription()
throws MessagingException
getDescription in interface PartgetDescription in class MimeBodyPartMessagingException
public void setDescription(String d,
String charset)
throws MessagingException
setDescription in class MimeBodyPartMessagingException
public String getFileName()
throws MessagingException
getFileName in interface PartgetFileName in class MimeBodyPartMessagingException
public void setFileName(String name)
throws MessagingException
setFileName in interface PartsetFileName in class MimeBodyPartMessagingException
protected InputStream getContentStream()
throws MessagingException
getContentStream in class MimeBodyPartMessagingException
public DataHandler getDataHandler()
throws MessagingException
getDataHandler in interface PartgetDataHandler in class MimeBodyPartMessagingException
public void setDataHandler(DataHandler content)
throws MessagingException
setDataHandler in interface PartsetDataHandler in class MimeBodyPartMessagingException
public void setContent(Object o,
String type)
throws MessagingException
setContent in interface PartsetContent in class MimeBodyPartMessagingException
public void setContent(Multipart mp)
throws MessagingException
setContent in interface PartsetContent in class MimeBodyPartMessagingException
public String[] getHeader(String name)
throws MessagingException
getHeader in interface PartgetHeader in class MimeBodyPartMessagingException
public String getHeader(String name,
String delimiter)
throws MessagingException
getHeader in interface MimePartgetHeader in class MimeBodyPartMessagingException
public Enumeration getAllHeaders()
throws MessagingException
getAllHeaders in interface PartgetAllHeaders in class MimeBodyPartMessagingException
public Enumeration getMatchingHeaders(String[] names)
throws MessagingException
getMatchingHeaders in interface PartgetMatchingHeaders in class MimeBodyPartMessagingException
public Enumeration getNonMatchingHeaders(String[] names)
throws MessagingException
getNonMatchingHeaders in interface PartgetNonMatchingHeaders in class MimeBodyPartMessagingException
public Enumeration getAllHeaderLines()
throws MessagingException
getAllHeaderLines in interface MimePartgetAllHeaderLines in class MimeBodyPartMessagingException
public Enumeration getMatchingHeaderLines(String[] names)
throws MessagingException
getMatchingHeaderLines in interface MimePartgetMatchingHeaderLines in class MimeBodyPartMessagingException
public Enumeration getNonMatchingHeaderLines(String[] names)
throws MessagingException
getNonMatchingHeaderLines in interface MimePartgetNonMatchingHeaderLines in class MimeBodyPartMessagingException
public void addHeader(String name,
String value)
throws MessagingException
addHeader in interface PartaddHeader in class MimeBodyPartMessagingException
public void setHeader(String name,
String value)
throws MessagingException
setHeader in interface PartsetHeader in class MimeBodyPartMessagingException
public void removeHeader(String name)
throws MessagingException
removeHeader in interface PartremoveHeader in class MimeBodyPartMessagingException
public void addHeaderLine(String line)
throws MessagingException
addHeaderLine in interface MimePartaddHeaderLine in class MimeBodyPartMessagingException
protected void loadHeaders()
throws MessagingException
MessagingException
protected void loadContent()
throws MessagingException
MessagingException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||