Rename ApplicationContextAotGenerator entry point

Closes gh-28927
This commit is contained in:
Stephane Nicoll
2022-08-05 10:17:38 +02:00
parent 2475523e19
commit 2cc4486e3d
4 changed files with 13 additions and 12 deletions

View File

@@ -36,14 +36,15 @@ import org.springframework.javapoet.ClassName;
public class ApplicationContextAotGenerator {
/**
* Refresh the specified {@link GenericApplicationContext} and generate the
* necessary code to restore the state of its {@link BeanFactory}, using the
* specified {@link GenerationContext}.
* @param applicationContext the application context to handle
* Process the specified {@link GenericApplicationContext} instance
* ahead-of-time using the specified {@link GenerationContext}.
* <p>Return the {@link ClassName} of the {@link ApplicationContextInitializer}
* to use to restore an optimized state of the application context.
* @param applicationContext the non-refreshed application context to handle
* @param generationContext the generation context to use
* @return the class name of the {@link ApplicationContextInitializer} entry point
*/
public ClassName generateApplicationContext(GenericApplicationContext applicationContext,
public ClassName processAheadOfTime(GenericApplicationContext applicationContext,
GenerationContext generationContext) {
applicationContext.refreshForAotProcessing();
DefaultListableBeanFactory beanFactory = applicationContext.getDefaultListableBeanFactory();