public interface

ApplicationEventMulticaster

org.springframework.context.event.ApplicationEventMulticaster
Known Indirect Subclasses

Class Overview

Interface to be implemented by objects that can manage a number of ApplicationListener objects, and publish events to them.

An ApplicationEventPublisher, typically a Spring ApplicationContext, can use an ApplicationEventMulticaster as a delegate for actually publishing events.

Summary

Public Methods
abstract void addApplicationListener(ApplicationListener listener)
Add a listener to be notified of all events.
abstract void addApplicationListenerBean(String listenerBeanName)
Add a listener bean to be notified of all events.
abstract void multicastEvent(ApplicationEvent event)
Multicast the given application event to appropriate listeners.
abstract void removeAllListeners()
Remove all listeners registered with this multicaster.
abstract void removeApplicationListener(ApplicationListener listener)
Remove a listener from the notification list.
abstract void removeApplicationListenerBean(String listenerBeanName)
Remove a listener bean from the notification list.

Public Methods

public abstract void addApplicationListener (ApplicationListener listener)

Add a listener to be notified of all events.

Parameters
listener the listener to add

public abstract void addApplicationListenerBean (String listenerBeanName)

Add a listener bean to be notified of all events.

Parameters
listenerBeanName the name of the listener bean to add

public abstract void multicastEvent (ApplicationEvent event)

Multicast the given application event to appropriate listeners.

Parameters
event the event to multicast

public abstract void removeAllListeners ()

Remove all listeners registered with this multicaster.

After a remove call, the multicaster will perform no action on event notification until new listeners are being registered.

public abstract void removeApplicationListener (ApplicationListener listener)

Remove a listener from the notification list.

Parameters
listener the listener to remove

public abstract void removeApplicationListenerBean (String listenerBeanName)

Remove a listener bean from the notification list.

Parameters
listenerBeanName the name of the listener bean to add