lib 1400087 // gimap import com.google.code.javax.mail.*; import com.google.code.javax.mail.internet.*; import com.google.code.com.sun.mail.imap.*; static Folder googleCode_gmail_folder(S folderName) { ret googleCode_gmail_folder(folderName, gmailDefaultUser()); } static Folder googleCode_gmail_folder(S folderName, S user) { ret googleCode_gmail_folder(folderName, user, findGMailPassword(user)); } static Folder googleCode_gmail_folder(S folderName, S user, S pass) ctex { new Properties props; props.setProperty("mail.store.protocol", "imaps"); Session session = Session.getInstance(props, null); URLName urlName = new URLName("imap.gmail.com"); IMAPSSLStore store = new IMAPSSLStore(session, urlName); store.connect("imap.gmail.com", user, pass); ret store.getFolder(folderName); }