I want to find instances of a class and modify some of the properties of one of the instance. But i cannot find a way to break in a block of code that references that class, so that it may appear in the variables view. What i'm thinking is to pause the jvm and the search for instances of MyClass but i can't find a tool to do this. Someone got an idea ?
Asked
Active
Viewed 4,824 times
3
-
The eclipse debugger lets you do that. If your class has the right setters, you can do it in the `Expression` view using the object reference and calling the setters (of course, I would hate doing this). – Luiggi Mendoza Jun 16 '13 at 23:12
-
Check this: http://stackoverflow.com/questions/5268998/find-methods-calls-in-eclipse-project/13966182 – Vishnu Prasad Kallummel Jun 17 '13 at 11:00
1 Answers
3
I would open the call-hierarchie of the constructor of this class. Mark the constructor, left click, call hierarchie. That will give you a list wherever the object gets instantiated.

Axel Amthor
- 10,980
- 1
- 25
- 44
-
3How can I search this if the class does not have an explicit constructor? – Montecarlo Jan 09 '14 at 18:48
-
1@CarlosSantos (might be a little late) but you can right-click on the class itself and show call hierarchy too, it will show all the constructors including implicit. – Jonah Graham Nov 12 '15 at 16:40