英文:
Eclipse java debug can't edit code while running
问题
抱歉,我只能返回中文翻译的部分,以下是您要的翻译内容:
我不确定是怎么发生的,但是我的Eclipse Java IDE中的许多设置都乱了。我猜这也是为什么在代码运行时进行更改不再起作用的原因。当我以调试模式运行它,进行一些更改并保存时,程序中并没有发生变化。如果我在代码运行时进行一些无法更改的操作,比如添加一个方法或一个字段,我也没有收到任何警告消息。有谁知道问题是什么?我可能可以重置所有设置,但我也有一些想保留的设置。
英文:
I'm not sure how it happened but a whole bunch of settings in my Eclipse java ide are messed up. I am assuming that this is also the reason why changing code while its running doesn't work anymore for me. When I run it in debug mode, change something and save it the changes are not happening in the program. I also dont get any warm messages if I do something that can't be changed while the code is running like adding a method or a field. Does anyone know what the problem is? I could probably reset all my settings but I also have some settings that I want to keep.
答案1
得分: 1
两件事要检查:
- 确保在项目菜单下选择了“自动构建”;
- 确保你正在使用1.4或更高版本的Java(窗口菜单 > 首选项 > Java > 已安装的JRE)。
Eclipse要求同时满足这两个条件才能执行热交换调试。
英文:
Two things to check:
- Ensure that Build Automatically is selected under the Project menu; and
- Make sure you're using Java version 1.4 or greater (Window menu > Preferences > Java > Installed JREs.
Eclipse requires both of these conditions in order to perform hotswap debugging.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论