Class MStorFolder

  • All Implemented Interfaces:
    AutoCloseable, javax.mail.UIDFolder

    public final class MStorFolder
    extends javax.mail.Folder
    implements javax.mail.UIDFolder
    A folder implementation for the mstor javamail provider.
    • Nested Class Summary

      • Nested classes/interfaces inherited from interface javax.mail.UIDFolder

        javax.mail.UIDFolder.FetchProfileItem
    • Field Summary

      • Fields inherited from class javax.mail.Folder

        HOLDS_FOLDERS, HOLDS_MESSAGES, mode, READ_ONLY, READ_WRITE, store
      • Fields inherited from interface javax.mail.UIDFolder

        LASTUID, MAXUID
    • Constructor Detail

      • MStorFolder

        public MStorFolder​(MStorStore store,
                           FolderDelegate<? extends MessageDelegate> delegate)
        Constructs a new mstor folder instance.
        Parameters:
        store - the mail store this folder belongs to
        delegate - a folder delegate that provides implementation-specific folder functionality
    • Method Detail

      • getName

        public String getName()
        Specified by:
        getName in class javax.mail.Folder
      • getFullName

        public String getFullName()
        Specified by:
        getFullName in class javax.mail.Folder
      • getParent

        public javax.mail.Folder getParent()
        Specified by:
        getParent in class javax.mail.Folder
      • exists

        public boolean exists()
        Specified by:
        exists in class javax.mail.Folder
      • list

        public javax.mail.Folder[] list​(String pattern)
                                 throws javax.mail.MessagingException
        Specified by:
        list in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • getSeparator

        public char getSeparator()
                          throws javax.mail.MessagingException
        Specified by:
        getSeparator in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • getType

        public int getType()
                    throws javax.mail.MessagingException
        Specified by:
        getType in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • create

        public boolean create​(int type)
                       throws javax.mail.MessagingException
        Specified by:
        create in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • hasNewMessages

        public boolean hasNewMessages()
        Specified by:
        hasNewMessages in class javax.mail.Folder
      • getFolder

        public javax.mail.Folder getFolder​(String name)
                                    throws javax.mail.MessagingException
        Specified by:
        getFolder in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • delete

        public boolean delete​(boolean recurse)
                       throws javax.mail.MessagingException
        Specified by:
        delete in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • renameTo

        public boolean renameTo​(javax.mail.Folder folder)
                         throws javax.mail.MessagingException
        Specified by:
        renameTo in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • open

        public void open​(int mode)
                  throws javax.mail.MessagingException
        Specified by:
        open in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • close

        public void close​(boolean expunge)
                   throws javax.mail.MessagingException
        Specified by:
        close in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • isOpen

        public boolean isOpen()
        Specified by:
        isOpen in class javax.mail.Folder
      • getPermanentFlags

        public javax.mail.Flags getPermanentFlags()
        Specified by:
        getPermanentFlags in class javax.mail.Folder
      • getMessageCount

        public int getMessageCount()
                            throws javax.mail.MessagingException
        Specified by:
        getMessageCount in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • getDeletedMessageCount

        public int getDeletedMessageCount()
                                   throws javax.mail.MessagingException
        Overrides:
        getDeletedMessageCount in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • getMessage

        public javax.mail.Message getMessage​(int index)
                                      throws javax.mail.MessagingException
        Specified by:
        getMessage in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • appendMessages

        public void appendMessages​(javax.mail.Message[] messages)
                            throws javax.mail.MessagingException
        Appends the specified messages to this folder. NOTE: The specified message array is destroyed upon processing to alleviate memory concerns with large messages. You should ensure the messages specified in this array are referenced elsewhere if you want to retain them.
        Specified by:
        appendMessages in class javax.mail.Folder
        Parameters:
        messages - an array of messages to append to the folder
        Throws:
        javax.mail.MessagingException - where an unexpected error occurs appending messages to the folder
      • expunge

        public javax.mail.Message[] expunge()
                                     throws javax.mail.MessagingException
        Specified by:
        expunge in class javax.mail.Folder
        Throws:
        javax.mail.MessagingException
      • getMessageByUID

        public javax.mail.Message getMessageByUID​(long uid)
                                           throws javax.mail.MessagingException
        Specified by:
        getMessageByUID in interface javax.mail.UIDFolder
        Throws:
        javax.mail.MessagingException
      • getMessagesByUID

        public javax.mail.Message[] getMessagesByUID​(long start,
                                                     long end)
                                              throws javax.mail.MessagingException
        Specified by:
        getMessagesByUID in interface javax.mail.UIDFolder
        Throws:
        javax.mail.MessagingException
      • getMessagesByUID

        public javax.mail.Message[] getMessagesByUID​(long[] uids)
                                              throws javax.mail.MessagingException
        Specified by:
        getMessagesByUID in interface javax.mail.UIDFolder
        Throws:
        javax.mail.MessagingException
      • getUID

        public long getUID​(javax.mail.Message message)
                    throws javax.mail.MessagingException
        Specified by:
        getUID in interface javax.mail.UIDFolder
        Throws:
        javax.mail.MessagingException
      • getUIDNext

        public long getUIDNext()
        Specified by:
        getUIDNext in interface javax.mail.UIDFolder
      • getUIDValidity

        public long getUIDValidity()
                            throws javax.mail.MessagingException
        Specified by:
        getUIDValidity in interface javax.mail.UIDFolder
        Throws:
        javax.mail.MessagingException