BAEL-5451 Code for the Finding All Beans with a Custom Annotation article (#12143)

This commit is contained in:
thibaultfaure
2022-06-10 17:29:16 +02:00
committed by GitHub
parent 766b24eab8
commit 58369d3229
16 changed files with 285 additions and 0 deletions

View File

@@ -0,0 +1,15 @@
package com.baeldung.countingbeans.latestsspring;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@Configuration
public class MyConfigurationBean {
@Bean
@MyCustomAnnotation
MyService myService() {
return new MyService();
}
}