public class

IMAPNestedMessage

extends IMAPMessage
java.lang.Object
   ↳ com.google.code.javax.mail.Message
     ↳ com.google.code.javax.mail.internet.MimeMessage
       ↳ com.google.code.com.sun.mail.imap.IMAPMessage
         ↳ com.google.code.com.sun.mail.imap.IMAPNestedMessage

Class Overview

This class implements a nested IMAP message

Summary

[Expand]
Inherited Constants
From interface com.google.code.javax.mail.Part
Fields
private IMAPMessage msg
[Expand]
Inherited Fields
From class com.google.code.com.sun.mail.imap.IMAPMessage
From class com.google.code.javax.mail.internet.MimeMessage
From class com.google.code.javax.mail.Message
Public Methods
int getSize()
Get the message size.
boolean isExpunged()
Checks whether this message is expunged.
synchronized void setFlags(Flags flag, boolean set)
Set/Unset the given flags in this message.
Protected Methods
void checkExpunged()
int getFetchBlockSize()
Object getMessageCacheLock()
Get the messageCacheLock, associated with this Message's GmailFolder.
IMAPProtocol getProtocol()
Get this message's folder's protocol connection.
int getSequenceNumber()
Get this message's IMAP sequence number.
boolean isREV1()
[Expand]
Inherited Methods
From class com.google.code.com.sun.mail.imap.IMAPMessage
From class com.google.code.javax.mail.internet.MimeMessage
From class com.google.code.javax.mail.Message
From class java.lang.Object
From interface com.google.code.javax.mail.HasRawInputStream
From interface com.google.code.javax.mail.Part
From interface com.google.code.javax.mail.internet.MimePart

Fields

private IMAPMessage msg

Public Methods

public int getSize ()

Get the message size.

Note that this returns RFC822.SIZE. That is, it's the size of the whole message, header and body included.

Returns
  • size of content in bytes

public boolean isExpunged ()

Checks whether this message is expunged. All other methods except getMessageNumber() are invalid on an expunged Message object.

Messages that are expunged due to an explict expunge() request on the containing GmailFolder are removed from the GmailFolder immediately. Messages that are externally expunged by another source are marked "expunged" and return true for the isExpunged() method, but they are not removed from the GmailFolder until an explicit expunge() is done on the GmailFolder.

See the description of expunge() for more details on expunge handling.

public synchronized void setFlags (Flags flag, boolean set)

Set/Unset the given flags in this message.

Parameters
flag Flags object containing the flags to be set
set The value to be set

Protected Methods

protected void checkExpunged ()

protected int getFetchBlockSize ()

protected Object getMessageCacheLock ()

Get the messageCacheLock, associated with this Message's GmailFolder.

protected IMAPProtocol getProtocol ()

Get this message's folder's protocol connection. Throws FolderClosedException, if the protocol connection is not available. ASSERT: Must hold the messageCacheLock.

protected int getSequenceNumber ()

Get this message's IMAP sequence number. ASSERT: This method must be called only when holding the messageCacheLock.

protected boolean isREV1 ()