0.37: What are JavaMail and mail sessions?

JavaMail models an e-mail and messaging service.The JavaMail APIs provide a platform and protocol independent framework to build Java technology-based mail and messaging applications. JavaMail requires the Java Activation Framework (JAF) to deal with complex data types as, for example, MIME (Multipurpose Internet Mail Extensions).

Mail sessions are represented by the javax.mail.Session class. The "session" object validates a JavaMail user, and controls the user's access to the message storage and transport services.

To create platform-independent applications, a JavaMail program uses a resource factory reference to obtain a JavaMail session. A resource factory is an object that provides access to resources in a program's deployed environment using the naming conventions defined by JNDI (Java Naming and Directory Interface).

See the Related information section for more JavaMail topics.