mirror of
https://gitee.com/durcframework/SOP.git
synced 2025-08-11 12:56:28 +08:00
修复当objClass被代理后,获取不到interface BUG
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
## 日常更新
|
||||
|
||||
- 2025-07-22: 修复当objClass被代理后,获取不到interface BUG
|
||||
- 2025-06-15:新增帮助文档管理。有升级SQL,见:[sop-20250615.sql](./upgrade/sop-20250615.sql)
|
||||
- 2025-06-11:java-sdk添加文件下载示例
|
||||
- 2025-06-01:OpenContext添加charset字段
|
||||
|
@@ -99,7 +99,15 @@ public class ApiRegister {
|
||||
}*/
|
||||
|
||||
Set<Method> cache = new HashSet<>();
|
||||
Class<?>[] interfaces = objClass.getInterfaces();
|
||||
Set<Class<?>> interfaceSet = new HashSet<>();
|
||||
Class<?> current = objClass;
|
||||
while (current != null) {
|
||||
for (Class<?> iface : current.getInterfaces()) {
|
||||
interfaceSet.add(iface);
|
||||
}
|
||||
current = current.getSuperclass();
|
||||
}
|
||||
Class<?>[] interfaces = interfaceSet.toArray(new Class<?>[0]);
|
||||
for (Class<?> interfaceClass : interfaces) {
|
||||
for (Method method : interfaceClass.getMethods()) {
|
||||
Open open = method.getAnnotation(Open.class);
|
||||
|
Reference in New Issue
Block a user