1 根據(jù)class名獲取代理對(duì)象,clazz.newInstance();
? 設(shè)置代理目標(biāo)和代理對(duì)象。
2 代理對(duì)象執(zhí)行接口中的方法doMethod時(shí)調(diào)用method.invoke(target,args);
proxy UndeclaredThrowableException
1 根據(jù)class名獲取代理對(duì)象,clazz.newInstance();
? 設(shè)置代理目標(biāo)和代理對(duì)象。
2 代理對(duì)象執(zhí)行接口中的方法doMethod時(shí)調(diào)用method.invoke(target,args);
proxy UndeclaredThrowableException