org.apache.velocity.tools.view.jsp
public class JspToolContext extends ViewToolContext
Velocity context implementation specific to the JSP environment.
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
PAGE_CONTEXT_KEY |
private PageContext |
pageContext |
CATCH_EXCEPTIONS_KEY, CONTEXT_KEY, ENGINE_KEY, LOCALE_KEY, LOG_KEY, PATH_KEY
APPLICATION, DEFAULT_TOOLBOX_KEY, REQUEST, RESPONSE, SERVLET_CONTEXT_KEY, SESSION
Constructor and Description |
---|
JspToolContext(VelocityEngine velocity,
PageContext pageContext) |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
getAttribute(java.lang.String key)
Searches for the named attribute in request, session (if valid),
and application scope(s) in order and returns the value associated
or null.
|
PageContext |
getPageContext() |
protected java.lang.Object |
getServletApi(java.lang.String key)
Returns the current matching servlet request, response, session,
or servlet context instance, or null if the key matches none of those
keys.
|
protected void |
putToolProperties() |
addToolboxesUnderKey, containsKey, get, getRequest, getResponse, getServletContext, getSession, getToolboxes, getToolVar, getUserVar, getVelocityContext, getVelocityEngine, setToolboxKey
addToolbox, containsKey, findTool, getKeys, getToolbox, getToolClassMap, getToolProperties, getUserCanOverwriteTools, internalGet, keySet, put, putAll, putToolProperties, putToolProperty, putVelocityEngine, remove, setUserCanOverwriteTools
public static final java.lang.String PAGE_CONTEXT_KEY
private final PageContext pageContext
public JspToolContext(VelocityEngine velocity, PageContext pageContext)
protected void putToolProperties()
putToolProperties
in class ViewToolContext
public PageContext getPageContext()
protected java.lang.Object getServletApi(java.lang.String key)
ViewToolContext
getServletApi
in class ViewToolContext
public java.lang.Object getAttribute(java.lang.String key)
ViewToolContext
Searches for the named attribute in request, session (if valid), and application scope(s) in order and returns the value associated or null.
getAttribute
in interface ViewContext
getAttribute
in class ViewToolContext
Copyright (c) 2003-2007 Apache Software Foundation