1. 程式人生 > >eclipse中自建實體類存在但是導入的包報錯cannot be resolved

eclipse中自建實體類存在但是導入的包報錯cannot be resolved

nbsp lazy net 沒有 文章 using debug switch ips

摘自:https://blog.csdn.net/lazy_p/article/details/7452846 ‘Clean’ Your Eclipse Project: Go to Project > Clean in Eclipse [This seems to work for me] Refresh your project folder (right click on your project > refresh) Re-build your project Clean your builds (If using Ant or Maven – clean your builds) Recreate your project in Eclipse ‘Switch’ Workspace – then Switch back (Eg Change to Debug, then switch back to Java) ‘Switch’ Workspace – then Switch back (Eg Change to Debug, then switch back to Java) Remove and re-add your JRE: 1. Right Click on your project > properties 2. Click on the Libraries tab 3. Click on the JRE 4. Click remove, then OK 5. Repeat 1-3 again, but add the JRE again --------------------- 其中 project 中 clean功能解釋如下: 由於eclipse的編譯是基於時間戳的判斷機制的。因此當你按build all的時候有些eclipse認為時間戳沒有改變的類不會被編譯。因此你可以先clean一下再編譯。這個時候eclipse會將所有的以前編譯信息清除然後編譯。 eclipse --->project ----->clean... 選項將工程中的.class文件刪除,同時重新編譯工程,類似於jbuild中的rebuild --------------------- 本文來自 映月文章 的CSDN 博客 ,全文地址請點擊:https://blog.csdn.net/u010715393/article/details/42125505?utm_source=copy

eclipse中自建實體類存在但是導入的包報錯cannot be resolved