service
perform all needed work on the Mail object. Whatever remains at the end of the service is considered to need futher processing and will go to the next Mailet if there is one configured or will go to the error processor if not. Setting a Mail state (setState(String)) to Mail.GHOST or cleaning its recipient list has the same meaning that s no more processing is needed. Instead of creating new messages, the mailet can put a message with new recipients at the top of the mail queue, or insert them immediately after it's execution through the API are provided by the MailetContext interface. This interface defines methods to initialize a mailet, to service messages, and to remove a mailet from the server. These are known as life-cycle methods and are called in the following sequence:
|
|