public class LoadTimeWeaverAwareProcessor
extends java.lang.Object
implements org.springframework.beans.factory.config.BeanPostProcessor, org.springframework.beans.factory.BeanFactoryAware
BeanPostProcessor
implementation that passes the context's default LoadTimeWeaver
to beans that implement the LoadTimeWeaverAware
interface.
Application contexts
will automatically register this with their underlying bean factory
,
provided that a default LoadTimeWeaver
is actually available.
Applications should not use this class directly.
LoadTimeWeaverAware
,
ConfigurableApplicationContext.LOAD_TIME_WEAVER_BEAN_NAME
Constructor and Description |
---|
LoadTimeWeaverAwareProcessor()
Create a new
LoadTimeWeaverAwareProcessor that will
auto-retrieve the LoadTimeWeaver from the containing
BeanFactory , expecting a bean named
"loadTimeWeaver" . |
LoadTimeWeaverAwareProcessor(org.springframework.beans.factory.BeanFactory beanFactory)
Create a new
LoadTimeWeaverAwareProcessor . |
LoadTimeWeaverAwareProcessor(LoadTimeWeaver loadTimeWeaver)
Create a new
LoadTimeWeaverAwareProcessor for the given
LoadTimeWeaver . |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
postProcessAfterInitialization(java.lang.Object bean,
java.lang.String name) |
java.lang.Object |
postProcessBeforeInitialization(java.lang.Object bean,
java.lang.String beanName) |
void |
setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory) |
public LoadTimeWeaverAwareProcessor()
LoadTimeWeaverAwareProcessor
that will
auto-retrieve the LoadTimeWeaver
from the containing
BeanFactory
, expecting a bean named
"loadTimeWeaver"
.public LoadTimeWeaverAwareProcessor(LoadTimeWeaver loadTimeWeaver)
LoadTimeWeaverAwareProcessor
for the given
LoadTimeWeaver
.
If the given loadTimeWeaver
is null
, then a
LoadTimeWeaver
will be auto-retrieved from the containing
BeanFactory
, expecting a bean named
"loadTimeWeaver"
.
loadTimeWeaver
- the specific LoadTimeWeaver
that is to be usedpublic LoadTimeWeaverAwareProcessor(org.springframework.beans.factory.BeanFactory beanFactory)
LoadTimeWeaverAwareProcessor
.
The LoadTimeWeaver
will be auto-retrieved from
the given BeanFactory
, expecting a bean named
"loadTimeWeaver"
.
beanFactory
- the BeanFactory to retrieve the LoadTimeWeaver frompublic void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory)
setBeanFactory
in interface org.springframework.beans.factory.BeanFactoryAware
public java.lang.Object postProcessBeforeInitialization(java.lang.Object bean, java.lang.String beanName) throws org.springframework.beans.BeansException
postProcessBeforeInitialization
in interface org.springframework.beans.factory.config.BeanPostProcessor
org.springframework.beans.BeansException
public java.lang.Object postProcessAfterInitialization(java.lang.Object bean, java.lang.String name)
postProcessAfterInitialization
in interface org.springframework.beans.factory.config.BeanPostProcessor