ApplicationStartedEvent Class — spring-boot Architecture
Architecture documentation for the ApplicationStartedEvent class in ApplicationStartedEvent.java from the spring-boot codebase.
Entity Profile
Relationship Graph
Source Code
core/spring-boot/src/main/java/org/springframework/boot/context/event/ApplicationStartedEvent.java lines 36–75
@SuppressWarnings("serial")
public class ApplicationStartedEvent extends SpringApplicationEvent {
private final ConfigurableApplicationContext context;
private final @Nullable Duration timeTaken;
/**
* Create a new {@link ApplicationStartedEvent} instance.
* @param application the current application
* @param args the arguments the application is running with
* @param context the context that was being created
* @param timeTaken the time taken to start the application
* @since 2.6.0
*/
public ApplicationStartedEvent(SpringApplication application, String[] args, ConfigurableApplicationContext context,
@Nullable Duration timeTaken) {
super(application, args);
this.context = context;
this.timeTaken = timeTaken;
}
/**
* Return the application context.
* @return the context
*/
public ConfigurableApplicationContext getApplicationContext() {
return this.context;
}
/**
* Return the time taken to start the application, or {@code null} if unknown.
* @return the startup time
* @since 2.6.0
*/
public @Nullable Duration getTimeTaken() {
return this.timeTaken;
}
}
Domain
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free