Simple SMTP Client

sendMailApp.png

Description

The application is the simple SMTP client GUI that demonstrates usage of the MailTransport class built on the top of Javamail extension to JDK.

The user has possibility to either compose one by one textual message and send them immediately or compose several textual messages in a raw and send them together.

After the first message is put into outgoing queue, application does not allow user to change selected server (until the queue is released with Send Immediatelly button).

The Mail Transport Client

The MailTransport class encapsulates mail transport agent with FIFO queue and non-blocking send capabilities. Instances of this class may be used in two different scenarios. (Note the position of MailTransport.startSending() method and the usage of MailTransport.noMoreMessages() bellow.)


Scenario 1: Sends one or more messages at once.

Usage:


Scenario 2. Works in background as relay client to SMTP server.

Usage:


Executable

The jar file of the package can be found here.

The jar also includes repacked mail.jar retrieved from JavaMail 1.4.3.

Sources

Source files: