int a;
public void show(){
System.out.println("kkk");
}
}
public static class kk{
static File1 fe(){
System.out.println("kk");
return new File1(){
public void get(){
System.out.println("kk58");
}
};
}
public static void main(String[] args) throws NoSuchMethodException, SecurityException, IllegalAccessException, IllegalArgumentException, InvocationTargetException, InstantiationException {
File1 f;
Class c=fe().getClass();
Method m=c.getMethod("get", null);
m.invoke(c.newInstance());
m=c.getMethod("show");
m.invoke(c.newInstance());
/*
File1 f;
Class c=new File1().getClass(); //必需用返回的内部类
Method m=c.getMethod("get", null);
m.invoke(c.newInstance());*/
}
}