|
||||||||||
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 fr.opensagres.xdocreport.document.web.BaseXDocReportServlet
public abstract class BaseXDocReportServlet
Base class for XDoc Report servlet.
Field Summary |
---|
Fields inherited from interface fr.opensagres.xdocreport.document.web.XDocBaseServletConstants |
---|
DISPATCH_HTTP_PARAM, ENTRY_NAME_HTTP_PARAM, PROCESS_STATE_HTTP_PARAM, REPORT_ID_HTTP_PARAM, TEMPLATE_ENGINE_ID_HTTP_PARAM, TEMPLATE_ENGINE_KIND_HTTP_PARAM, XDOCREPORT_ATTR_KEY, XDOCREPORTREGISTRY_SESSION_KEY |
Constructor Summary | |
---|---|
BaseXDocReportServlet()
|
Method Summary | |
---|---|
protected void |
clearRegistryFromHTTPSession(javax.servlet.http.HttpServletRequest request)
Clear registry from HTTP session. |
protected void |
disableHTTPResponCache(javax.servlet.http.HttpServletResponse response)
Disable cache HTTP hearder. |
void |
doGet(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Handles HTTP GET requests by calling #doRequest() . |
void |
doPost(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Handles HTTP POST requests by calling #doRequest() . |
protected String |
getContentDisposition(String fileName)
|
protected String |
getContentDisposition(String reportId,
MimeMapping mimeMapping,
javax.servlet.http.HttpServletRequest request)
|
protected String |
getDispatchParameter(javax.servlet.http.HttpServletRequest request)
Returns dispatch parameter value. |
protected String |
getEntryName(javax.servlet.http.HttpServletRequest request)
Returns the entry name of the report. |
protected ProcessState |
getProcessState(javax.servlet.http.HttpServletRequest request)
Returns process state (original|preprocessed|generated). |
protected XDocReportRegistry |
getRegistry(javax.servlet.http.HttpServletRequest request)
Returns the XDocReport registry which load and cache document. |
protected XDocReportRegistry |
getRegistryFromHTTPSession(javax.servlet.http.HttpServletRequest request)
Returns registry from HTTP session. |
protected String |
getReportId(javax.servlet.http.HttpServletRequest request)
Returns the id of the report. |
protected ITemplateEngine |
getTemplateEngine(javax.servlet.http.HttpServletRequest request)
Returns the template engine from request and otherwise returns the default template engine. |
protected ITemplateEngine |
getTemplateEngine(IXDocReport report,
javax.servlet.http.HttpServletRequest request)
|
protected ITemplateEngine |
getTemplateEngine(String reportId,
javax.servlet.http.HttpServletRequest request)
Returns the template engine to use for the report. |
protected String |
getTemplateEngineId(javax.servlet.http.HttpServletRequest request)
Returns the template engine id from request. |
protected String |
getTemplateEngineKind(javax.servlet.http.HttpServletRequest request)
|
protected String |
getTemplateEngineKind(String reportId,
javax.servlet.http.HttpServletRequest request)
|
void |
init(javax.servlet.ServletConfig config)
|
protected boolean |
isDisableHTTPResponCache()
|
protected boolean |
isGenerateContentDisposition(String reportId,
MimeMapping mimeMapping,
javax.servlet.http.HttpServletRequest request)
|
protected void |
prepareHTTPResponse(String reportId,
MimeMapping mimeMapping,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
protected void |
prepareHTTPResponse(String reportId,
String entryName,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
protected abstract void |
processRequest(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Handles all requests (by default). |
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 BaseXDocReportServlet()
Method Detail |
---|
public void init(javax.servlet.ServletConfig config) throws javax.servlet.ServletException
init
in interface javax.servlet.Servlet
init
in class javax.servlet.GenericServlet
javax.servlet.ServletException
public void doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, IOException
GET
requests by calling #doRequest()
.
doGet
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
public void doPost(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, IOException
POST
requests by calling #doRequest()
.
doPost
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
protected String getDispatchParameter(javax.servlet.http.HttpServletRequest request)
request
-
protected String getReportId(javax.servlet.http.HttpServletRequest request)
request
-
protected ProcessState getProcessState(javax.servlet.http.HttpServletRequest request)
request
-
protected String getEntryName(javax.servlet.http.HttpServletRequest request)
request
-
protected String getTemplateEngineKind(String reportId, javax.servlet.http.HttpServletRequest request)
protected String getTemplateEngineKind(javax.servlet.http.HttpServletRequest request)
protected String getTemplateEngineId(javax.servlet.http.HttpServletRequest request)
request
-
protected ITemplateEngine getTemplateEngine(String reportId, javax.servlet.http.HttpServletRequest request)
reportId
- request
-
protected ITemplateEngine getTemplateEngine(IXDocReport report, javax.servlet.http.HttpServletRequest request)
protected ITemplateEngine getTemplateEngine(javax.servlet.http.HttpServletRequest request)
request
-
protected XDocReportRegistry getRegistry(javax.servlet.http.HttpServletRequest request)
request
-
protected XDocReportRegistry getRegistryFromHTTPSession(javax.servlet.http.HttpServletRequest request)
request
-
protected void clearRegistryFromHTTPSession(javax.servlet.http.HttpServletRequest request)
request
- protected void disableHTTPResponCache(javax.servlet.http.HttpServletResponse response)
response
- protected void prepareHTTPResponse(String reportId, MimeMapping mimeMapping, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
protected void prepareHTTPResponse(String reportId, String entryName, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
protected boolean isDisableHTTPResponCache()
protected boolean isGenerateContentDisposition(String reportId, MimeMapping mimeMapping, javax.servlet.http.HttpServletRequest request)
protected String getContentDisposition(String reportId, MimeMapping mimeMapping, javax.servlet.http.HttpServletRequest request)
protected String getContentDisposition(String fileName)
protected abstract void processRequest(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, IOException
request
- HttpServletRequest object containing client requestresponse
- HttpServletResponse object for the response
javax.servlet.ServletException
IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |