当前页面:
在线文档首页 >
JBOSS Portal 2.6 API 英文版文档
DownloadAttachmentsServlet - JBOSS Portal 2.6 API 英文版文档
org.jboss.portlet.forums.servlet
Class DownloadAttachmentsServlet
java.lang.Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
org.jboss.portlet.forums.servlet.DownloadAttachmentsServlet
- All Implemented Interfaces:
- java.io.Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig
- public class DownloadAttachmentsServlet
- extends javax.servlet.http.HttpServlet
Provides attachments downloading capabilities
- Version:
- $Revision: 5448 $
- Author:
- Boleslaw Dawidowicz
- See Also:
- Serialized Form
Fields inherited from class javax.servlet.http.HttpServlet |
|
Fields inherited from class javax.servlet.GenericServlet |
|
Method Summary |
void |
destroy()
|
void |
doGet(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
void |
doPost(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
private Attachment |
getAttachment(java.lang.Integer id)
In portal we don't use hibernate transactions because every request is surounded with JTA transaction context by
portal. |
void |
init()
|
private void |
printMessage(java.lang.String msg,
javax.servlet.http.HttpServletResponse resp)
this prints dummy message to output writer |
Methods inherited from class javax.servlet.http.HttpServlet |
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service |
Methods inherited from class javax.servlet.GenericServlet |
getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
tm
private javax.transaction.TransactionManager tm
forumsModule
ForumsModule forumsModule
BUF_SIZE
int BUF_SIZE
DownloadAttachmentsServlet
public DownloadAttachmentsServlet()
init
public void init()
destroy
public void destroy()
doPost
public void doPost(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws javax.servlet.ServletException,
java.io.IOException
- Throws:
javax.servlet.ServletException
java.io.IOException
doGet
public void doGet(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws javax.servlet.ServletException,
java.io.IOException
- Throws:
javax.servlet.ServletException
java.io.IOException
getAttachment
private Attachment getAttachment(java.lang.Integer id)
- In portal we don't use hibernate transactions because every request is surounded with JTA transaction context by
portal. So in servlet when we use ForumsModule we must do the same.
- Parameters:
id
-
- Returns:
printMessage
private void printMessage(java.lang.String msg,
javax.servlet.http.HttpServletResponse resp)
- this prints dummy message to output writer
- Parameters:
msg
- resp
-