(String[] args)
| 8 | |
| 9 | public class AopMain { |
| 10 | public static void main(String[] args) throws Exception { |
| 11 | MyAdvice myAdvice = new MyAdvice(); |
| 12 | |
| 13 | Class myClass = Class.forName("com.fastcampus.ch3.aop.MyClass"); |
| 14 | Object obj = myClass.newInstance(); |
| 15 | |
| 16 | for(Method m : myClass.getDeclaredMethods()) { |
| 17 | myAdvice.invoke(m, obj, null); |
| 18 | } |
| 19 | } |
| 20 | } |
| 21 | |
| 22 | class MyAdvice { |