Package org.ujmp.mail

Class ImapUtil

  • All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable

    public class ImapUtil
    extends java.lang.Object
    implements java.io.Closeable
    • Constructor Detail

      • ImapUtil

        public ImapUtil​(java.lang.String host,
                        java.lang.String user,
                        java.lang.String password)
    • Method Detail

      • getPersonalFolders

        public ListMatrix<javax.mail.Folder> getPersonalFolders()
                                                         throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getSubFolders

        public ListMatrix<javax.mail.Folder> getSubFolders​(javax.mail.Folder folder)
                                                    throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getMessages

        public MessagesMatrix getMessages​(java.lang.String folderName)
                                   throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getFolder

        public javax.mail.Folder getFolder​(java.lang.String folderName)
                                    throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getSubFolders

        public ListMatrix<javax.mail.Folder> getSubFolders​(java.lang.String folderName)
                                                    throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getMessages

        public MessagesMatrix getMessages​(javax.mail.Folder folder)
                                   throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getStore

        private javax.mail.Store getStore()
                                   throws java.lang.Exception
        Throws:
        java.lang.Exception
      • close

        public void close()
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface java.io.Closeable
      • getSharedFolders

        public ListMatrix<javax.mail.Folder> getSharedFolders()
                                                       throws java.lang.Exception
        Throws:
        java.lang.Exception