Hello,
How to get caller of the method (as object, which called it, or as object of the same class) ?
For instance, I can use
Throwable tracer = new Throwable();
tracer.fillInStackTrace();
and then analize this stack trace, but in this case I have to use Java Reflection to make object of the class in stack (because stack contains strings). Is there any other way to do it?
Which stack is used by IDE's debuggers, do they use the same StackTraceElement and JavaReflection?
Thanks in advance,
Maxym