org.apache.servlet.mail
Class MailServlet
java.lang.Object
|
+--javax.servlet.GenericServlet
|
+--org.apache.servlet.mail.MailServlet
- public abstract class MailServlet
- extends javax.servlet.GenericServlet
- implements java.io.Serializable
This class is a generic servlet abstract extention that simplifies
the process of writing a mail servlet. To implement a mail
servlet, a servlet writer must subclass it and override the
service() method.
While an Http servlet is described as an action associated with the
called Http URL, a mail servlet may be considered as an active filter
associated with a given mail address.
The mail servlet recieves a MailServletRequest encapsulating the mail
message received and a MailServletResponse used by the mail servlet to
forward the message to the specified destinations and with the message
body processed by the mail servlet.
- Version:
- pre-draft 1.0 (submitted for review)
- Author:
- Stefano Mazzocchi , Pierpaolo Fumagalli
- See Also:
- Serialized Form
Constructor Summary |
MailServlet()
Default constructor does nothing. |
Method Summary |
abstract void |
service(MailServletRequest mailServletRequest,
MailServletResponse mailServletResponse)
This method must be implemented by the mail servlet writers. |
void |
service(javax.servlet.ServletRequest servletRequest,
javax.servlet.ServletResponse servletResponse)
This method forwards the request and response objects to the other
service method casting them to the appropriate mail equivalents. |
Methods inherited from class javax.servlet.GenericServlet |
destroy,
getInitParameter,
getInitParameterNames,
getServletConfig,
getServletContext,
getServletInfo,
init,
log |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
MailServlet
public MailServlet()
- Default constructor does nothing.
service
public void service(javax.servlet.ServletRequest servletRequest,
javax.servlet.ServletResponse servletResponse)
throws javax.servlet.ServletException,
java.io.IOException
- This method forwards the request and response objects to the other
service method casting them to the appropriate mail equivalents.
- Overrides:
- service in class javax.servlet.GenericServlet
service
public abstract void service(MailServletRequest mailServletRequest,
MailServletResponse mailServletResponse)
throws javax.servlet.ServletException,
java.io.IOException
- This method must be implemented by the mail servlet writers.