Quadcap Embeddable Server

com.quadcap.pop3.client.MessageHook Interface Reference

Inheritance diagram for com.quadcap.pop3.client.MessageHook:

com.quadcap.pop3.client.HookShell com.quadcap.pop3.client.MailSuck List of all members.

Detailed Description

Interface for message delivery.

Author:
Stan Bailes

Definition at line 18 of file MessageHook.java.

Public Member Functions

void init (Properties p) throws Exception
 Initialize the hook with its property set.

boolean passAllHeaders ()
 Return true if the call to boolean passHeaders(Map headers) will always return true, so the message receiver can avoid calling it.

boolean passHeaders (Map headers)
 A hook first gets called with the parsed headers from the message.

boolean passMessage (InputStream is) throws Exception
 The hook is called to process the entire message (including headers) as an octet stream.


Member Function Documentation

void com.quadcap.pop3.client.MessageHook.init Properties  p  )  throws Exception
 

Initialize the hook with its property set.

Implemented in com.quadcap.pop3.client.HookShell, and com.quadcap.pop3.client.MailSuck.

Referenced by com.quadcap.pop3.client.Pop3Service.runAgent().

boolean com.quadcap.pop3.client.MessageHook.passAllHeaders  ) 
 

Return true if the call to boolean passHeaders(Map headers) will always return true, so the message receiver can avoid calling it.

Implemented in com.quadcap.pop3.client.HookShell, and com.quadcap.pop3.client.MailSuck.

boolean com.quadcap.pop3.client.MessageHook.passHeaders Map  headers  ) 
 

A hook first gets called with the parsed headers from the message.

If the hook returns 'true' to this call, it will be called again to process the body using sendMessage(), below.

Implemented in com.quadcap.pop3.client.HookShell, and com.quadcap.pop3.client.MailSuck.

boolean com.quadcap.pop3.client.MessageHook.passMessage InputStream  is  )  throws Exception
 

The hook is called to process the entire message (including headers) as an octet stream.

Returns:
false if the message is to be retained in the store, true to delete it.

Implemented in com.quadcap.pop3.client.HookShell, and com.quadcap.pop3.client.MailSuck.