Support for Java Decompiling in current Eclipse IDE - eclipse

I am currently looking for the latest version of the decompiler plugin for Eclipse (Kepler). Does this tool still exist?
I have downloaded jd.ide.eclipse.feature_0.1.5.jar and placed it in my plugins folder for eclipse but it does not seem to work. I have also copied JAD.exe into my local file and I point to that location for Path to Decompiler in JadCliple preferences. I have also set File Associations to read *.class as JadClipse Class File Viewer to default. Is there something else I am missing here? I have read past posts on this website and I see that access to the website has been the main problem. If anyone can guide me in the right direction this would be great.
I keep getting this error, The Class File Viewer cannot handle the given input ('org.eclipse.ui.ide.FileStoreEditorInput').

Instead of using JD-GUI or other GUI based tools, you may want to consider command-line decompilers that are frequently updated like the ones below:
Procyon
CFR
Both of these (should) support new Java 8 additions and other things that JD-GUI usually fails on.

Related

Eclipse JRE Definition not including core classes

I am trying to lnclude an additional JDK (really JRE) to my eclipse project as i need to build against the IBM Java 5 JRE.
When I add the root folder of the jre it appears as if the core java class jars are not being added and only the jars in \lib\ext are being added. That is problem 1.
The next issues is I can't even manually add the jars by adding external jars to the runtime library. The reason being when I hit ok to save off the changes and then hit ok to the preferences dialog. The changes do not truly save. I open up the jre definition dialog again and only the jars in \lib\ext are there again.
Is this an eclipse bug? Is anybody finding similar results?
I'd really like to figure out where these preferences are stored so I can manually edit the file if need be.
As a side note, I have had a similar experience with not being able to save .pmd rule preferences and having to edit them manually in the backend. Though I suspect that bug is on the PMD developers.
Anyway any help on this is greatly appreciated.
Thanks.

Why we just can't download a jar file of Javadocs of SWT from the main website

For almost every library I've come to see a link of the JAVADOCS jar to be downloaded, plain and simple. Why There is no jar for SWT ? and if there is why it's not on their website ..
Please note that I know there is a version in Eclipse help, and there is an online version, which I can't link to cause It doesn't validate cause it's in php ! no Index.html found
Though that's not what I'm looking for I tried it, I'm using SWT.jar and I want to attach the javadocs jar to it so when CTRL+Space and highlight a method I just see the docs right away beside etc you know..
Anyway Because I think SWT is so great I feel like there is a simple way to do that and I just can't see it maybe. if there is nothing I think I should file a feature request or somethin' to them.
Ok I kinda knew this question was not going to get much interest, so I gave it another try and I came back cause I don't want anyone to waste 1 hour of trying to figure out something like that..
Download the swt zip
Go to eclipse and load existing project
you'll find src.zip in that project
unzip src.zip and copy the folder "org" org\eclipse\swt..
paste that folder in src (inside the project)
select org folder in eclipse then go to project >> generate javadocs
If you're in windows you probably going to press on (Configure) to pick up the Javadoc.exe file it's in the C:\programFiles\java\jdk-xyz\bin\
choose where you want to drop the doc files, next then finish
ok, just go to the files and zip it, P.S zip the files don't zip the folder which contains the files cause when you load the docs as archive and validate it won't see the index.html
if you want to know how to load the archive, google it's in (in project properties>> java buildpath >> libraries tab >> swt jar >> add jar >> add your SWT.jar then expand and edit the javadoc location..
That was Robo detailed I know, I just don't want someone to read this and still can't do it
The suggested way to develop SWT apps is by following the instructions at Developing SWT applications using Eclipse. Each download page of eclipse includes an SWT section with SWT source complete zips.
The second way as mentioned is to look in your eclipse/plugins directory and use the 2 arch compatible jars provided there:
org.eclipse.swt.gtk.linux.x86_64_3.7.0.v3735b.jar
org.eclipse.swt.gtk.linux.x86_64.source_3.7.0.v3735b.jar
The source jar can be attached so as to provide javadoc. The javadoc (for most of the API shipped with eclipse) is stored in the eclipse/plugins/org.eclipse.platform.doc.isv_3.7.0.v20110602-0800.jar jar. If you unzip that, it should be in reference/api
I know that Eclipse is setting up a maven repository, although a quick scan for org.eclipse.swt only found 3.6.2 binaries and source. See http://maven.eclipse.org. They're still in they trail phase.

Mysterious Eclipse javadoc problem

I had a problem with finding Java docs in Eclipse. I seem to have fixed the problem, but I'm posting this for two reasons: I would like to know why I had the problem in the first place and perhaps my method of fixing it might be useful to someone else having a similar problem.
I created a simple Java project in Eclipse (Helios on Windows 7) and selected the JavaSE-1.6 JRE. Then I created a source file and imported java.util.GregorianCalendar. When I hovered over GregorianCalendar, I was getting the message:
This element has no attached source and the Javadoc could not be found in the attached Javadoc
None of the methods of GregorianCalendar seemed to have any Javadoc, either. Other standard Java classes (even others in java.util, like ArrayList) didn't have this problem; only GregorianCalendar. Everything seemed set up properly in the project settings. The Javadoc location set in the Java Build Path was http://java.sun.com/javase/6/docs/api/.
I managed to restore correct behavior by temporarily switching to JavaSE-1.7 and then back. Evidently something got reset and all is well. While I'm happy that things are now working, I don't like being clueless as to how they got messed up in the first place.
Can anyone provide any insights into this?
I think general support relies on the presence of a src.zip in your JDK directory, which is detected when you autosearch a directory for Java installations. It could be missing. Not sure if online Javadocs are used.
I'm using Eclipse Juno on a Windows 7 64-bit (with a 32-bit JDK) but i think it will also apply to your Eclipse version:
Download JDK docs zip file to your Desktop folder;
Right-click on the file, choose Properties and unblock it;
Move the file to a location of your choice. I normally move it to the JDK folder;
Open Eclipse and go to Window->Preferences->Java->Installed JREs;
Select your JDK installation and press Edit;
Select the rt.jar file and click "Javadoc Location..." button;
Select the "Javadoc in archive" radio button;
Set the archive path by browsing to the JDK docs zip file;
Set the "Path within archive" to "docs/api" (without the quotes).
Enjoy! ;)

