Package org.craftercms.engine.view
Class CrafterPageView
java.lang.Object
org.springframework.context.support.ApplicationObjectSupport
org.springframework.web.context.support.WebApplicationObjectSupport
org.springframework.web.servlet.view.AbstractView
org.craftercms.engine.view.CrafterPageView
- All Implemented Interfaces:
org.craftercms.core.util.cache.CachingAwareObject,org.springframework.beans.factory.Aware,org.springframework.beans.factory.BeanNameAware,org.springframework.beans.factory.InitializingBean,org.springframework.context.ApplicationContextAware,org.springframework.web.context.ServletContextAware,org.springframework.web.servlet.View
- Direct Known Subclasses:
UserAgentAwareCrafterPageView
public class CrafterPageView
extends org.springframework.web.servlet.view.AbstractView
implements org.craftercms.core.util.cache.CachingAwareObject, org.springframework.beans.factory.InitializingBean
- Author:
- Alfonso Vásquez
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Longstatic final Stringstatic final Stringprotected org.springframework.web.servlet.ViewResolverprotected booleanprotected Objectstatic final Stringstatic final StringDeprecated.protected Localeprotected Stringprotected SiteItemstatic final Stringprotected Stringprotected StringFields inherited from interface org.springframework.web.servlet.View
PATH_VARIABLES, RESPONSE_STATUS_ATTRIBUTE, SELECTED_CONTENT_TYPE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcreateScriptVariables(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, Map<String, Object> model) protected voidexecuteScript(Script script, Map<String, Object> scriptVariables) getKey()protected StringgetPage()protected StringgetScope()protected voidrenderActualView(String pageViewName, Map<String, Object> model, jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) protected voidrenderMergedOutputModel(Map<String, Object> model, jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) voidsetCachingTime(Long cachingTime) voidsetDisableVariableRestrictions(boolean disableVariableRestrictions) voidvoidtoString()Methods inherited from class org.springframework.web.servlet.view.AbstractView
addStaticAttribute, createMergedOutputModel, createRequestContext, createTemporaryOutputStream, exposeModelAsRequestAttributes, formatViewName, generatesDownloadContent, getAttributesMap, getBeanName, getContentType, getRequestContextAttribute, getRequestToExpose, getStaticAttributes, isExposePathVariables, prepareResponse, render, setAttributes, setAttributesCSV, setAttributesMap, setBeanName, setContentType, setExposeContextBeansAsAttributes, setExposedContextBeanNames, setExposePathVariables, setRequestContextAttribute, setResponseContentType, writeToResponseMethods inherited from class org.springframework.web.context.support.WebApplicationObjectSupport
getServletContext, getTempDir, getWebApplicationContext, initApplicationContext, initServletContext, isContextRequired, setServletContextMethods inherited from class org.springframework.context.support.ApplicationObjectSupport
getApplicationContext, getMessageSourceAccessor, initApplicationContext, obtainApplicationContext, requiredContextClass, setApplicationContext
-
Field Details
-
PAGE_URL_ATTRIBUTE_NAME
- See Also:
-
DEFAULT_CONTENT_TYPE
- See Also:
-
DEFAULT_CHARSET
- See Also:
-
KEY_MODEL
Deprecated.- See Also:
-
KEY_CONTENT_MODEL
- See Also:
-
scope
-
key
-
cachingTime
-
page
-
locale
-
pageViewNameXPathQuery
-
mimeTypeXPathQuery
-
scripts
-
delegatedViewResolver
protected org.springframework.web.servlet.ViewResolver delegatedViewResolver -
disableVariableRestrictions
protected boolean disableVariableRestrictions
-
-
Constructor Details
-
CrafterPageView
-
-
Method Details
-
getPage
-
getScope
- Specified by:
getScopein interfaceorg.craftercms.core.util.cache.CachingAwareObject
-
setScope
- Specified by:
setScopein interfaceorg.craftercms.core.util.cache.CachingAwareObject
-
getKey
- Specified by:
getKeyin interfaceorg.craftercms.core.util.cache.CachingAwareObject
-
setKey
- Specified by:
setKeyin interfaceorg.craftercms.core.util.cache.CachingAwareObject
-
getCachingTime
- Specified by:
getCachingTimein interfaceorg.craftercms.core.util.cache.CachingAwareObject
-
setCachingTime
- Specified by:
setCachingTimein interfaceorg.craftercms.core.util.cache.CachingAwareObject
-
setDisableVariableRestrictions
public void setDisableVariableRestrictions(boolean disableVariableRestrictions) -
toString
- Overrides:
toStringin classorg.springframework.web.servlet.view.AbstractView
-
afterPropertiesSet
- Specified by:
afterPropertiesSetin interfaceorg.springframework.beans.factory.InitializingBean- Throws:
Exception
-
renderMergedOutputModel
protected void renderMergedOutputModel(Map<String, Object> model, jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) throws Exception- Specified by:
renderMergedOutputModelin classorg.springframework.web.servlet.view.AbstractView- Throws:
Exception
-
executeScript
- Throws:
Exception
-
createScriptVariables
-
getPageViewName
- Throws:
RenderingException
-
getMimeType
-
renderActualView
protected void renderActualView(String pageViewName, Map<String, Object> model, jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) throws Exception- Throws:
Exception
-