1. 程式人生 > >eclipse反編譯class檔案,全配置

eclipse反編譯class檔案,全配置

昨天從eclipse官網下了eclipse-jee-luna-R-win32版使用,其中關於反編譯設定,怎麼查資料,配置,都不管用,最後綜合了部分人的答案,才搞定,

這裡我歸納下,就4步搞定,前3步,幾乎大家的部落格都這麼說,唯有第4步,才在一個很偏的部落格上找到

準備檔案

net.sf.jadclipse_3.3.0.jar   (百度上說,此包要與eclipse版本相匹配才能使用,此包我從一個於2012年上傳的網點上下載的。。坑人)

jad.exe

第一步:

將 net.sf.jadclipse_3.3.0.jar 放到eclipse目錄中的 dropins 或 plugins資料夾下都行,重啟eclipse

第二步:

從eclipse 選單欄 Window->Preferences->Java->JadClipse,在Path to decompiler中填寫反編譯工具jad的全路徑名,如:D:\Program Files\xxxxxxxx\jad.exe

第三步:

從eclipse 選單欄 Windows -> Perference -> General -> Editors -> File Associations

在File Type 下選擇*.class,然後在 Associated Editors下選擇JadClipse Class File Viewer,並點選右側的 default 按鈕,設定為預設編輯器

(結束配置,看看能不能反編譯成功)

第四步:

從eclipse 選單欄 Windows -> Perference -> General -> Editors -> File Associations

在File Type 下選擇 *.class without source,(若沒有選項,就add按鈕自己新增 *.class without source 型別),然後在 Associated Editors,選擇JadClipse Class File Viewer,並點選右側的default按鈕,將 JadClipse Class File Viewer 設定為  *.class without source 的預設編輯器,沒有就add

以上4步 成功解決 eclipse-jee-indigo-SR2-win32 和 eclipse-jee-luna-R-win32 兩個版本的反編譯

額外 給大家介紹一款國外的綠色反編譯軟體 Java Decompiler 

不知道上傳檔案在哪,大家自己搜下相關檔案,下載吧