Class ApplicationPreparedEvent
java.lang.Object
java.util.EventObject
org.springframework.context.ApplicationEvent
org.springframework.boot.context.event.SpringApplicationEvent
org.springframework.boot.context.event.ApplicationPreparedEvent
- All Implemented Interfaces:
Serializable
Event published as when a
SpringApplication
is starting up and the
ApplicationContext
is fully prepared but not refreshed. The bean definitions
will be loaded and the Environment
is ready for use at this stage.- Since:
- 1.0.0
- Author:
- Dave Syer
- See Also:
-
Field Summary
Fields inherited from class java.util.EventObject
source
-
Constructor Summary
ConstructorDescriptionApplicationPreparedEvent
(SpringApplication application, String[] args, ConfigurableApplicationContext context) Create a newApplicationPreparedEvent
instance. -
Method Summary
Modifier and TypeMethodDescriptionReturn the application context.Methods inherited from class org.springframework.boot.context.event.SpringApplicationEvent
getArgs, getSpringApplication
Methods inherited from class org.springframework.context.ApplicationEvent
getTimestamp
Methods inherited from class java.util.EventObject
getSource, toString
-
Constructor Details
-
ApplicationPreparedEvent
public ApplicationPreparedEvent(SpringApplication application, String[] args, ConfigurableApplicationContext context) Create a newApplicationPreparedEvent
instance.- Parameters:
application
- the current applicationargs
- the arguments the application is running withcontext
- the ApplicationContext about to be refreshed
-
-
Method Details
-
getApplicationContext
Return the application context.- Returns:
- the context
-