/*
* Created on 2004-9-24
*
* TODO To change the template for this generated file go to
* Window - Preferences - Java - Code Style - Code Templates
*/
package cn.cpX.Parco.AddMethod;
import java.lang.reflect.*;
import javassist.*;
/**
* @author cpX.Parco
*
* TODO To change the template for this generated type comment go to
* Window - Preferences - Java - Code Style - Code Templates
*/
public class AddMethod {
/**
*
*/
public AddMethod() {
super();
// TODO Auto-generated constructor stub
}
private static void addMethod(CtClass clas)
{
try
{
String strOldMethod = "outputHello";
String strNewMethod = strOldMethod + "2";
/*
* Created on 2004-9-24
*
* TODO To change the template for this generated file go to
* Window - Preferences - Java - Code Style - Code Templates
*/
package cn.cpX.Parco.AddMethod;
/**
* @author cpX.Parco
*
* TODO To change the template for this generated type comment go to
* Window - Preferences - Java - Code Style - Code Templates
*/
public class SayHello {
/**
*
*/
public SayHello() {
super();
// TODO Auto-generated constructor stub
}
public void outputHello()
{