org.springframework.context.event
Interface SmartApplicationListener

All Superinterfaces:
ApplicationListener<ApplicationEvent>, EventListener, Ordered
All Known Implementing Classes:
GenericApplicationListenerAdapter, SourceFilteringListener

public interface SmartApplicationListener
extends ApplicationListener<ApplicationEvent>, Ordered

Extended variant of the standard ApplicationListener interface, exposing further metadata such as the supported event type.

Since:
3.0
Author:
Juergen Hoeller

Field Summary
 
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
 
Method Summary
 boolean supportsEventType(Class<? extends ApplicationEvent> eventType)
          Determine whether this listener actually supports the given event type.
 boolean supportsSourceType(Class<?> sourceType)
          Determine whether this listener actually supports the given source type.
 
Methods inherited from interface org.springframework.context.ApplicationListener
onApplicationEvent
 
Methods inherited from interface org.springframework.core.Ordered
getOrder
 

Method Detail

supportsEventType

boolean supportsEventType(Class<? extends ApplicationEvent> eventType)
Determine whether this listener actually supports the given event type.


supportsSourceType

boolean supportsSourceType(Class<?> sourceType)
Determine whether this listener actually supports the given source type.