添加枚举字段注解扫描注入

This commit is contained in:
2025-05-12 18:14:38 +08:00
parent a872e4e1d1
commit 410cd565da
4 changed files with 198 additions and 1 deletions

View File

@@ -18,7 +18,11 @@ public class ReflectionsConfig {
@Bean("reflections")
Reflections reflections() {
return new Reflections(new ConfigurationBuilder()
.addScanners(Scanners.MethodsAnnotated, Scanners.SubTypes, Scanners.TypesAnnotated)
.addScanners(
Scanners.MethodsAnnotated,
Scanners.SubTypes,
Scanners.FieldsAnnotated,
Scanners.TypesAnnotated)
.forPackages("quant.rich.emoney"));
}