feat:增加自动完成数据源
This commit is contained in:
parent
1907d4a055
commit
d53dfaffb0
@ -348,14 +348,15 @@ public class BeanProperty {
|
|||||||
*/
|
*/
|
||||||
private static List<BeanProperty> parseExtras(Class<?> clazz, List<BeanProperty> origin) {
|
private static List<BeanProperty> parseExtras(Class<?> clazz, List<BeanProperty> origin) {
|
||||||
List<BeanProperty> result = new ArrayList<>();
|
List<BeanProperty> result = new ArrayList<>();
|
||||||
|
MergedAnnotations annotations = MergedAnnotations.from(clazz);
|
||||||
// 包含properties
|
// 包含properties
|
||||||
if (clazz.isAnnotationPresent(Properties.class)) {
|
if (annotations.isPresent(Properties.class)) {
|
||||||
Properties properties = clazz.getAnnotation(Properties.class);
|
Properties properties = annotations.get(Properties.class).synthesize();
|
||||||
for (Property prop : properties.value()) {
|
for (Property prop : properties.value()) {
|
||||||
applyExtraProperty(result, origin, prop);
|
applyExtraProperty(result, origin, prop);
|
||||||
}
|
}
|
||||||
} else if (clazz.isAnnotationPresent(Property.class)) {
|
} else if (annotations.isPresent(Property.class)) {
|
||||||
applyExtraProperty(result, origin, clazz.getAnnotation(Property.class));
|
applyExtraProperty(result, origin, annotations.get(Property.class).synthesize());
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user