Hello, I was wondering if its possible to make an ...
# reflect
j
Hello, I was wondering if its possible to make an
internal
interface
public
? Similar to make a method or member accessible. Details in thread 🧵
I understand that reflection is risky but we have a need in this case.
I am looking to create an instance of the
internal interface
using Java’s Proxy mechanism at runtime.
I am getting an error however:
Copy code
java.lang.IllegalArgumentException: interface com.thirdparty.CustomInterface is not visible from class loader
Actually I think I solved this. Wrong class loader was used in the proxy and now its working. Thanks!
j
Yeah
internal
is public in bytecode
🙏 1