93. @ComponentScan(
excludeFilters = {
@ComponentScan.Filter(
type = FilterType.ANNOTATION,
value = Facade.class
),
@ComponentScan.Filter(
type = FilterType.ANNOTATION,
value = Service.class
)
}
)
適用例
public class Main {
public static void main(String[] args) {
new SpringApplicationBuilder(Main.class)
.initializers(
new FacadeInitializer()
)
.run(args);
}
}
93
101. @ComponentScan(
excludeFilters = {
@ComponentScan.Filter(
type = FilterType.ANNOTATION,
value = Repository.class
),
@ComponentScan.Filter(
type = FilterType.ANNOTATION,
value = Facade.class
),
@ComponentScan.Filter(
type = FilterType.ANNOTATION,
value = Service.class
)
}
)
public class Main {
public static void main(String[] args) {
new SpringApplicationBuilder(Main.class)
.initializers(
new RepositoryInitializer(),
new FacadeInitializer()
)
.run(args);
}
}
101
適用例