|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
BeanPostProcessor service that allows bundles to contribute to the programming model of WLEvS. This avoids runtime and build-time dependencies between providers and the programming model. The API differs from regular BeanPostProcessors in that it is stateless with all the required state information passed in.
| Method Summary | |
void |
afterPropertiesSet(BundleContext context)
Initialization callback for this context |
void |
destroy(BundleContext context)
Destruction callback for this context |
java.lang.Object |
postProcessAfterInitialization(BundleContext context,
ConfigurableListableBeanFactory factory,
java.lang.Object bean,
java.lang.String beanName)
Apply this BeanPostProcessor to the given new bean instance after any bean initialization callbacks (like InitializingBean's afterPropertiesSet
or a custom init-method). |
void |
postProcessBeforeDestruction(BundleContext context,
ConfigurableListableBeanFactory factory,
java.lang.Object bean,
java.lang.String beanName)
Apply this BeanPostProcessor to the given bean instance before its destruction. |
java.lang.Object |
postProcessBeforeInitialization(BundleContext context,
ConfigurableListableBeanFactory factory,
java.lang.Object bean,
java.lang.String beanName)
Apply this BeanPostProcessor to the given new bean instance before any bean initialization callbacks (like InitializingBean's afterPropertiesSet
or a custom init-method). |
| Method Detail |
public java.lang.Object postProcessBeforeInitialization(BundleContext context,
ConfigurableListableBeanFactory factory,
java.lang.Object bean,
java.lang.String beanName)
throws BeansException
afterPropertiesSet
or a custom init-method). The bean will already be populated with property values.
The returned bean instance may be a wrapper around the original.
context - bundlefactory - the bean factory used by the application contextbean - the new bean instancebeanName - the name of the beanorg.springframework.beans.factory.InitializingBean#afterPropertiesSet
public java.lang.Object postProcessAfterInitialization(BundleContext context,
ConfigurableListableBeanFactory factory,
java.lang.Object bean,
java.lang.String beanName)
throws BeansException
afterPropertiesSet
or a custom init-method). The bean will already be populated with property values.
The returned bean instance may be a wrapper around the original.
In case of a FactoryBean, this callback will be invoked for both the FactoryBean
instance and the objects created by the FactoryBean (as of Spring 2.0). The
post-processor can decide whether to apply to either the FactoryBean or created
objects or both through corresponding bean instanceof FactoryBean checks.
This callback will also be invoked after a short-circuiting triggered by a
org.springframework.beans.factory.config.InstantiationAwareBeanPostProcessor#postProcessBeforeInstantiation method,
in contrast to all other BeanPostProcessor callbacks.
context - bundlefactory - the bean factory used by the application contextbean - the new bean instancebeanName - the name of the beanorg.springframework.beans.factory.InitializingBean#afterPropertiesSet,
org.springframework.beans.factory.FactoryBean
public void postProcessBeforeDestruction(BundleContext context,
ConfigurableListableBeanFactory factory,
java.lang.Object bean,
java.lang.String beanName)
throws BeansException
Like DisposableBean's destroy and a custom destroy method,
this callback just applies to singleton beans in the factory (including
inner beans).
context - bundlefactory - the bean factory used by the application contextbean - the bean instance to be destroyedbeanName - the name of the beanorg.springframework.beans.factory.DisposableBean,
org.springframework.beans.factory.support.AbstractBeanDefinition#setDestroyMethodName
public void afterPropertiesSet(BundleContext context)
throws java.lang.Exception
context -
public void destroy(BundleContext context)
throws java.lang.Exception
context -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||