how to find a caller of a method
hi all,i have a method in a class and that method is being called from many different classes.Inside that method , I want to know who is the caller of the method.how can i find that. any help would be appreciated.Thanks,Dhanasekaran Vivekanandhan
[288 byte] By [
dhana007a] at [2007-11-27 2:21:22]

# 2
look at the method Thread.currentThread.getStackTrace(), and the class StackTraceElement. you can work out the rest yourself, hopefullybut if your code depends on this knowledge, I reckon you've got design problems