Class FetchedMail

java.lang.Object
com.codename1.backend.mail.FetchedMail

public final class FetchedMail extends Object

A message a MailReceiver fetched: its uid, which MailReceiver.markSeen(String) and MailReceiver.delete(String) take, and the parsed message.

A message the receiver would not read -- one larger than cn1.mail.store.maxMessageSize -- is still listed, with a null getMessage() and the reason in getSkipped(), so that one oversized message neither hides the rest of the folder nor goes unnoticed. Its uid works with MailReceiver.delete(String) like any other.

  • Constructor Details

    • FetchedMail

      public FetchedMail(String uid, ReceivedMessage message)
      A message under the uid the server gave it.
    • FetchedMail

      public FetchedMail(String uid, ReceivedMessage message, String skipped)
      A message under the uid the server gave it, or, when skipped is not null, one that was not read for that reason and has no message.
  • Method Details

    • getSkipped

      public String getSkipped()
      Why the message was not read, or null when getMessage() holds it.
    • isSkipped

      public boolean isSkipped()
      True when the message was not read; see getSkipped().
    • getUid

      public String getUid()
      The uid the server gave the message: the IMAP UID, or the POP3 UIDL.
    • getMessage

      public ReceivedMessage getMessage()
      The message, parsed by MimeParser, or null when it was skipped.