public class JspToolContext extends ViewToolContext
Velocity context implementation specific to the JSP environment.
| Modifier and Type | Field and Description |
|---|---|
static String |
PAGE_CONTEXT_KEY |
CATCH_EXCEPTIONS_KEY, CONTEXT_KEY, ENGINE_KEY, LOCALE_KEY, LOG_KEY, PATH_KEY, TOOLKEY_KEYAPPLICATION, DEFAULT_TOOLBOX_KEY, REQUEST, RESPONSE, SERVLET_CONTEXT_KEY, SESSION| Constructor and Description |
|---|
JspToolContext(org.apache.velocity.app.VelocityEngine velocity,
javax.servlet.jsp.PageContext pageContext) |
| Modifier and Type | Method and Description |
|---|---|
Object |
getAttribute(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.
|
javax.servlet.jsp.PageContext |
getPageContext() |
protected Object |
getServletApi(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, setToolboxKeyaddToolbox, findTool, getKeys, getToolbox, getToolClassMap, getToolProperties, getUserCanOverwriteTools, internalGet, keySet, put, putAll, putToolProperties, putToolProperty, putVelocityEngine, remove, setUserCanOverwriteToolspublic static final String PAGE_CONTEXT_KEY
public JspToolContext(org.apache.velocity.app.VelocityEngine velocity,
javax.servlet.jsp.PageContext pageContext)
protected void putToolProperties()
putToolProperties in class ViewToolContextpublic javax.servlet.jsp.PageContext getPageContext()
protected Object getServletApi(String key)
ViewToolContextgetServletApi in class ViewToolContextkey - attribute keypublic Object getAttribute(String key)
ViewToolContextSearches 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 ViewContextgetAttribute in class ViewToolContextkey - attribute keyCopyright © 2002–2021 The Apache Software Foundation. All rights reserved.