All Packages This Package Class Hierarchy Class Search Index
Class grendel.storage.MessageReadOnly
java.lang.Object | +----javax.mail.Message | +----grendel.storage.MessageReadOnly
This implements those methods on Message which are commonly used in all of our read-only message implementations. It also provides an implementation for the header-reading routines, all of which assume that the subclass implements getHeadersObj, a method to get an InternetHeaders object for this message.
abstract class MessageReadOnly extends javax.mail.Message { // Constructors 2 MessageReadOnly(); MessageReadOnly(Folder, int); // Methods 38 public void addFrom(Address[]) throws MessagingException; public void addHeader(String, String) throws MessagingException; public void addRecipients(RecipientType, Address[]) throws MessagingException; public Enumeration getAllHeaders(); public String getContentType(); public String getDescription(); public String getDisposition(); public String getFileName(); public Address[] getFrom() throws MessagingException; public String[] getHeader(String) throws MessagingException; protected abstract InternetHeaders getHeadersObj() throws MessagingException; public InputStream getInputStream() throws MessagingException; public InputStream getInputStreamWithHeaders() throws MessagingException; public Enumeration getMatchingHeaders(String[]); public Enumeration getNonMatchingHeaders(String[]); protected String getOneHeader(String) throws MessagingException; public Address[] getRecipients(RecipientType) throws MessagingException; public Date getSentDate() throws MessagingException; public long getSentDateAsLong(); public String getSubject() throws MessagingException; public boolean isMimeType(String); protected void readonly() throws MessagingException; public void removeHeader(String) throws MessagingException; public Message reply(boolean); public void setContent(Object, String); public void setContent(String) throws MessagingException; public void setContent(Multipart); public void setDataHandler(DataHandler); public void setDescription(String) throws MessagingException; public void setDisposition(String) throws MessagingException; public void setFileName(String) throws MessagingException; public void setFrom() throws MessagingException; public void setFrom(Address) throws MessagingException; public void setHeader(String, String) throws MessagingException; public void setRecipients(RecipientType, Address[]) throws MessagingException; public void setSentDate(Date) throws MessagingException; public void setSubject(String) throws MessagingException; public void setText(String) throws MessagingException; }
Constructors
MessageReadOnly
MessageReadOnly()
MessageReadOnly
MessageReadOnly(Folder f, int num)
Methods
readonly
protected void readonly() throws MessagingException
addFrom
public void addFrom(Address[] addresses) throws MessagingException
setSubject
public void setSubject(String s) throws MessagingException
- Overrides:
- setSubject in class Message
setRecipients
public void setRecipients(RecipientType type, Address[] addresses) throws MessagingException
addRecipients
public void addRecipients(RecipientType type, Address[] addresses) throws MessagingException
setFrom
public void setFrom() throws MessagingException
setFrom
public void setFrom(Address address) throws MessagingException
setSentDate
public void setSentDate(Date d) throws MessagingException
- Overrides:
- setSentDate in class Message
getContentType
public String getContentType()
- Overrides:
- getContentType in class Message
getDisposition
public String getDisposition()
- Overrides:
- getDisposition in class Message
getDescription
public String getDescription()
- Overrides:
- getDescription in class Message
getFileName
public String getFileName()
- Overrides:
- getFileName in class Message
setDisposition
public void setDisposition(String d) throws MessagingException
- Overrides:
- setDisposition in class Message
setDescription
public void setDescription(String d) throws MessagingException
- Overrides:
- setDescription in class Message
setFileName
public void setFileName(String f) throws MessagingException
- Overrides:
- setFileName in class Message
setDataHandler
public void setDataHandler(DataHandler d)
- Overrides:
- setDataHandler in class Message
setText
public void setText(String s) throws MessagingException
setContent
public void setContent(String s) throws MessagingException
setContent
public void setContent(Object o, String s)
- Overrides:
- setContent in class Message
setContent
public void setContent(Multipart m)
- Overrides:
- setContent in class Message
addHeader
public void addHeader(String s1, String s2) throws MessagingException
setHeader
public void setHeader(String s1, String s2) throws MessagingException
removeHeader
public void removeHeader(String s) throws MessagingException
- Overrides:
- removeHeader in class Message
getHeadersObj
protected abstract InternetHeaders getHeadersObj() throws MessagingException
Get the InternetHeaders object.
getHeader
public String[] getHeader(String name) throws MessagingException
getOneHeader
protected String getOneHeader(String name) throws MessagingException
getRecipients
public Address[] getRecipients(RecipientType type) throws MessagingException
getFrom
public Address[] getFrom() throws MessagingException
getSentDate
public Date getSentDate() throws MessagingException
- Overrides:
- getSentDate in class Message
getSentDateAsLong
public long getSentDateAsLong()
getSubject
public String getSubject() throws MessagingException
- Overrides:
- getSubject in class Message
getAllHeaders
public Enumeration getAllHeaders()
- Overrides:
- getAllHeaders in class Message
getMatchingHeaders
public Enumeration getMatchingHeaders(String[] s)
- Overrides:
- getMatchingHeaders in class Message
getNonMatchingHeaders
public Enumeration getNonMatchingHeaders(String[] s)
- Overrides:
- getNonMatchingHeaders in class Message
reply
public Message reply(boolean replyToAll)
isMimeType
public boolean isMimeType(String mimeType)
- Overrides:
- isMimeType in class Message
getInputStream
public InputStream getInputStream() throws MessagingException
This default implementation of getInputStream() works in terms of getInputStreamWithHeaders. Subclasses are encouraged to define this more directly if they have an easy way of doing so.
- Overrides:
- getInputStream in class Message
getInputStreamWithHeaders
public InputStream getInputStreamWithHeaders() throws MessagingException
All Packages This Package Class Hierarchy Class Search IndexFreshly brewed Java API Documentation automatically generated with polardoc Version 1.0.4