JavaMail Section Index | Page 3
JSR 919, http://jcp.org/en/jsr/detail?id=919 includes the information on the API changes for this release.
Until now, no. Support is coming in the 1.4.1 release of JavaMail. You can try out an early access version at https://maven-repository.dev.java.net/nonav/repository/javax.mail/.more
How you can know that two parts in an email (typically a text/plain and text/html) are the same thing?
The parts will be contained in a multipart/alternative.
Short answer: You can't. Longer answer: You can discover all the multipart messages without calling getBodyPart(), but you can't tell if those messages actually contain attachments, and you defin...more
The Java 6 Desktop class has a mail() method for just such an action.
What string do I pass to SimpleDateFormat to format the message date to spec - getSentDate() method of Message?
There is no need to create a custom DateFormat. The MailDateFormat class found in the javax.mail.internet handles all this for you. It formats and parses the date based on the draft-ietf-drums-msg...more
The GlassFish Project is Sun's open source application server project. Found at https://glassfish.dev.java.net/, you can participate in the development of the latest version of Sun's Java System A...more
According to Bill Shannon of Sun, the July 2005 release of GlassFish contains JAF 1.1ea and a version of JavaMail slightly newer than 1.3.3ea.
As of July 2005, JavaMail is licensed with GlassFish under Sun's CDDL open source license.
Added with JavaMail 1.3, the getDeletedMessageCount() method of Folder gets this for you. A -1 may be returned if the server doesn't support the operation.
The mail.mime.charset system property is used. If unset, file.encoding is used instead.
The getFrom() of Message is one way, but the getSender() method of MimeMessage reads the RFC 822 Sender header field. A value of null is returned if the header isn't present. Comparing the two all...more
For POP3, you can get this information for the INBOx with <size=2>com.sun.mail.pop3.POP3Folder.getSize()</size>. For IMAP, the protocol doesn't support this feature. You would need to ...more
How do I package a JavaMail application into a single jar file along with the mail.jar and activation.jar?
You need to unjar all the JAR files into a single directory tree and then JAR them back up. The trick is preserving the location of some files: 425 Fri Dec 01 00:05:16 EST 2000 META-INF/javam...more
How do I get rid of unused connections? Doing something like checking for the existance of an IMAP folder leaves the connection open.
You can set the connection pool timeout property (mail.imap.connectionpooltimeout for imap). Then... according to JavaMail architect Bill Shannon: Because JavaMail doesn't use a separate thread t...more