com.javaforge.tapestry.spring
Class SpringBeanInjectionWorker
java.lang.Object
com.javaforge.tapestry.spring.SpringBeanInjectionWorker
- All Implemented Interfaces:
- org.apache.tapestry.enhance.InjectEnhancementWorker
public final class SpringBeanInjectionWorker
- extends Object
- implements org.apache.tapestry.enhance.InjectEnhancementWorker
Injects a spring bean into a Tapestry page or component. This is done a bit differently than
injecting a HiveMind service. With HiveMind, a proxy can be obtained and injected, and the
HiveMind proxy will encapsulate the lifecycle of the underlying service (the client doesn't have
to be aware of when the service is instantiated, or what is lifecycle is). Spring is a bit
different, for beans with the prototype lifecycle, it is necessary to keep re-acquiring them.
This form of injection, "spring" injection, does just that; the implementation of the property
getter method will go to the default Spring BeanFactory at ask for each bean; no caching of
Spring beans occurs.
- Author:
- Howard M. Lewis Ship
|
Method Summary |
void |
performEnhancement(org.apache.tapestry.enhance.EnhancementOperation op,
org.apache.tapestry.spec.InjectSpecification is)
|
void |
setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory)
For injection. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SpringBeanInjectionWorker
public SpringBeanInjectionWorker()
performEnhancement
public void performEnhancement(org.apache.tapestry.enhance.EnhancementOperation op,
org.apache.tapestry.spec.InjectSpecification is)
- Specified by:
performEnhancement in interface org.apache.tapestry.enhance.InjectEnhancementWorker
setBeanFactory
public void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory)
- For injection.
Copyright © 2006-2007 Howard M. Lewis Ship. All Rights Reserved.