Overview | Package | Class | Tree | Deprecated | Index | Help
| Compoze Software, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.compoze.mail
Class FileAttachmentServlet

    java.lang.Object
      |
      +--javax.servlet.GenericServlet
            |
            +--javax.servlet.http.HttpServlet
                  |
                  +--com.compoze.mail.FileAttachmentServlet

All Implemented Interfaces:
  java.io.Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig

public class FileAttachmentServlet
extends javax.servlet.http.HttpServlet

This class is a servlet that writes the file attachment. The servlet expects that an Http session attribute called `SESSION_ATTRIBUTE` contains the mail `ISession` object that is the mail session.

The servlet also expects that three request parameters be set: the `MESSAGE_ID` parameter must contain the ID of the message which has the file attachment to serve; the `FOLDER_ID` parameter must contain the ID of the folder which contains the message; and the `FILE_ATTACHMENT_NAME` parameter must contain the name of the file attachment to serve.

See Also:
  Serialized Form

Field Summary
`static java.lang.String` | `FILE_ATTACHMENT_NAME` The file attachment name request parameter .
`static java.lang.String` | `FOLDER_ID` The folder ID containing the message.
`static java.lang.String` | `MESSAGE_ATTACHMENT_NAME` The message attachment name containing the attachment (if the attachment is nested in an attached message) (optional).
`static java.lang.String` | `MESSAGE_ID` The message ID request parameter.
`static java.lang.String` | `SESSION_ATTRIBUTE` The session property name holding the `ISession` object.

Constructor Summary
`FileAttachmentServlet()`

Method Summary
`void` | `doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)`
`protected FileAttachment` | `getFileAttachment(javax.servlet.http.HttpServletRequest request)` Gets the file attachment.

Methods inherited from class javax.servlet.http.HttpServlet
`doDelete, doHead, doOptions, doPost, doPut, doTrace, getLastModified, service, service`

Methods inherited from class javax.servlet.GenericServlet
`destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, init, log, log`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### MESSAGE_ID

    public static final java.lang.String MESSAGE_ID

  The message ID request parameter.

### FOLDER_ID

    public static final java.lang.String FOLDER_ID

  The folder ID containing the message.

### MESSAGE_ATTACHMENT_NAME

    public static final java.lang.String MESSAGE_ATTACHMENT_NAME

  The message attachment name containing the attachment (if the attachment is nested in an attached message) (optional).

### FILE_ATTACHMENT_NAME

    public static final java.lang.String FILE_ATTACHMENT_NAME

  The file attachment name request parameter .

### SESSION_ATTRIBUTE

    public static final java.lang.String SESSION_ATTRIBUTE

  The session property name holding the `ISession` object.

Constructor Detail

### FileAttachmentServlet

    public FileAttachmentServlet()

Method Detail

### doGet

    public void doGet(javax.servlet.http.HttpServletRequest request,
                      javax.servlet.http.HttpServletResponse response)
               throws javax.servlet.ServletException,
                      java.io.IOException

  Overrides:
    `doGet` in class `javax.servlet.http.HttpServlet`

### getFileAttachment

    protected FileAttachment getFileAttachment(javax.servlet.http.HttpServletRequest request)

  Gets the file attachment.
  Parameters:
    `request` - the http servlet request
  Returns:
    the file attachment or `null` if not found

Overview | Package | Class | Tree | Deprecated | Index | Help
| Compoze Software, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright ©1999-2003 Compoze Software, Inc. All rights reserved.