class name = Outer$1という名前のclass name
methods name = Object's methods + added method
public class Outer {
public static void main(String[] args) {
var obj = new Object() {
public void test() {
System.out.println("i am test method");
}
};
System.out.println(obj.getClass());
Method m[] = obj.getClass().getMethods();
for(Method mc:m) {
System.out.println(mc);
}
}
}
class com.mycompany.mavenproject1.Outer$1
public void com.mycompany.mavenproject1.Outer$1.test()
public final native void java.lang.Object.wait(long) throws java.lang.InterruptedException
public final void java.lang.Object.wait(long,int) throws java.lang.InterruptedException
public final void java.lang.Object.wait() throws java.lang.InterruptedException
public boolean java.lang.Object.equals(java.lang.Object)
public java.lang.String java.lang.Object.toString()
public native int java.lang.Object.hashCode()
public final native java.lang.Class java.lang.Object.getClass()
public final native void java.lang.Object.notify()
public final native void java.lang.Object.notifyAll()