在Eclipse中调试时查找类的所有实例 [英] Find all instances of a class while debugging in Eclipse
问题描述
MyClass123
对象在调试窗口。 这是甚么可能吗?是否在Eclipse或任何插件中提供?
是的,可以在标准的eclipse调试器中。请参阅这里。调试时,右键单击变量视图中的变量条目,然后单击所有实例:
这将打开一个这样的列表:
I was wondering if the way Java/JVM works means debugging tools like Eclipse can show me a list of all instances of a given class? I suppose one could write some reflection code but I don't want to break execution at the same place every time... rather I;d like to break execution and bring up a list of all MyClass123
objects in a debug window.
Is this even possible? Is it provided in Eclipse or any plugin?
Yes, it's possible in the standard eclipse debugger. See here. While debugging, right-click on a variable entry in the 'Variables View' and then click on 'All Instances':
This will open a list like this:
这篇关于在Eclipse中调试时查找类的所有实例的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!