
It is possible to call Private method of a class using the Refletion API:
Method myMethod = MyClass.class.getDeclaredMethod("myMethod", ...);
myMethod.setAccessible(true);
myMethod.invoke(...);
Above snippet of code can be used to call private method, of a class
No comments:
Post a Comment