Class InterceptingApplicationEventMulticasterProxy
java.lang.Object
io.microsphere.spring.beans.factory.config.GenericBeanPostProcessorAdapter<org.springframework.context.ApplicationListener>
io.microsphere.spring.context.event.InterceptingApplicationEventMulticasterProxy
- All Implemented Interfaces:
org.springframework.beans.factory.Aware
,org.springframework.beans.factory.BeanFactoryAware
,org.springframework.beans.factory.config.BeanPostProcessor
,org.springframework.context.event.ApplicationEventMulticaster
public class InterceptingApplicationEventMulticasterProxy
extends GenericBeanPostProcessorAdapter<org.springframework.context.ApplicationListener>
implements org.springframework.context.event.ApplicationEventMulticaster, org.springframework.beans.factory.BeanFactoryAware
Intercepting
ApplicationEventMulticaster
Proxy- Since:
- 1.0.0
- Author:
- Mercy
- See Also:
-
ApplicationEventMulticaster
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionInterceptingApplicationEventMulticasterProxy
(org.springframework.core.env.Environment environment) -
Method Summary
Modifier and TypeMethodDescriptionvoid
addApplicationListener
(org.springframework.context.ApplicationListener<?> listener) void
addApplicationListenerBean
(String listenerBeanName) protected org.springframework.context.ApplicationListener
doPostProcessAfterInitialization
(org.springframework.context.ApplicationListener bean, String beanName) Adapter BeanPostProcessor#postProcessAfterInitialization(Object, String) method , sub-type could override this method.static String
getResetBeanName
(org.springframework.core.env.Environment environment) protected Executor
void
multicastEvent
(org.springframework.context.ApplicationEvent event) void
multicastEvent
(org.springframework.context.ApplicationEvent event, org.springframework.core.ResolvableType eventType) void
void
removeApplicationListener
(org.springframework.context.ApplicationListener<?> listener) void
removeApplicationListenerBean
(String listenerBeanName) void
removeApplicationListenerBeans
(Predicate<String> predicate) void
removeApplicationListeners
(Predicate<org.springframework.context.ApplicationListener<?>> predicate) void
setBeanFactory
(org.springframework.beans.factory.BeanFactory beanFactory) void
setTaskExecutor
(Executor taskExecutor) Methods inherited from class io.microsphere.spring.beans.factory.config.GenericBeanPostProcessorAdapter
doPostProcessBeforeInitialization, getBeanType, postProcessAfterInitialization, postProcessBeforeInitialization, processAfterInitialization, processBeforeInitialization
-
Field Details
-
DEFAULT_RESET_BEAN_NAME
The default reset bean name ofApplicationEventMulticaster
.The original bean name of
ApplicationEventMulticaster
is"applicationEventMulticaster"
- See Also:
-
AbstractApplicationContext.APPLICATION_EVENT_MULTICASTER_BEAN_NAME
- Constant Field Values
-
RESET_BEAN_NAME_PROPERTY_NAME
@ConfigurationProperty(defaultValue="applicationEventMulticaster_ORIGINAL", description="The property name of the reset bean name of ApplicationEventMulticaster") public static final String RESET_BEAN_NAME_PROPERTY_NAMEThe property name of the reset bean name ofApplicationEventMulticaster
- See Also:
-
-
Constructor Details
-
InterceptingApplicationEventMulticasterProxy
public InterceptingApplicationEventMulticasterProxy(org.springframework.core.env.Environment environment)
-
-
Method Details
-
getResetBeanName
-
addApplicationListener
public void addApplicationListener(org.springframework.context.ApplicationListener<?> listener) - Specified by:
addApplicationListener
in interfaceorg.springframework.context.event.ApplicationEventMulticaster
-
addApplicationListenerBean
- Specified by:
addApplicationListenerBean
in interfaceorg.springframework.context.event.ApplicationEventMulticaster
-
removeApplicationListener
public void removeApplicationListener(org.springframework.context.ApplicationListener<?> listener) - Specified by:
removeApplicationListener
in interfaceorg.springframework.context.event.ApplicationEventMulticaster
-
removeApplicationListenerBean
- Specified by:
removeApplicationListenerBean
in interfaceorg.springframework.context.event.ApplicationEventMulticaster
-
removeApplicationListeners
public void removeApplicationListeners(Predicate<org.springframework.context.ApplicationListener<?>> predicate) - Specified by:
removeApplicationListeners
in interfaceorg.springframework.context.event.ApplicationEventMulticaster
-
removeApplicationListenerBeans
- Specified by:
removeApplicationListenerBeans
in interfaceorg.springframework.context.event.ApplicationEventMulticaster
-
removeAllListeners
public void removeAllListeners()- Specified by:
removeAllListeners
in interfaceorg.springframework.context.event.ApplicationEventMulticaster
-
multicastEvent
public void multicastEvent(org.springframework.context.ApplicationEvent event) - Specified by:
multicastEvent
in interfaceorg.springframework.context.event.ApplicationEventMulticaster
-
multicastEvent
public void multicastEvent(org.springframework.context.ApplicationEvent event, org.springframework.core.ResolvableType eventType) - Specified by:
multicastEvent
in interfaceorg.springframework.context.event.ApplicationEventMulticaster
-
doPostProcessAfterInitialization
protected org.springframework.context.ApplicationListener doPostProcessAfterInitialization(org.springframework.context.ApplicationListener bean, String beanName) throws org.springframework.beans.BeansException Description copied from class:GenericBeanPostProcessorAdapter
Adapter BeanPostProcessor#postProcessAfterInitialization(Object, String) method , sub-type could override this method.- Overrides:
doPostProcessAfterInitialization
in classGenericBeanPostProcessorAdapter<org.springframework.context.ApplicationListener>
- Parameters:
bean
- Bean ObjectbeanName
- Bean Name- Returns:
- Bean Object
- Throws:
org.springframework.beans.BeansException
- See Also:
-
BeanPostProcessor.postProcessAfterInitialization(Object, String)
-
setTaskExecutor
-
getTaskExecutor
-
setBeanFactory
public void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory) throws org.springframework.beans.BeansException - Specified by:
setBeanFactory
in interfaceorg.springframework.beans.factory.BeanFactoryAware
- Throws:
org.springframework.beans.BeansException
-