@@ -127,7 +127,7 @@ protected void register(BeanDefinitionRegistry registry, ConfigurableListableBea
127127 .containsBeanDefinition (AnnotationConfigUtils .CONFIGURATION_ANNOTATION_PROCESSOR_BEAN_NAME )) {
128128 // Switch off the ConfigurationClassPostProcessor
129129 this .context .registerBean (AnnotationConfigUtils .CONFIGURATION_ANNOTATION_PROCESSOR_BEAN_NAME ,
130- DummyProcessor .class , () -> new DummyProcessor () );
130+ DummyProcessor .class , DummyProcessor :: new );
131131 // But switch on other annotation processing
132132 AnnotationConfigUtils .registerAnnotationConfigProcessors (this .context );
133133 }
@@ -137,7 +137,7 @@ protected void register(BeanDefinitionRegistry registry, ConfigurableListableBea
137137
138138 if (ClassUtils .isPresent ("com.google.gson.Gson" , null ) && "gson" .equals (preferredMapper )) {
139139 if (this .context .getBeanFactory ().getBeanNamesForType (Gson .class , false , false ).length == 0 ) {
140- this .context .registerBean (Gson .class , () -> new Gson () );
140+ this .context .registerBean (Gson .class , Gson :: new );
141141 }
142142 this .context .registerBean (JsonMapper .class , () -> new ContextFunctionCatalogAutoConfiguration .JsonMapperConfiguration ().jsonMapper (this .context ));
143143 }
@@ -183,7 +183,7 @@ && new ClassPathResource(basePackage.replace(".", "/")).exists()) {
183183 ConversionService conversionService = new DefaultConversionService ();
184184 return new SimpleFunctionRegistry (conversionService , messageConverter , this .context .getBean (JsonMapper .class ));
185185 });
186- this .context .registerBean (FunctionProperties .class , () -> new FunctionProperties () );
186+ this .context .registerBean (FunctionProperties .class , FunctionProperties :: new );
187187 this .context .registerBean (FunctionRegistrationPostProcessor .class ,
188188 () -> new FunctionRegistrationPostProcessor (this .context .getAutowireCapableBeanFactory ()
189189 .getBeanProvider (FunctionRegistration .class )));
@@ -199,7 +199,7 @@ private void performPreinitialization() {
199199
200200 @ Override
201201 public void run () {
202- runSafely (() -> new DefaultFormattingConversionService () );
202+ runSafely (DefaultFormattingConversionService :: new );
203203 }
204204
205205 public void runSafely (Runnable runnable ) {
0 commit comments