Class ApplicationContextEvent
- java.lang.Object
- java.util.EventObject
- org.springframework.context.ApplicationEvent
- org.springframework.context.event.ApplicationContextEvent
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
ContextClosedEvent
,ContextRefreshedEvent
,ContextStartedEvent
,ContextStoppedEvent
public abstract class ApplicationContextEvent extends ApplicationEvent
Base class for events raised for anApplicationContext
.- Since:
- 2.5
- Author:
- Juergen Hoeller
- See Also:
- Serialized Form
Field Summary
Fields inherited from class java.util.EventObject
source
Constructor Summary
Constructors Constructor Description ApplicationContextEvent(ApplicationContext source)
Create a new ContextStartedEvent.
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ApplicationContext
getApplicationContext()
Get theApplicationContext
that the event was raised for.Methods inherited from class org.springframework.context.ApplicationEvent
getTimestamp
Methods inherited from class java.util.EventObject
getSource, toString
Constructor Detail
ApplicationContextEvent
public ApplicationContextEvent(ApplicationContext source)
Create a new ContextStartedEvent.- Parameters:
source
- theApplicationContext
that the event is raised for (must not benull
)
Method Detail
getApplicationContext
public final ApplicationContext getApplicationContext()
Get theApplicationContext
that the event was raised for.