documentation missing in eclipse

I'm new to eclipse/java Mobile development and all the rest of the keywords.
I have just downloaded the eclipse pulsar package, and installed it, i also downloaded the 'java me sdk 3.0' and installed it and linked it in eclipse. now i can create a new midlet and i'm using the splash template as a start.
now i typed: g.drawString(...) and i have like a string argument which is supposed to be the string to display. and other three integers.
Now the problem is that there's no documentation at all. it's like you have to guess each argument is what.
I'm sure there's something called documentation right? but i don't what where is it's the sdk ? is it eclipse? where can i fix that?
even the 'string' type i couldn't find it's documentation.
EDIT:
now in my installed jres i have only jre6, though i also have installed jdk1.6.0 but it's not appearing i added it now...
But the main thing here, is that i had to download something called 'sun java wireless toolkit' which suggested to download the new feature 'sun_java_me_sdk-3_0-win.exe'. and i did, when i installed it i have a new section 'window->preferences->javame' which also contains missing configurations.
but there's a section in it called 'device management' (meaning the device that i need to work against, like standard hansets configurations) each with a set of jars. And very few jars have javadoc location set.
i know where the javadoc is now, but it's not covering all the jars i'm working with.
so to recap: i think i'm working against swt sdk and i need to link the libraries taht i'm working against to their corresponding javadoc. but not sure since it's not supposed that 'Graphics' class or 'string' class be used from this sdk and not the default java sdk 1.6.0?
i think i'll take this day to try to fix all this and really understand what libraries i'm working with and if i can download the rest of the javadocs and use them.
if it didn't work i'll go with netbeans. they say it's much easier to deploy
I did install netbeans, and the documentation is working. i saw inside netbeans that they are integrating the 'Java_ME_platform_SDK_3.0' but i don't know from where they provide the javadoc.
I have a simple walkaround that fix this problem. Just go to the library setting, you will see the javadoc of cldc11api.jar is missing, give it the same location as midp21api.jar, restart eclipse. Hope this work for you.
I don't have first-hand experience with Java ME development in Eclipse, but I will tell you how javadoc hookup works in Eclipse and you can investigate further.
Go to Window -> Preferences -> Java -> Installed JREs. You should find your Java ME install listed here.
Select it and hit Edit.
Expand various jar nodes under JRE system libraries. You will see source attachment and javadoc location.
If you don't see a location listed under javadoc, select that tree entry and hit Javadoc Location button to edit the location.
For me, using Java SE, I see location specified like this: http://java.sun.com/javase/6/docs/api/
It is possible that Eclipse simply doesn't know where to find Java ME javadoc. If you know the location, you can specify it in the above dialog. This could be a local or a remote URL.
If the location is specified and appears correct, the problem could be with network connectivity. If you are behind the proxy, make sure that it is correctly specified under Window -> Preferences -> General -> Network Connections.
my question is close to this question, you can refer to
Attach Javadoc to Eclipse for Java ME
anyway
Konstantin Komissarchik has also answered correctly to how you set the javadoc location.
Now the problem is with the 'Java_ME_platform_SDK_3.0', anyway through setting manually the configurations of javadoc location, igot it working after i restarted the eclipse with -clean argument.

Eclipse doesn't recognize lua files after installing the lua plugin

I downloaded Eclipse Classic off of the Eclipse website then the Lua Eclipse IDE plugin. I followed the install instructions but Eclipse doesn't seem to recognize or be able to understand lua files. Can someone help?
Sounds like your file types aren't associated. Click on Window/Preferences and select General/Editors/File Associations.
Add more information
Which installation guide did you follow? (Lua Eclipse Installation?)
Which OS (version)?
Which java version? (Which implementation)
Which eclipse version?
I love these kind of questions because they provide an opportunity to do a test I postponed until now...
So I downloaded the plugin package, and followed the instructions: closed Eclipse, put two jar files in the plugin folder, put the open-ldb.exe elsewhere, restarted Eclipse.
I created a generic project, added a generic file linked to an existing Lua file. When I opened the file, it was automatically identified as such, with a moon icon and correct syntax highlighting.
Using Eclipse 3.5.1 on Windows XP, BTW.
Now, I have an issue, the debugger won't start for me, I get a
Unable to connect to PDA VM
Connection refused: connect
error, not sure why (path to exe file is correct, I have another error when it is wrong).
But at least I have the Lua files recognized without problem.
I think you might want to check that in Preferences > General > Editors > File Associations, *.lua is defined and associated to the Lua editor.
Instead of opening a File you have to do the following:
Open a new LUA project.
Then import using 'File System' all files (resources and LUA files) into the project.
Now you can see and edit the LUA files. Don't know why it doesn't work by simply opening a LUA file directly.