Thank you Shiba,
I think I should be fine with your explanations.
View the original post :
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3838161#3838161
Reply to the post :
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3838161
--
If you want to copy a whole method body, you can simply add
a CtMethod from class A to class B.
If you want to insert only part of a method body, you must use
CodeIterator. For example,
CtClass b = ... ;
CtMethod m = b.getMethod(...);
MethodInfo minfo = m.getMethodInfo();
CodeAttribute ca = minf