Package i2p.susi.webmail
Class Draft
- java.lang.Object
-
- i2p.susi.webmail.Mail
-
- i2p.susi.webmail.Draft
-
class Draft extends Mail
Holds a draft message and reference to attachments, if any Differences from Mail: - Never multipart, body is always text/plain UTF-8 - Attachments are just headers containing name, type, encoding, and path to file - Bcc is a header- Since:
- 0.9.35
-
-
Field Summary
Fields Modifier and Type Field Description static String
HDR_BCC
-
Fields inherited from class i2p.susi.webmail.Mail
cc, contentType, date, dateString, error, formattedDate, HEADER_MATCH, localFormattedDate, markForDeletion, messageID, quotedDate, reply, sender, shortSender, shortSubject, subject, to, uidl
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
addAttachment(Attachment a)
void
clearAttachments()
StringBuilder
encodeAttachments()
List<Attachment>
getAttachments()
String[]
getBcc()
boolean
hasAttachment()
void
removeAttachment(int index)
void
setBody(Buffer rb)
Overridden to process attachment and Bcc headers-
Methods inherited from class i2p.susi.webmail.Mail
appendRecipients, appendRecipients, getAddress, getBody, getHeader, getPart, getRecipientsFromList, getRecipientsFromList, getSize, hasBody, hasHeader, hasPart, isNew, isSpam, setHeader, setNew, setSize, validateAddress
-
-
-
-
Field Detail
-
HDR_BCC
public static final String HDR_BCC
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
Draft
public Draft(String uidl)
-
-
Method Detail
-
setBody
public void setBody(Buffer rb)
Overridden to process attachment and Bcc headers
-
hasAttachment
public boolean hasAttachment()
- Overrides:
hasAttachment
in classMail
-
getBcc
public String[] getBcc()
- Returns:
- may be null
-
getAttachments
public List<Attachment> getAttachments()
- Returns:
- non-null, not a copy
-
addAttachment
public int addAttachment(Attachment a)
-
removeAttachment
public void removeAttachment(int index)
-
clearAttachments
public void clearAttachments()
-
encodeAttachments
public StringBuilder encodeAttachments()
-
-