-
Hi! Using this Java program: import java.lang.reflect.Method;
public class Repro {
public static void main (String [] args) {
Class x = String.class;
Method[] methods = x.getMethods();
for (Method m: methods) {
System.out.println(m);
}
}
} I am able to see the methods:
in a native image compiled from this Java program, if I provide the following reflection config: [{"name" : "java.lang.String",
"allPublicMethods" : true}] However, I would like to keep my program small and want to make available I tried: [{"name" : "java.lang.String",
"methods": [{"name": "notify"}]}] but this results in an error message:
So, how do I make available the |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I may have found a solution. When I only include
|
Beta Was this translation helpful? Give feedback.
I may have found a solution. When I only include
String
without any other methods and alsonotify
from Object, I see them both in the native image: