org.apache.james.core
Class MimeMessageCopyOnWriteProxy
java.lang.Object
javax.mail.Message
javax.mail.internet.MimeMessage
org.apache.james.core.MimeMessageCopyOnWriteProxy
- All Implemented Interfaces:
- javax.mail.internet.MimePart, javax.mail.Part, org.apache.avalon.framework.activity.Disposable
public class MimeMessageCopyOnWriteProxy
- extends javax.mail.internet.MimeMessage
- implements org.apache.avalon.framework.activity.Disposable
This object wraps a "possibly shared" MimeMessage tracking copies and
automatically cloning it (if shared) when a write operation is invoked.
Nested classes/interfaces inherited from class javax.mail.internet.MimeMessage |
javax.mail.internet.MimeMessage.RecipientType |
Fields inherited from class javax.mail.internet.MimeMessage |
content, contentStream, dh, flags, headers, modified, saved |
Fields inherited from class javax.mail.Message |
expunged, folder, msgnum, session |
Fields inherited from interface javax.mail.Part |
ATTACHMENT, INLINE |
Method Summary |
void |
addFrom(javax.mail.Address[] addresses)
|
void |
addHeader(java.lang.String name,
java.lang.String value)
|
void |
addHeaderLine(java.lang.String line)
|
void |
addRecipient(javax.mail.internet.MimeMessage.RecipientType arg0,
javax.mail.Address arg1)
|
void |
addRecipients(javax.mail.Message.RecipientType type,
javax.mail.Address[] addresses)
|
void |
addRecipients(javax.mail.Message.RecipientType type,
java.lang.String addresses)
|
void |
dispose()
|
boolean |
equals(java.lang.Object arg0)
|
protected void |
finalize()
|
java.util.Enumeration |
getAllHeaderLines()
|
java.util.Enumeration |
getAllHeaders()
|
javax.mail.Address[] |
getAllRecipients()
|
java.lang.Object |
getContent()
|
java.lang.String |
getContentID()
|
java.lang.String[] |
getContentLanguage()
|
java.lang.String |
getContentMD5()
|
java.lang.String |
getContentType()
|
javax.activation.DataHandler |
getDataHandler()
|
java.lang.String |
getDescription()
|
java.lang.String |
getDisposition()
|
java.lang.String |
getEncoding()
|
java.lang.String |
getFileName()
|
javax.mail.Flags |
getFlags()
|
javax.mail.Folder |
getFolder()
|
javax.mail.Address[] |
getFrom()
|
java.lang.String[] |
getHeader(java.lang.String name)
|
java.lang.String |
getHeader(java.lang.String name,
java.lang.String delimiter)
|
java.io.InputStream |
getInputStream()
|
int |
getLineCount()
|
java.util.Enumeration |
getMatchingHeaderLines(java.lang.String[] names)
|
java.util.Enumeration |
getMatchingHeaders(java.lang.String[] names)
|
java.lang.String |
getMessageID()
|
int |
getMessageNumber()
|
long |
getMessageSize()
|
java.util.Enumeration |
getNonMatchingHeaderLines(java.lang.String[] names)
|
java.util.Enumeration |
getNonMatchingHeaders(java.lang.String[] names)
|
java.io.InputStream |
getRawInputStream()
|
java.util.Date |
getReceivedDate()
|
javax.mail.Address[] |
getRecipients(javax.mail.Message.RecipientType type)
|
javax.mail.Address[] |
getReplyTo()
|
javax.mail.Address |
getSender()
|
java.util.Date |
getSentDate()
|
int |
getSize()
|
java.lang.String |
getSubject()
|
javax.mail.internet.MimeMessage |
getWrappedMessage()
|
protected javax.mail.internet.MimeMessage |
getWrappedMessageForWriting()
Check the number of references over the MimeMessage and clone it if
needed before returning the reference |
int |
hashCode()
|
boolean |
isExpunged()
|
boolean |
isMimeType(java.lang.String mimeType)
|
boolean |
isSet(javax.mail.Flags.Flag flag)
|
boolean |
match(javax.mail.search.SearchTerm arg0)
|
void |
removeHeader(java.lang.String name)
|
javax.mail.Message |
reply(boolean replyToAll)
This does not need a writable message |
void |
saveChanges()
|
void |
setContent(javax.mail.Multipart mp)
|
void |
setContent(java.lang.Object o,
java.lang.String type)
|
void |
setContentID(java.lang.String cid)
|
void |
setContentLanguage(java.lang.String[] languages)
|
void |
setContentMD5(java.lang.String md5)
|
void |
setDataHandler(javax.activation.DataHandler dh)
|
void |
setDescription(java.lang.String description)
|
void |
setDescription(java.lang.String description,
java.lang.String charset)
|
void |
setDisposition(java.lang.String disposition)
|
void |
setFileName(java.lang.String filename)
|
void |
setFlag(javax.mail.Flags.Flag arg0,
boolean arg1)
|
void |
setFlags(javax.mail.Flags flag,
boolean set)
|
void |
setFrom()
|
void |
setFrom(javax.mail.Address address)
|
void |
setHeader(java.lang.String name,
java.lang.String value)
|
void |
setRecipients(javax.mail.Message.RecipientType type,
javax.mail.Address[] addresses)
|
void |
setRecipients(javax.mail.Message.RecipientType type,
java.lang.String addresses)
|
void |
setReplyTo(javax.mail.Address[] addresses)
|
void |
setSender(javax.mail.Address arg0)
|
void |
setSentDate(java.util.Date d)
|
void |
setSubject(java.lang.String subject)
|
void |
setSubject(java.lang.String subject,
java.lang.String charset)
|
void |
setText(java.lang.String text)
|
void |
setText(java.lang.String text,
java.lang.String charset)
|
java.lang.String |
toString()
|
void |
writeTo(java.io.OutputStream os)
Rewritten for optimization purposes |
void |
writeTo(java.io.OutputStream os,
java.lang.String[] ignoreList)
Rewritten for optimization purposes |
Methods inherited from class javax.mail.internet.MimeMessage |
createInternetHeaders, createMimeMessage, getContentStream, parse, setText, updateHeaders, updateMessageID |
Methods inherited from class javax.mail.Message |
addRecipient, setExpunged, setMessageNumber, setRecipient |
Methods inherited from class java.lang.Object |
clone, getClass, notify, notifyAll, wait, wait, wait |
refCount
protected MimeMessageCopyOnWriteProxy.MessageReferenceTracker refCount
MimeMessageCopyOnWriteProxy
public MimeMessageCopyOnWriteProxy(javax.mail.internet.MimeMessage original)
throws javax.mail.MessagingException
- Parameters:
original
- MimeMessageWrapper
- Throws:
javax.mail.MessagingException
MimeMessageCopyOnWriteProxy
public MimeMessageCopyOnWriteProxy(MimeMessageSource original)
throws javax.mail.MessagingException
- Parameters:
original
- MimeMessageSource
- Throws:
javax.mail.MessagingException
getWrappedMessageForWriting
protected javax.mail.internet.MimeMessage getWrappedMessageForWriting()
throws javax.mail.MessagingException
- Check the number of references over the MimeMessage and clone it if
needed before returning the reference
- Throws:
javax.mail.MessagingException
- exception
getWrappedMessage
public javax.mail.internet.MimeMessage getWrappedMessage()
- Returns:
dispose
public void dispose()
- Specified by:
dispose
in interface org.apache.avalon.framework.activity.Disposable
- See Also:
Disposable.dispose()
writeTo
public void writeTo(java.io.OutputStream os)
throws java.io.IOException,
javax.mail.MessagingException
- Rewritten for optimization purposes
- Specified by:
writeTo
in interface javax.mail.Part
- Overrides:
writeTo
in class javax.mail.internet.MimeMessage
- Throws:
java.io.IOException
javax.mail.MessagingException
writeTo
public void writeTo(java.io.OutputStream os,
java.lang.String[] ignoreList)
throws java.io.IOException,
javax.mail.MessagingException
- Rewritten for optimization purposes
- Overrides:
writeTo
in class javax.mail.internet.MimeMessage
- Throws:
java.io.IOException
javax.mail.MessagingException
getFrom
public javax.mail.Address[] getFrom()
throws javax.mail.MessagingException
- Overrides:
getFrom
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.getFrom()
getRecipients
public javax.mail.Address[] getRecipients(javax.mail.Message.RecipientType type)
throws javax.mail.MessagingException
- Overrides:
getRecipients
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.getRecipients(javax.mail.Message.RecipientType)
getAllRecipients
public javax.mail.Address[] getAllRecipients()
throws javax.mail.MessagingException
- Overrides:
getAllRecipients
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.getAllRecipients()
getReplyTo
public javax.mail.Address[] getReplyTo()
throws javax.mail.MessagingException
- Overrides:
getReplyTo
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.getReplyTo()
getSubject
public java.lang.String getSubject()
throws javax.mail.MessagingException
- Overrides:
getSubject
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.getSubject()
getSentDate
public java.util.Date getSentDate()
throws javax.mail.MessagingException
- Overrides:
getSentDate
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.getSentDate()
getReceivedDate
public java.util.Date getReceivedDate()
throws javax.mail.MessagingException
- Overrides:
getReceivedDate
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.getReceivedDate()
getSize
public int getSize()
throws javax.mail.MessagingException
- Specified by:
getSize
in interface javax.mail.Part
- Overrides:
getSize
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getSize()
getLineCount
public int getLineCount()
throws javax.mail.MessagingException
- Specified by:
getLineCount
in interface javax.mail.Part
- Overrides:
getLineCount
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getLineCount()
getContentType
public java.lang.String getContentType()
throws javax.mail.MessagingException
- Specified by:
getContentType
in interface javax.mail.Part
- Overrides:
getContentType
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getContentType()
isMimeType
public boolean isMimeType(java.lang.String mimeType)
throws javax.mail.MessagingException
- Specified by:
isMimeType
in interface javax.mail.Part
- Overrides:
isMimeType
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.isMimeType(java.lang.String)
getDisposition
public java.lang.String getDisposition()
throws javax.mail.MessagingException
- Specified by:
getDisposition
in interface javax.mail.Part
- Overrides:
getDisposition
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getDisposition()
getEncoding
public java.lang.String getEncoding()
throws javax.mail.MessagingException
- Specified by:
getEncoding
in interface javax.mail.internet.MimePart
- Overrides:
getEncoding
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.getEncoding()
getContentID
public java.lang.String getContentID()
throws javax.mail.MessagingException
- Specified by:
getContentID
in interface javax.mail.internet.MimePart
- Overrides:
getContentID
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.getContentID()
getContentMD5
public java.lang.String getContentMD5()
throws javax.mail.MessagingException
- Specified by:
getContentMD5
in interface javax.mail.internet.MimePart
- Overrides:
getContentMD5
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.getContentMD5()
getDescription
public java.lang.String getDescription()
throws javax.mail.MessagingException
- Specified by:
getDescription
in interface javax.mail.Part
- Overrides:
getDescription
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getDescription()
getContentLanguage
public java.lang.String[] getContentLanguage()
throws javax.mail.MessagingException
- Specified by:
getContentLanguage
in interface javax.mail.internet.MimePart
- Overrides:
getContentLanguage
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.getContentLanguage()
getMessageID
public java.lang.String getMessageID()
throws javax.mail.MessagingException
- Overrides:
getMessageID
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimeMessage.getMessageID()
getFileName
public java.lang.String getFileName()
throws javax.mail.MessagingException
- Specified by:
getFileName
in interface javax.mail.Part
- Overrides:
getFileName
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getFileName()
getInputStream
public java.io.InputStream getInputStream()
throws java.io.IOException,
javax.mail.MessagingException
- Specified by:
getInputStream
in interface javax.mail.Part
- Overrides:
getInputStream
in class javax.mail.internet.MimeMessage
- Throws:
java.io.IOException
javax.mail.MessagingException
- See Also:
Part.getInputStream()
getDataHandler
public javax.activation.DataHandler getDataHandler()
throws javax.mail.MessagingException
- Specified by:
getDataHandler
in interface javax.mail.Part
- Overrides:
getDataHandler
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getDataHandler()
getContent
public java.lang.Object getContent()
throws java.io.IOException,
javax.mail.MessagingException
- Specified by:
getContent
in interface javax.mail.Part
- Overrides:
getContent
in class javax.mail.internet.MimeMessage
- Throws:
java.io.IOException
javax.mail.MessagingException
- See Also:
Part.getContent()
getHeader
public java.lang.String[] getHeader(java.lang.String name)
throws javax.mail.MessagingException
- Specified by:
getHeader
in interface javax.mail.Part
- Overrides:
getHeader
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getHeader(java.lang.String)
getHeader
public java.lang.String getHeader(java.lang.String name,
java.lang.String delimiter)
throws javax.mail.MessagingException
- Specified by:
getHeader
in interface javax.mail.internet.MimePart
- Overrides:
getHeader
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.getHeader(java.lang.String, java.lang.String)
getAllHeaders
public java.util.Enumeration getAllHeaders()
throws javax.mail.MessagingException
- Specified by:
getAllHeaders
in interface javax.mail.Part
- Overrides:
getAllHeaders
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getAllHeaders()
getMatchingHeaders
public java.util.Enumeration getMatchingHeaders(java.lang.String[] names)
throws javax.mail.MessagingException
- Specified by:
getMatchingHeaders
in interface javax.mail.Part
- Overrides:
getMatchingHeaders
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getMatchingHeaders(java.lang.String[])
getNonMatchingHeaders
public java.util.Enumeration getNonMatchingHeaders(java.lang.String[] names)
throws javax.mail.MessagingException
- Specified by:
getNonMatchingHeaders
in interface javax.mail.Part
- Overrides:
getNonMatchingHeaders
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.getNonMatchingHeaders(java.lang.String[])
getAllHeaderLines
public java.util.Enumeration getAllHeaderLines()
throws javax.mail.MessagingException
- Specified by:
getAllHeaderLines
in interface javax.mail.internet.MimePart
- Overrides:
getAllHeaderLines
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.getAllHeaderLines()
getMatchingHeaderLines
public java.util.Enumeration getMatchingHeaderLines(java.lang.String[] names)
throws javax.mail.MessagingException
- Specified by:
getMatchingHeaderLines
in interface javax.mail.internet.MimePart
- Overrides:
getMatchingHeaderLines
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.getMatchingHeaderLines(java.lang.String[])
getNonMatchingHeaderLines
public java.util.Enumeration getNonMatchingHeaderLines(java.lang.String[] names)
throws javax.mail.MessagingException
- Specified by:
getNonMatchingHeaderLines
in interface javax.mail.internet.MimePart
- Overrides:
getNonMatchingHeaderLines
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.getNonMatchingHeaderLines(java.lang.String[])
getFlags
public javax.mail.Flags getFlags()
throws javax.mail.MessagingException
- Overrides:
getFlags
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.getFlags()
isSet
public boolean isSet(javax.mail.Flags.Flag flag)
throws javax.mail.MessagingException
- Overrides:
isSet
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.isSet(javax.mail.Flags.Flag)
getSender
public javax.mail.Address getSender()
throws javax.mail.MessagingException
- Overrides:
getSender
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimeMessage.getSender()
match
public boolean match(javax.mail.search.SearchTerm arg0)
throws javax.mail.MessagingException
- Overrides:
match
in class javax.mail.Message
- Throws:
javax.mail.MessagingException
- See Also:
Message.match(javax.mail.search.SearchTerm)
getRawInputStream
public java.io.InputStream getRawInputStream()
throws javax.mail.MessagingException
- Overrides:
getRawInputStream
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimeMessage.getRawInputStream()
getFolder
public javax.mail.Folder getFolder()
- Overrides:
getFolder
in class javax.mail.Message
- See Also:
Message.getFolder()
getMessageNumber
public int getMessageNumber()
- Overrides:
getMessageNumber
in class javax.mail.Message
- See Also:
Message.getMessageNumber()
isExpunged
public boolean isExpunged()
- Overrides:
isExpunged
in class javax.mail.Message
- See Also:
Message.isExpunged()
equals
public boolean equals(java.lang.Object arg0)
- Overrides:
equals
in class java.lang.Object
- See Also:
Object.equals(java.lang.Object)
hashCode
public int hashCode()
- Overrides:
hashCode
in class java.lang.Object
- See Also:
Object.hashCode()
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
- See Also:
Object.toString()
setFrom
public void setFrom(javax.mail.Address address)
throws javax.mail.MessagingException
- Overrides:
setFrom
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.setFrom(javax.mail.Address)
setFrom
public void setFrom()
throws javax.mail.MessagingException
- Overrides:
setFrom
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.setFrom()
addFrom
public void addFrom(javax.mail.Address[] addresses)
throws javax.mail.MessagingException
- Overrides:
addFrom
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.addFrom(javax.mail.Address[])
setRecipients
public void setRecipients(javax.mail.Message.RecipientType type,
javax.mail.Address[] addresses)
throws javax.mail.MessagingException
- Overrides:
setRecipients
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.setRecipients(javax.mail.Message.RecipientType, javax.mail.Address[])
addRecipients
public void addRecipients(javax.mail.Message.RecipientType type,
javax.mail.Address[] addresses)
throws javax.mail.MessagingException
- Overrides:
addRecipients
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.addRecipients(javax.mail.Message.RecipientType, javax.mail.Address[])
setReplyTo
public void setReplyTo(javax.mail.Address[] addresses)
throws javax.mail.MessagingException
- Overrides:
setReplyTo
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.setReplyTo(javax.mail.Address[])
setSubject
public void setSubject(java.lang.String subject)
throws javax.mail.MessagingException
- Overrides:
setSubject
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.setSubject(java.lang.String)
setSubject
public void setSubject(java.lang.String subject,
java.lang.String charset)
throws javax.mail.MessagingException
- Overrides:
setSubject
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimeMessage.setSubject(java.lang.String, java.lang.String)
setSentDate
public void setSentDate(java.util.Date d)
throws javax.mail.MessagingException
- Overrides:
setSentDate
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.setSentDate(java.util.Date)
setDisposition
public void setDisposition(java.lang.String disposition)
throws javax.mail.MessagingException
- Specified by:
setDisposition
in interface javax.mail.Part
- Overrides:
setDisposition
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.setDisposition(java.lang.String)
setContentID
public void setContentID(java.lang.String cid)
throws javax.mail.MessagingException
- Overrides:
setContentID
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimeMessage.setContentID(java.lang.String)
setContentMD5
public void setContentMD5(java.lang.String md5)
throws javax.mail.MessagingException
- Specified by:
setContentMD5
in interface javax.mail.internet.MimePart
- Overrides:
setContentMD5
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.setContentMD5(java.lang.String)
setDescription
public void setDescription(java.lang.String description)
throws javax.mail.MessagingException
- Specified by:
setDescription
in interface javax.mail.Part
- Overrides:
setDescription
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.setDescription(java.lang.String)
setDescription
public void setDescription(java.lang.String description,
java.lang.String charset)
throws javax.mail.MessagingException
- Overrides:
setDescription
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimeMessage.setDescription(java.lang.String, java.lang.String)
setContentLanguage
public void setContentLanguage(java.lang.String[] languages)
throws javax.mail.MessagingException
- Specified by:
setContentLanguage
in interface javax.mail.internet.MimePart
- Overrides:
setContentLanguage
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.setContentLanguage(java.lang.String[])
setFileName
public void setFileName(java.lang.String filename)
throws javax.mail.MessagingException
- Specified by:
setFileName
in interface javax.mail.Part
- Overrides:
setFileName
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.setFileName(java.lang.String)
setDataHandler
public void setDataHandler(javax.activation.DataHandler dh)
throws javax.mail.MessagingException
- Specified by:
setDataHandler
in interface javax.mail.Part
- Overrides:
setDataHandler
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.setDataHandler(javax.activation.DataHandler)
setContent
public void setContent(java.lang.Object o,
java.lang.String type)
throws javax.mail.MessagingException
- Specified by:
setContent
in interface javax.mail.Part
- Overrides:
setContent
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.setContent(java.lang.Object, java.lang.String)
setText
public void setText(java.lang.String text)
throws javax.mail.MessagingException
- Specified by:
setText
in interface javax.mail.internet.MimePart
- Specified by:
setText
in interface javax.mail.Part
- Overrides:
setText
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.setText(java.lang.String)
setText
public void setText(java.lang.String text,
java.lang.String charset)
throws javax.mail.MessagingException
- Specified by:
setText
in interface javax.mail.internet.MimePart
- Overrides:
setText
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.setText(java.lang.String, java.lang.String)
setContent
public void setContent(javax.mail.Multipart mp)
throws javax.mail.MessagingException
- Specified by:
setContent
in interface javax.mail.Part
- Overrides:
setContent
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.setContent(javax.mail.Multipart)
reply
public javax.mail.Message reply(boolean replyToAll)
throws javax.mail.MessagingException
- This does not need a writable message
- Overrides:
reply
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.reply(boolean)
setHeader
public void setHeader(java.lang.String name,
java.lang.String value)
throws javax.mail.MessagingException
- Specified by:
setHeader
in interface javax.mail.Part
- Overrides:
setHeader
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.setHeader(java.lang.String, java.lang.String)
addHeader
public void addHeader(java.lang.String name,
java.lang.String value)
throws javax.mail.MessagingException
- Specified by:
addHeader
in interface javax.mail.Part
- Overrides:
addHeader
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.addHeader(java.lang.String, java.lang.String)
removeHeader
public void removeHeader(java.lang.String name)
throws javax.mail.MessagingException
- Specified by:
removeHeader
in interface javax.mail.Part
- Overrides:
removeHeader
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Part.removeHeader(java.lang.String)
addHeaderLine
public void addHeaderLine(java.lang.String line)
throws javax.mail.MessagingException
- Specified by:
addHeaderLine
in interface javax.mail.internet.MimePart
- Overrides:
addHeaderLine
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimePart.addHeaderLine(java.lang.String)
setFlags
public void setFlags(javax.mail.Flags flag,
boolean set)
throws javax.mail.MessagingException
- Overrides:
setFlags
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.setFlags(javax.mail.Flags, boolean)
saveChanges
public void saveChanges()
throws javax.mail.MessagingException
- Overrides:
saveChanges
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
Message.saveChanges()
addRecipients
public void addRecipients(javax.mail.Message.RecipientType type,
java.lang.String addresses)
throws javax.mail.MessagingException
- Overrides:
addRecipients
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimeMessage.addRecipients(javax.mail.Message.RecipientType, java.lang.String)
setRecipients
public void setRecipients(javax.mail.Message.RecipientType type,
java.lang.String addresses)
throws javax.mail.MessagingException
- Overrides:
setRecipients
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimeMessage.setRecipients(javax.mail.Message.RecipientType, java.lang.String)
setSender
public void setSender(javax.mail.Address arg0)
throws javax.mail.MessagingException
- Overrides:
setSender
in class javax.mail.internet.MimeMessage
- Throws:
javax.mail.MessagingException
- See Also:
MimeMessage.setSender(javax.mail.Address)
addRecipient
public void addRecipient(javax.mail.internet.MimeMessage.RecipientType arg0,
javax.mail.Address arg1)
throws javax.mail.MessagingException
- Throws:
javax.mail.MessagingException
- See Also:
Message.addRecipient(javax.mail.Message.RecipientType, javax.mail.Address)
setFlag
public void setFlag(javax.mail.Flags.Flag arg0,
boolean arg1)
throws javax.mail.MessagingException
- Overrides:
setFlag
in class javax.mail.Message
- Throws:
javax.mail.MessagingException
- See Also:
Message.setFlag(javax.mail.Flags.Flag, boolean)
finalize
protected void finalize()
throws java.lang.Throwable
- Overrides:
finalize
in class java.lang.Object
- Throws:
java.lang.Throwable
- See Also:
Object.finalize()
getMessageSize
public long getMessageSize()
throws javax.mail.MessagingException
- Returns:
- the message size
- Throws:
javax.mail.MessagingException
Copyright © 2002-2007 The Apache Software Foundation. All Rights Reserved.