public class ExtendableViewToolManager
extends org.apache.velocity.tools.view.ViewToolManager
Constructor and Description |
---|
ExtendableViewToolManager(javax.servlet.ServletContext servletContext,
boolean autoConfig,
boolean includeDefaults) |
Modifier and Type | Method and Description |
---|---|
void |
addApplicationScopeTools(String providerId,
Class<?>... toolClasses)
Add the provided application scope velocity tools to the toolbox.
|
void |
addRequestScopeTools(String providerId,
Class<?>... toolClasses)
Add the provided request scope velocity tools to the toolbox.
|
void |
configure(org.apache.velocity.tools.config.FactoryConfiguration config) |
void |
refresh() |
void |
removeApplicationScopeTools(String providerId)
Remove all application scope tools of the given provider.
|
void |
removeRequestScopeTools(String providerId)
Remove all request scope tools of the given provider.
|
protected void |
unpublishApplicationTools() |
addToolboxes, autoConfigure, createContext, createContext, findConfig, getCreateSession, getPublishToolboxes, getSessionToolbox, getToolboxKey, hasSessionTools, prepareContext, publishToolboxes, publishToolboxes, setCreateSession, setPublishToolboxes, setToolboxKey, updateGlobalProperties
configure, createContext, createToolbox, debug, getApplicationToolbox, getLog, getRequestToolbox, getToolboxFactory, getUserCanOverwriteTools, getVelocityEngine, hasApplicationTools, hasRequestTools, hasTools, prepareContext, setToolboxFactory, setUserCanOverwriteTools, setVelocityEngine
public ExtendableViewToolManager(javax.servlet.ServletContext servletContext, boolean autoConfig, boolean includeDefaults)
public void addApplicationScopeTools(String providerId, Class<?>... toolClasses)
refresh()
has to be called.providerId
- the ID of the provider whose tools should be addedtoolClasses
- the velocity tools to addpublic void addRequestScopeTools(String providerId, Class<?>... toolClasses)
refresh()
has to be called.providerId
- the ID of the provider whose tools should be addedtoolClasses
- the velocity tools to addpublic void configure(org.apache.velocity.tools.config.FactoryConfiguration config)
configure
in class org.apache.velocity.tools.view.ViewToolManager
public void refresh()
public void removeApplicationScopeTools(String providerId)
refresh()
has to be called.providerId
- the ID of the provider whose tools should be removedpublic void removeRequestScopeTools(String providerId)
refresh()
has to be called.providerId
- the ID of the provider whose tools should be removedprotected void unpublishApplicationTools()
unpublishApplicationTools
in class org.apache.velocity.tools.view.ViewToolManager
Copyright © 2019 Communote team. All rights reserved.