getFromSpringFactories() — spring-boot Function Reference
Architecture documentation for the getFromSpringFactories() function in DefaultApplicationContextFactory.java from the spring-boot codebase.
Entity Profile
Dependency Diagram
graph TD 5c2cbdf1_f6e3_a87b_1802_1f936d1199f9["getFromSpringFactories()"] 42f9d9ca_f8b6_9dd6_021c_5c1d1ea32faa["getEnvironmentType()"] 42f9d9ca_f8b6_9dd6_021c_5c1d1ea32faa -->|calls| 5c2cbdf1_f6e3_a87b_1802_1f936d1199f9 b54e5499_085d_a88f_2c5e_a914d47d0012["createEnvironment()"] b54e5499_085d_a88f_2c5e_a914d47d0012 -->|calls| 5c2cbdf1_f6e3_a87b_1802_1f936d1199f9 1b326aab_1084_bfe0_55a1_abca74384bd0["create()"] 1b326aab_1084_bfe0_55a1_abca74384bd0 -->|calls| 5c2cbdf1_f6e3_a87b_1802_1f936d1199f9 style 5c2cbdf1_f6e3_a87b_1802_1f936d1199f9 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
core/spring-boot/src/main/java/org/springframework/boot/DefaultApplicationContextFactory.java lines 76–88
@Contract("_, _, !null -> !null")
private <T> @Nullable T getFromSpringFactories(@Nullable WebApplicationType webApplicationType,
BiFunction<ApplicationContextFactory, @Nullable WebApplicationType, @Nullable T> action,
@Nullable Supplier<T> defaultResult) {
for (ApplicationContextFactory candidate : SpringFactoriesLoader.loadFactories(ApplicationContextFactory.class,
getClass().getClassLoader())) {
T result = action.apply(candidate, webApplicationType);
if (result != null) {
return result;
}
}
return (defaultResult != null) ? defaultResult.get() : null;
}
Domain
Subdomains
Called By
- create()
- createEnvironment()
- getEnvironmentType()
Source
Frequently Asked Questions
What does getFromSpringFactories() do?
getFromSpringFactories() is a function in the spring-boot codebase.
What calls getFromSpringFactories()?
getFromSpringFactories() is called by 3 function(s): create, createEnvironment, getEnvironmentType.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free