How to set Eclipse watchpoint to activate when object/primitive changes?

喜欢而已 提交于 2019-12-03 14:42:49

You can set a watchpoint on each field of the class you are interested in.

Alternatively, you can find all places in the source referring a certain field by using the call hierarchy (click on the field, and press Ctrl-Alt-H). This has the advantage that you are not only finding where the field is accessed in a particular execution of the program, but for all possible executions.

Note that neither method will notice if the field is accessed using reflection.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!