public class SimpleMessage<Id> extends AbstractMessage<Id>
| Constructor and Description |
|---|
SimpleMessage(Date internalDate,
int size,
int bodyStartOctet,
javax.mail.internet.SharedInputStream content,
javax.mail.Flags flags,
PropertyBuilder propertyBuilder,
Id mailboxId) |
SimpleMessage(Mailbox<Id> mailbox,
Message<Id> original) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
InputStream |
getBodyContent()
Gets the body content of the document.
|
protected int |
getBodyStartOctet()
Return the start octet of the body
|
long |
getFullContentOctets()
The number of octets contained in the full content of this document.
|
InputStream |
getHeaderContent()
Gets the header as
InputStream. |
Date |
getInternalDate() |
Id |
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
|
int |
hashCode() |
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 |
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()
Representation suitable for logging and debugging.
|
compareTo, createFlags, createUserFlags, getBodyOctets, getFullContentpublic SimpleMessage(Date internalDate, int size, int bodyStartOctet, javax.mail.internet.SharedInputStream content, javax.mail.Flags flags, PropertyBuilder propertyBuilder, Id mailboxId)
public SimpleMessage(Mailbox<Id> mailbox, Message<Id> original) throws MailboxException
MailboxExceptionpublic Date getInternalDate()
public Id getMailboxId()
Messagepublic long getUid()
Messagepublic boolean isAnswered()
Messagepublic boolean isDeleted()
Messagepublic boolean isDraft()
Messagepublic boolean isFlagged()
Messagepublic boolean isRecent()
Messagepublic boolean isSeen()
Messagepublic void setFlags(javax.mail.Flags flags)
Messagepublic InputStream getBodyContent() throws IOException
MessageInputStream
on every call, which basicly means it need to start at position 0IOExceptionpublic long getFullContentOctets()
Messagepublic String getMediaType()
Messagepublic List<Property> getProperties()
Messagepublic String getSubType()
Messagepublic Long getTextualLineCount()
Messagepublic String toString()
protected int getBodyStartOctet()
AbstractMessagegetBodyStartOctet in class AbstractMessage<Id>public long getModSeq()
MessageMessage.getModSeq()public void setModSeq(long modSeq)
MessageMessage.setModSeq(long)public void setUid(long uid)
MessageMessage.setUid(long)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.