public class PlatformProcessor extends AbstractRequestProcessor
RequestProcessor
-implementation, using an XSLT based template.contentLength, contentType, env, marshallService, navigationBuilder, outputFormat, outputType, pathInfo, redirect, servletRequest, servletResponse, templatePath
Constructor and Description |
---|
PlatformProcessor() |
Modifier and Type | Method and Description |
---|---|
protected void |
addTemplates(List<Template> templates) |
Platform |
getPlatform(MarshallService marshallService,
Path path)
Returns the
Platform -object unmarshalled from the template's
"conf/platform.xml"-file. |
PlatformTransformer |
getPlatformTransformer() |
protected String |
handleError(Properties platformProperties,
Platform platform,
String templateName,
Exception e) |
void |
init(javax.servlet.http.HttpServletRequest servletRequest,
javax.servlet.http.HttpServletResponse servletResponse,
PathInfo pathInfo,
String templateDir)
Initializes the
RequestProcessor . |
String |
processWithTemplate(Site applicationSite)
Processes the request, including the processing of the template.
|
void |
setPlatformTransformer(PlatformTransformer platformTransformer) |
determineActiveAuthentication, determineFormatAndType, getApplicationProvider, getContentLength, getContentType, getMarshallService, getOutputFormat, getOutputType, getTemplatePath, initPlatform, isRedirect, processPlatform, setMarshallService, setRedirect, setTemplatePath
public void init(javax.servlet.http.HttpServletRequest servletRequest, javax.servlet.http.HttpServletResponse servletResponse, PathInfo pathInfo, String templateDir)
RequestProcessor
RequestProcessor
.init
in interface RequestProcessor
init
in class AbstractRequestProcessor
servletRequest
- the current HttpServletRequest
servletResponse
- the current HttpServletResponse
pathInfo
- the current PathInfo
templateDir
- the absolute path to the directory where the active template of the Site
residespublic Platform getPlatform(MarshallService marshallService, Path path) throws InvalidConfigurationException
AbstractRequestProcessor
Platform
-object unmarshalled from the template's
"conf/platform.xml"-file. Also determines the OutputType
and
OutputFormat
for the upcoming transformation.getPlatform
in class AbstractRequestProcessor
marshallService
- the MarshallService
to use for unmarshallingpath
- the current Path
-objectPlatform
-objectInvalidConfigurationException
- if the "conf/platform.xml"-file could net be found or
unmarshalled.AbstractRequestProcessor.getOutputFormat()
,
AbstractRequestProcessor.getOutputType()
public String processWithTemplate(Site applicationSite) throws InvalidConfigurationException
RequestProcessor
RequestProcessor.init(HttpServletRequest, HttpServletResponse, PathInfo, String)
must have been called before.applicationSite
- the Site
for which the process the requestApplication
and applying the Template
. This should then be
written to the HttpServletResponse
InvalidConfigurationException
- if something goes wrong while processing the requestRequestProcessor.processPlatform(Site)
protected String handleError(Properties platformProperties, Platform platform, String templateName, Exception e)
public PlatformTransformer getPlatformTransformer()
public void setPlatformTransformer(PlatformTransformer platformTransformer)
protected void addTemplates(List<Template> templates)
addTemplates
in class AbstractRequestProcessor
Copyright © 2011–2017 aiticon GmbH. All rights reserved.