|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.servlet.GenericServlet javax.servlet.http.HttpServlet org.dbforms.servlets.reports.ReportServletAbstract
public abstract class ReportServletAbstract
This is the abstract base class for generating reports.
Constructor Summary | |
---|---|
ReportServletAbstract()
|
Method Summary | |
---|---|
protected void |
compileReport(ServletContext context,
String reportFile)
|
void |
doGet(HttpServletRequest request,
HttpServletResponse response)
Basic servlet method, answers requests from the browser. |
void |
doPost(HttpServletRequest request,
HttpServletResponse response)
Basic servlet method, answers requests fromt the browser. |
protected abstract String |
getReportFileExtension()
|
protected void |
handleException(HttpServletRequest request,
HttpServletResponse response,
Exception e)
|
void |
init()
Initialize this servlet. |
protected void |
process(HttpServletRequest request,
HttpServletResponse response)
generates a report from request. |
protected abstract ReportWriter |
processReport(String reportFileFullName,
JRDataSourceAbstract dataSource,
ServletContext context,
HttpServletRequest request,
HttpServletResponse response)
generates a report. |
Methods inherited from class javax.servlet.http.HttpServlet |
---|
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service |
Methods inherited from class javax.servlet.GenericServlet |
---|
destroy, 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 |
Constructor Detail |
---|
public ReportServletAbstract()
Method Detail |
---|
public final void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
doGet
in class HttpServlet
request
- HTTPServletRequestresponse
- HTTPServletResponse
ServletException
- if there is a servlet problem.
IOException
- if there is an I/O problem.public final void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
doPost
in class HttpServlet
request
- HTTPServletRequestresponse
- HTTPServletResponse
ServletException
- if there is a servlet problem.
IOException
- if there is an I/O problem.public void init() throws ServletException
init
in class GenericServlet
ServletException
- if we cannot configure ourselves correctlyprotected abstract ReportWriter processReport(String reportFileFullName, JRDataSourceAbstract dataSource, ServletContext context, HttpServletRequest request, HttpServletResponse response)
reportFileFullName
- filename of report to process reportHTTPServletRequest
generated by getReportFile! getReportFile should be called
before fetching data, so that error handling of report not
found e.g. could be processed first!dataSource
- data for the reportcontext
- ServletContextrequest
- HTTPServletRequestresponse
- HTTPServletResponseprotected abstract String getReportFileExtension()
protected final void handleException(HttpServletRequest request, HttpServletResponse response, Exception e)
protected void compileReport(ServletContext context, String reportFile) throws Exception
Exception
protected void process(HttpServletRequest request, HttpServletResponse response)
request
- HTTPServletRequestresponse
- HTTPServletResponse
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |