public class MaildirMessage extends AbstractMessage<Integer>
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
newMessage |
| Constructor and Description |
|---|
MaildirMessage(Mailbox<Integer> mailbox,
long uid,
MaildirMessageName messageName) |
| Modifier and Type | Method and Description |
|---|---|
InputStream |
getBodyContent()
Gets the body content of the document.
|
protected int |
getBodyStartOctet()
Return the start octet of the body
|
InputStream |
getFullContent()
Return the full content of the message via a
FileInputStream |
long |
getFullContentOctets()
The number of octets contained in the full content of this document.
|
InputStream |
getHeaderContent()
Gets the header as
InputStream. |
Date |
getInternalDate() |
Integer |
getMailboxId()
Return the mailbox id of the linked mailbox
|
String |
getMediaType()
Gets the top level MIME content media type.
|
long |
getModSeq()
Return the mod-sequence for the message
|
List<Property> |
getProperties()
Gets a read-only list of meta-data properties.
|
String |
getSubType()
Gets the MIME content subtype.
|
Long |
getTextualLineCount()
Gets the number of CRLF in a textual document.
|
long |
getUid()
Return the uid
|
boolean |
isAnswered()
Return if it was marked as answered
|
boolean |
isDeleted()
Return if it was mark as deleted
|
boolean |
isDraft()
Return if it was mark as draft
|
boolean |
isFlagged()
Return if it was flagged
|
boolean |
isNew()
Indicates whether this MaildirMessage reflects a new message or one that already
exists in the file system.
|
boolean |
isRecent()
Return if it was marked as recent
|
boolean |
isSeen()
Return if it was marked as seen
|
void |
setFlags(javax.mail.Flags flags)
Set the Flags
|
void |
setModSeq(long modSeq)
Set the mod-sequence for the message.
|
void |
setUid(long uid)
Set the uid for the message.
|
String |
toString() |
compareTo, createFlags, createUserFlags, getBodyOctetspublic MaildirMessage(Mailbox<Integer> mailbox, long uid, MaildirMessageName messageName) throws IOException
IOExceptionpublic Integer getMailboxId()
Messagepublic long getUid()
Messagepublic void setUid(long uid)
Messagepublic void setFlags(javax.mail.Flags flags)
MessageMessage.setFlags(
javax.mail.Flags)public boolean isAnswered()
MessageMessage.isAnswered()public boolean isDeleted()
MessageMessage.isDeleted()public boolean isDraft()
MessageMessage.isDraft()public boolean isFlagged()
MessageMessage.isFlagged()public boolean isRecent()
MessageMessage.isRecent()public boolean isSeen()
MessageMessage.isSeen()public boolean isNew()
public long getModSeq()
MessageMessage.getModSeq()public void setModSeq(long modSeq)
MessageMessage.setModSeq(long)public String getMediaType()
MessageMessage.getMediaType()public String getSubType()
MessageMessage.getSubType()public long getFullContentOctets()
MessageMessage.getFullContentOctets()public Long getTextualLineCount()
MessageMessage.getTextualLineCount()public List<Property> getProperties()
MessageMessage.getProperties()public Date getInternalDate()
Message.getInternalDate()public InputStream getFullContent() throws IOException
FileInputStreamgetFullContent in interface Message<Integer>getFullContent in class AbstractMessage<Integer>IOExceptionpublic InputStream getBodyContent() throws IOException
MessageInputStream
on every call, which basicly means it need to start at position 0IOExceptionMessage.getBodyContent()protected int getBodyStartOctet()
AbstractMessagegetBodyStartOctet in class AbstractMessage<Integer>AbstractMessage.getBodyStartOctet()public InputStream getHeaderContent() throws IOException
MessageInputStream. This MUST INCLUDE the CRLF terminator
Be aware that this method need to return a new fresh InputStream
on every callIOExceptionCopyright © 2010-2012 The Apache Software Foundation. All Rights Reserved.