Useful Eclipse (IDE) Features

Most of us working on Java use an IDE for development believing it saves our time and making us more productive. But do we really use the IDE effectively is the question. Let us see through some features that really helps in increasing our productivity in Eclipse Luna version 4.4.2 (IDE which I use).

1. Camel Case Assist

Go to Windows->Preferences->Java->Editor->Content Assist and Check “Show Camel Case Matches”

CameCaseAssit.jpg

CameCaseAssit_1.jpg

This feature is completely based on Camel Case naming convention used in Java. Just type in the capital letters of the class name and press ctrl + space, Eclipse will suggest the classes whose name matches with the capitalized letters typed in.

Note: The classes will be suggested only if the classes are part of the imports specified in the Class file.

 2. Local History

Right Click on Editor -> Context Menu -> Local History

localhistory.jpg

In an ongoing project, there is fair chance that we need to change the logic in a Class quite a few times. The local history feature in Eclipse is helpful in keeping track of the changes that we make on the file and revert back to any version at any point in time.

3. Split Editor

Split horizontally using CTRL+_  or vertically using CTRL+{

SplitEditors.jpg

Most of the times while implementing a logic we might want to refer to a different section of the same file. Eclipse has a cool feature of splitting the editor and allowing to edit both the sections of the file.

4. Save Actions

Go to Windows -> Preferences->Java->Editor->Save Actions

SaveActions.jpg

Basic activities a developer does after writing some code are organizing the imports (CTRL + o), formatting the code (CTRL + SHIFT+ f ) and saving the file (CTRL +s). What if all these can be done on a single command. Yes. Eclipse has this option to organize the import and format the code automatically on saving the file.

5. Code Clean Up

Right Click on Editor -> Context Menu -> Source -> Clean Up

CleanCode

Refactoring of any existing module always starts with removing unused code. Eclipse does clean up of unused code automatically.

       Eclipse has a lot more features. The ones listed are here are very basic and used in our day-to-day activities. To explore more about Eclipse, the official help from Eclipse is available at Eclipse official Help. The screen shots in this article are from the Internet.

PS: Click on the images for more clarity.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s