com.atlassian.confluence.setup.velocity
Class PrototypeBeanContextItemProvider
java.lang.Object
com.atlassian.confluence.setup.velocity.PrototypeBeanContextItemProvider
- All Implemented Interfaces:
- VelocityContextItemProvider, org.springframework.context.ApplicationContextAware
public final class PrototypeBeanContextItemProvider
- extends Object
- implements VelocityContextItemProvider, org.springframework.context.ApplicationContextAware
Looks up the named bean each time in the application context before setting it in the Velocity context.
This is suitable for use with prototype beans that change based on the user, like "i18n" and "jsonator".
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PrototypeBeanContextItemProvider
public PrototypeBeanContextItemProvider()
getContextMap
public Map<String,Object> getContextMap()
- Specified by:
getContextMap
in interface VelocityContextItemProvider
- Returns:
- A map of values to be used within a Velocity
Context
. Must not be
null
setApplicationContext
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext)
throws org.springframework.beans.BeansException
- Specified by:
setApplicationContext
in interface org.springframework.context.ApplicationContextAware
- Throws:
org.springframework.beans.BeansException
setContextKeyToBeanNameMapping
public void setContextKeyToBeanNameMapping(Map<String,String> contextKeyToBeanName)
Copyright © 2003-2011 Atlassian. All Rights Reserved.