0

Is it possible to get project from a *.Jar For ex. to Eclipse?

I see code with "jd-gui", but program have +/- 700 classes, so copy/paste will take a lot of time.

I tried : (Import>General>Archive File>... ), But this did not work.

4
  • Have you considered importing the jar file as a library? Commented Apr 17, 2015 at 21:10
  • Yes... I have this : scr.hu/31ua/m92zq Commented Apr 17, 2015 at 21:16
  • You'll have to download a source archive or decompile the classes in the jar. Commented Apr 17, 2015 at 21:17
  • Decompile the classes in the jar. With what program ? Commented Apr 17, 2015 at 21:21

2 Answers 2

0

Understanding that most jar files don't contain source, you'll have to either specifically obtain a source jar, decompile the class files in the jar or download an archive with source.

If you have a source jar or decompiled jar, from another answer:

New Java Project -> Java settings -> Source -> Link source (Source folder). There I added my decompiled jar and it was imported correctly 
Sign up to request clarification or add additional context in comments.

Comments

0

It depends on if you need to modify the existing source or just include/use the library. If you need to modify the source, I'd recommend either tracking down whoever build the library and see if the source is accessible or alternatively try to run a reverse compiler on it... but that being said, if it was obfuscated, it may be pretty difficult to read or trace.

Or, alternatively if you just need to utilize the library, you could just include it as a source directly. Depending how your project is organized, it should be be a simple matter to add it to the source directory (http://www.wikihow.com/Add-JARs-to-Project-Build-Paths-in-Eclipse-%28Java%29)

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.