Hello is there a way to know the caller class name of a function, specifically for a Java-GWT application?
Thread.currentThread
is not supported in GWT (remember that java code gets compiled to javascript), so this is a possible duplicate of:
How do you find out the caller function in JavaScript?
In GWT you'd simply write a jsni wrapper:
public static native void whosMyCaller() /*-{
$wnd.alert(arguments.callee.caller.toString());
}-*/;
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With