public class TemplateView extends AbstractWebFrameworkView
MIMETYPE_HTML| Constructor and Description |
|---|
TemplateView(WebFrameworkConfigElement webFrameworkConfiguration,
ModelObjectService modelObjectService,
ResourceService resourceService,
RenderService renderService,
TemplatesContainer templatesContainer)
This is the preferred constructor to use for instantiating a new
TemplateView because it allows
complete flexibility when rendering the view. |
TemplateView(WebFrameworkServiceRegistry serviceRegistry)
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
void |
dispatchTemplate(RequestContext context) |
protected void |
renderView(RequestContext context)
To be implemented by view classes to provide render dispatch
|
protected void |
validateRequestContext(RequestContext context,
javax.servlet.http.HttpServletRequest request)
Extension point for performing any validation of the request context state
If the request context state is invalid, it can either be adjusted or an exception
can be raised.
|
exposeForwardRequestAttributes, getObjectService, getRenderService, getResourceService, getTemplatesContainer, getUriTokens, getUrlHelperFactory, getWebFrameworkConfiguration, lookupPage, populateRequestContext, renderMergedOutputModel, setupRequestContext, setUriTokens, setUrlHelperFactoryafterPropertiesSet, checkResource, getUrl, isUrlRequired, setUrl, toStringaddStaticAttribute, createMergedOutputModel, createRequestContext, createTemporaryOutputStream, exposeModelAsRequestAttributes, generatesDownloadContent, getAttributesMap, getBeanName, getContentType, getRequestContextAttribute, getStaticAttributes, isExposePathVariables, prepareResponse, render, setAttributes, setAttributesCSV, setAttributesMap, setBeanName, setContentType, setExposePathVariables, setRequestContextAttribute, setResponseContentType, writeToResponsegetServletContext, getTempDir, getWebApplicationContext, initApplicationContext, initServletContext, isContextRequired, setServletContextpublic TemplateView(WebFrameworkConfigElement webFrameworkConfiguration, ModelObjectService modelObjectService, ResourceService resourceService, RenderService renderService, TemplatesContainer templatesContainer)
This is the preferred constructor to use for instantiating a new TemplateView because it allows
complete flexibility when rendering the view. An AbstractWebFrameworkView is typically instantiated from
within a AbstractWebFrameworkViewResolver and all the arguments in the constructor signature should be
supplied to the AbstractWebFrameworkViewResolver as beans via the Spring configuration.
webFrameworkConfiguration - WebFrameworkConfigElementmodelObjectService - ModelObjectServiceresourceService - ResourceServicerenderService - RenderServicetemplatesContainer - TemplatesContainerpublic TemplateView(WebFrameworkServiceRegistry serviceRegistry)
This constructor should be avoided if possible because it relies on the supplied WebFrameworkServiceRegistry
argument to provide all the other Spring beans required to render the view. This means that there is no flexibility via
configuration to adapt different views to use different beans.
serviceRegistry - WebFrameworkServiceRegistryprotected void renderView(RequestContext context) throws Exception
AbstractWebFrameworkViewrenderView in class AbstractWebFrameworkViewcontext - the render contextExceptionpublic void dispatchTemplate(RequestContext context) throws RequestDispatchException
RequestDispatchExceptionprotected void validateRequestContext(RequestContext context, javax.servlet.http.HttpServletRequest request) throws Exception
AbstractWebFrameworkViewvalidateRequestContext in class AbstractWebFrameworkViewcontext - RequestContextrequest - HttpServletRequestExceptionCopyright © 2005–2016 Alfresco Software. All rights reserved.