Eclipse Ide



Wiki: (on the EditMe WikiFarm) /* was (on the SwikiFarm) */

EclipseEditor is an excellent open extensible IntegratedDevelopmentEnvironment (IDE), written in JavaLanguage, by InternationalBusinessMachines (IBM). It is now OpenSource.

Currently I have switched to a very interesting way of programming in WebSphereStudioApplicationDeveloper. The same pattern can be applied to EclipseIde. Here is a description of the method. The idea is to use EclipseIde in tandem with BeanShell. It gives me a very pleasant experience of programming. In the present time I work with web applications, but I think this pattern can be useful for programming inside of any framework or container (as long as web server is a container for servlets, too).

To write a new code or to fix something, I set a breakpoint in my code in Eclipse. Note that currently "my code" has no implementation for the desired feature which I'd like to program. Maybe it will be just a stub that has empty methods and will really do nothing.

BeanShell JAR should be added to the project classpath.

Then I run my application in Eclipse debugger and press all the necessary buttons in my GUI. When debugger stops on my breakpoint, my context is properly initialized. All objects (like HttpRequest?) had proper values, etc.

Next, Eclipse has a debug window named Display where you can execute code. Generally I add to the application to the "test" package a little class named "Beanshell". I run it from the Display window in the following way:

new test.Beanshell(new Object[] {someInterestingObjectCurrentlyAvailable, anotherInterestingObject, ...}, "myscript.bsh")

This class just calls BeanShell script named "myscript.bsh". First argument is available to script as "params" array.

Here the programming itself starts. Sitting on that breakpoint, I modify "myscript.bsh" and run it as many times as I like till it will do the job. Good news about BeanShell is that you have not recompile anything, your changes are available to system immediately, so your development cycle between the change and seeing it's result is minimal. All exceptions are catched inside Beanshell class.

This way you can create a BeanShell code that will implement your feature. Converting it to Java code is easy

At its core, out of the box:

And then there's the Eclipse Platform on which the Ide runs...

The Eclipse Platform is an open framework and toolkit for building IDE's (just like MozillaBrowser isn't a web browser but a web platform). Eclipse itself consists of a set of core technologies (a windowing API that works the same on Linux and Windows and a few other useful bits and pieces) a core Java Development Toolkit, and what is called the Plugin Development Kit. You can build "plugins" in either Java or other technologies (integration with ActiveX and COM is included) which can interact with each other through standard, published ExtensionPoints. It is the foundation for IBM's new commercial IDE, known as WebSphereStudioApplicationDeveloper.

Eclipse is open source under the CommonPublicLicense version 0.5 (as of November 8, 2001).

The Eclipse IDE supports several languages.

language plugins:

I've been playing around with the C/C++ IDE a bit over the holidays and it's a reasonable front-end to GNU C++. Even though they say it's only officially for Linux, I've been using it on Windows 2000 with only a few problems. I've been using MINGWIN32 for my GNU tools suite to sit beneath Eclipse. About the only thing I've not been able to do yet is to write a DLL for integration with Java (my whole reason for doing this) but that's mostly due to my inexperience with GNU C++. With a bit more work this will be fully as capable as Visual C++ and a lot cheaper :) --KyleBrown

May be a stupid question: is there a smalltalk plugin for eclipse?

I don't think the question is stupid, as there are plugins for a whole number of languages, but the answer seems to be "no" at the moment.

At OOPSLA this year, there was a presentation on Eclipse. There, some guys (from IBM, I believe) gave a short demo of their eclipse-smalltalk work. It wasn't prime time, but they demonstrated that they were able to write and run a tiny smalltalk program using eclipse. The downside is that they were using a proprietary smalltalk component instead of an open one, like SqueakSmalltalk. --EricHerman Which year? OOPSLA 2005? -- omc

other plugins:

Recommended plugin... LunarEclipse "Editor Enhancements", and install the Emacs plugin... I only use the completion command from it, but it adds a lot to eclipse. Don't get me wrong, the code completion built into eclipse is great, they really serve different purposes, the built in one is more 'global', more 'smart', the emacs one is quicker, and you tend to have many happy accidents (it searchs for all matches, in all open editors, and including matches starting partway through a word)

-- WilliamUnderwood

I was all excited to see "emacs" and "eclipse" mentioned on the same page, but alas, the Editor Enhancements package does not seem to provide an emacs keybindings remapping to eclipse... I'd love to dive in, but my fingers keep getting lost along the way. They're too trained to emacs shortcuts.

Emacs keybindings are in Window -> Preferences -> Workbench -> Keys -> Keyboard Shortcuts -> Active Configuration -> Emacs.

The core philosophy behind Eclipse is "Everything is a plugin," as inspired by VisualStudio.

it is an open framework and toolkit for building IDE's

It don't think it's only useful for building IDEs. You can take out all IDE-ish parts, as they're only plugins, and have a complete application framework for complex tasks. The extension point strategy is very concise and expressive. I had my first plugin running in minutes. -- ManuelSimoni

I saw this running at LondonXpDay. I liked it so much I tried to install it at home. (Normally I'm immune to the tool hype.) I tried to install it under Windows98 - all I got was a splash screen that seemed to hang. (I don't expect 100% of installs to work seamlessly, but some sort of error message would be nice.) There doesn't seem to be any documentation about what you're supposed to do if it won't launch. Do I really have to start debugging it?

-- DafyddRees

Dafydd, I also had this problem when I grabbed the latest version of Eclipse. Its because Eclipse doesn't ship with a JRE but the launcher is a win exe that hangs if Eclipse doesn't start (they really should sort that). You can download a 1.3.x runtime from the Eclipse website or use another JDK if you use the appropriate command line arguments. ChanningWalton

Problem fixed - I posted the details on the eclipse newsgroup. Within a day, I had the answer: install a more recent version of the Java 2 SDK. That fixed the problem. This is a great IDE - it only took a few hours to get productive and I even have enough memory left over do useful things. --DafyddRees

A general way to debug startup errors is to run eclipse from the command line (in the eclipse directory) with java -cp startup.jar org.eclipse.core.launcher.Main

This method reported to me that a certain dll did not have the proper permissions (Windows 2000) -- Mark Miller

We use Eclipse for our every-day development. Importing our existing code was no problem (several thousand classes). It works allright, though we had to drop the spectacular integration with CVS (no, it is really great) because of performance problems. (you might want to check a recent build, they've been making improvements :) )

We're quite happy with it, it is usefull and the price is right ;-). I hope to see a MacOsx version soon.


The MacOsx port is available now. --ChanningWalton

The only thing I find missing in Eclipse (v2.1) is global regex search and replace, there is only global find (Ctrl-H) but no replace, Find/Replace (Ctrl-F) only works in a single file.

It's there, but it's hard to find. Do a global find (Ctrl-H); then, in the search results window, you'll see "Replace" in the context menu (right-click).

Otherwise, depending on what you are trying to do, one of the refactoring functions which will make the changes in a semantically meaningful way might work for you. Refactor->Rename...

3.0 stream adds regex in replacements (search regex have been available for some time, but the ability to use matches in the replacement is fairly recent).

I wonder... Are there any guides to stand-alone application deployment with Eclipse? Last time I was any involved with Java, I reconsidered for JBuilder mainly for its configurable build options, especially packaging all dependencies and resources into a single JAR file. I was doing a GUI assignment, and it took me ages to figure out how to get JFace viewers running outside the Eclipse environment.

A stand-alone SWT/JFace/RCP SDK for use with any development environment would be a nice thing to have.

Although I don't think there is anything beyond the plugin/feature development stuff built-in, there is an open-source plugin (the name of which escapes me right now) which provides a package-all-dependencies-into-a-giant-jar function.

Q. How does one print with line numbers? It seems that one can make line numbers appear on the screen but cannot print out the file with the numbers included. Is this a missing feature or a user error?

A. It is a missing feature. See

Not to be whiny, but WHY are they still putting this feature off? Most of us probably work in environments where we do code reviews, and line numbers are pretty essential, aren't they?

Headers and footers would also be nice, and they've been deferred too...

AnneM: for java I discovered this; To show line numbers in the Java editor, select Window => Preferences, open the Java node, and select Editor. Then, in the Appearance panel to the right, click the Show line numbers check box and then click OK.

Unfortunately that solution is language specific, thus not really maintainable.

Q. AnneM: I work on a Mac and desire to have my full printing options, ie 2/page duplex. How do I get that?

Q. Can you hide directories from being displayed in the left window? I have several data directories, which I never examine with EclipseIde, cluttering things up.

A. Yes, you can. In the Java perspective, package explorer window, click the Menu arrow and select "Filters...". You can do the same in the Resource perspective's Navigator view. Is there some other view in Eclipse where the folders show up that you'd like them to be hidden?

Q. Can you keep your source external or do you need to import it into a project?

A. Yes, you can keep it external (since the 3.0 stream).

Q. Can you edit code externally (say with vi) and then recompile in Eclipse?

A. Yes, just refresh the directory where you edited the code so that Eclipse knows that it has changed. The latest versions can detect changes automatically, although I'm not sure it will trigger a rebuild.

See also: NetBeans, JavaIde, ForteForJava, IntellijIdea, EclipseVsIdea, JavaObjectMapTraversal, WhoIsUsingEclipse
CategorySoftwareTool, CategoryFramework
EditText of this page (last edited August 15, 2005)
FindPage by browsing or searching

This page mirrored in WikiPagesAboutRefactoring as of April 29, 2006