This action might not be possible to undo. Are you sure you want to continue?
tech facts at your fingertips
Getting Eclipse Workbench 101 Development with Eclipse Keyboard Shortcuts Plug-ins Community Web Sites Hot Tips and more...
Getting Started with Eclipse
By Ed Burnette & Adam Houghton
Go to the eclipse.org download site—http://download. eclipse.org/eclipse/downloads—and choose the package that’s right for you:
Package Eclipse IDE for Java Developers Eclipse IDE for Java EE Developers Eclipse IDE for C/ C++ Developers Eclipse for RCP/ Plug-In Developers Eclipse Classic Major Features Java IDE with incremental compilation, cross-referencing, code-assist, and Mylyn task management. Adds JEE validation, app server support, graphical HTML/JSP/JSF editing, and database tools. C/C++ IDE with syntax highlighting and code completion, launcher, debugger, and makefile generator. Java IDE plus the Plug-In Development Environment for creating Eclipse plug-ins and applications. The original Java IDE and Rich Client Platform.
WHAT IS ECLIPSE?
Eclipse is the leading Integrated Development Environment (IDE) for Java, with a rich ecosystem of plug-ins and an open source framework that supports other languages and projects. You’ll find this reference card useful for getting started with Eclipse and exploring the breadth of its features. We rundown the Eclipse distributions and configuration options, then guide you through Views, Editors, and Perspectives in Workbench 101. We list the top shortcuts and toolbar actions for everyday development. And, we provide a guide to the best places for finding plug-ins and getting involved with the Eclipse community.
We focus on the Windows and Mac OS X versions, but Eclipse runs on any modern operating system. Each Eclipse release is tested and validated on different versions of Windows, Linux, OS X, Solaris, and AIX.
What version should I get?
At any given time up to five different build types are available. To see these, select All versions from the download page or visit http://download.eclipse.org/eclipse/downloads
Version Releases Maintenance Builds Stable/Milestone Builds Integration Builds 1 Week 1 Day Fair Poor Frequency Yearly Quarterly 6 Weeks Stability Best Best Good Audience Everyone Everyone Users interested in the latest features Contributors to Eclipse Contributors to Eclipse
OS Friendly Upgrade to Vista? Eclipse 3.3 runs great on 32-bit versions of Microsoft’s latest operating system and uses native WPF components. Eclipse 3.4 adds support for 64-bit Windows XP and Vista. Mac user? Eclipse for OS X is a Universal Binary, so it natively supports both Intel and PowerPC Macs.
Getting Started with Eclipse
Eclipse is the most well known of several dozen open source projects hosted at eclipse.org (http://www.eclipse.org). Since 2001, the Eclipse SDK has been downloaded over 50 million times. Most people think of Eclipse as a Java IDE but it’s also one of the most popular tools for developing programs in Python, PHP, Ruby, C/C++, and other languages. You can even use it for non-programming tasks such as document creation and order entry. It achieves this flexibility through its modular plug-in architecture (more on that later).
Get More Refcardz
n n n n n n n
Never install a new version of Eclipse on top of an older version. Rename the old one first to move it out of the way, and let the new version be unpacked in a clean directory.
Authoritative content Designed for developers Written by top experts Latest tools & technologies Hot tips & examples Bonus content online New issue every 1-2 weeks
Subscribe Now for FREE! Refcardz.com
This will create a new project in the standard location: a new directory off of the main workspace directory. Regardless of what you’re creating. For the most part you will be using the built-in Java or Debug perspectives. review your build settings and click “Finish” The last dialog window lets you define jar files and dependent projects. If automatic builds are disabled then you can use Project > Build All (Ctrl+B) to start a build.com . Building Where possible. this build is run after the Save and the results are shown in the Console view. You can also edit two portions of the same file by using the Window > New Editor command. new views. resources. Eclipse uses incremental compilation to build derived objects in the background. As you move your cursor it will change shape to indicate actions you can take or places you can drop things on. and toolbars. Inc. and derived files.3 tech facts at your fingertips Getting Started with Eclipse Editors Editors are very similar to views. | www. Toolbar Five useful icons on the Eclipse toolbar: Debug As: debugs the last application you’ve launched. or collapse them to an icon on the edge of the window (as a fast view). Perspectives A perspective is a set of views. Typically projects are subdirectories of your workspace directory. along with their arrangement within the Workbench window. simply switch to that perspective and Eclipse will put everything back the way you left it. DZone. You can turn automatic building on or off with an option: Window > Preferences > General > Workspace > Build automatically. 2. click and drag its title bar. DEVELOPMENT WITH ECLIPSE Eclipse can be used to create anything from a Java program to the next bestselling novel. a few basic concepts remain the same… Managing Projects An Eclipse project is a directory that contains any source files.dzone. Run As: runs the last application you’ve launched. You can either create a project from scratch or import an existing project from the file system. Toggle Mark occurrences: highlighting an element will highlight all other occurrences of that element in the editor window. you may rearrange windows. but they are constrained to a single rectangular area in the Workbench window. then click on a line of code to see who last changed it. Select File > New > Java Project This brings up the “New Java Project” dialog box. Start coding! If you need to change the project settings. but you can also select Window > Save Perspective As… to save your current arrangement under a new name. 1. it’s best to leave the default options selected. Don’t worry if these aren’t available yet—it’s easy to change build setting later. select Projects > Properties or right click on a project name and click Properties. metadata. or from an existing Ant build file. when you save a Java file in Eclipse. from CVS. You can drag views outside of the Workbench window. you can show two files side by side. The next time you have to perform the same kind of task. 3. Hot Tip Blame Game Want to track down who broke the build? Open the Annotate View with Team > Show Annotation. Rearranging Views and Editors To move a view or editor. but Eclipse allows them to be anywhere on the file system. Editors may be text-based (like the Java editor) or graphical (such as a diagram editor). there is no need to run a Build— it’s already done. Hot Tip Side by Side By dragging editors. Perspectives are not “modes”. For example. 4. An asterisk in the editor’s title bar indicates it has unsaved data. Link with Editor: the Package Explorer will continually update to reflect the active file in the editor window. Fill in your project name and click “Next” For most projects. editors. The project will use the default JDK and store compiled class files in their own directory. In Ant or Make based projects. Last Edit Location: jumps to the file and location of the last edit you’ve made. You can save or revert an editor’s contents. and so on. As you perform a task. Your arrangement is saved under the current perspective.
then format all of your code with Ctrl+Shift+F. DZone. then share it with your team members. The CVS Repository Exploring perspective lets you browse branches and check out projects from existing CVS repositories. The Team Synchronizing Perspective provides helpful tools for keeping track of pushes and managing merges. move classes between packages...dzone. Right click on a resource and select Team >… to see options for synchronizing. This dialog also lets you configure actions like removing unnecessary casts or adding missing annotations. To create or modify a launch configuration. Visual SourceSafe. depending on whether you want to run the program under the debugger or not. recipes describing how to run or debug your project. Inc. Enable the Change Sets view. continued Running and Debugging In Eclipse there is no overall “Run” command. you use one or more launch configurations. Instead. and extract methods without fear of breaking the build. Synchronizing CVS synchronization is built into Eclipse. Git. Refactoring Eclipse has a powerful set of refactoring tools to help reshape your code. including Subversion. and Mercurial.4 tech facts at your fingertips Getting Started with Eclipse DEVELOPMENT WITH ECLIPSE.com . Or. Save your formatting profile by selecting “Export” in the profile properties. The Debug and Run icons on the toolbar provide a quicker way to do the same thing. Rename variables. Hot Tip Automatic Clean Up Forgetful about formatting? Set up Eclipse to automatically format source code and organize imports on every save. Spend hours tweaking your settings in Window > Preferences > Java > Code Style > Formatter. | www.. committing. then select a group of files and right-click Add To > New Change Set. Select Window > Preferences > Java Editor > Save Actions to enable these actions. select Run > Debug. Formatting Control the minutiae of code formatting with Eclipse’s plethora of Formatter options. and updating. Hot Tip Juggling Code Change Sets help you keep track of multiple commits in your playpen. press Ctrl+F11 to re-run the last program. Check out the Plug-ins section for the best places to find and download plug-ins.. Not using CVS? There are Eclipse plug-ins for every type of version control system. or Run > Run. Highlight an element and press Alt+Shift+T to see the list of available refactorings.
A large and growing number of Eclipse plug-ins are being developed in this open source nexus. Inc. and managing Eclipse plug-ins.5 tech facts at your fingertips Getting Started with Eclipse KEyBOArD SHOrTCUTS Here are our Top 50 favorite keyboard shortcuts defined by Eclipse. and listings for products and services.net Pulse 2. Java Refactoring Shortcuts Windows Alt+Shift+R Alt+Shift+L Alt+Shift+M Ctrl+Shift+Y Ctrl+Shift+Z oS X Cmd+option+R Cmd+option+L Cmd+option+M Cmd+option+Y Cmd+option+Z Shortcut Rename Element Extract to Local Variable Extract to Method Change Method Signature Undo Refactoring Source Forge http://sf.yoxos. This site offers a plug-in directory.org/ eclipse/downloads Eclipse Plugin Central http://eclipseplugincentral. The main ones are: Plug-in Resource Eclipse Downloads Home http://download. Shortcut Format Source Find Reference Open Resource Open Type Open Search Dialog Quick Outline Quick Hierarchy Go to Line Back Forward Last Edit Next Error Previous Error JDT Java Development Tools Workbench JFace SWT Core Plug-in A Plug-in B Workspace Runtime Plug-in C PDE Plug-in Development Environment Coding Shortcuts Windows Ctrl+1 Ctrl+Space F2 Shift+F2 Ctrl+Shift+o Ctrl+Shift+F Ctrl+I Ctrl+/ Ctrl+F Ctrl+D Ctrl+Alt+up Alt+up Ctrl+Alt+Down Alt+Down oS X Cmd+1 Cmd+Space F2 Shift+F2 Cmd+Shift+o Cmd+Shift+F Cmd+I Cmd+/ Cmd+F Cmd+D Cmd+option+up option+up Cmd+option+Down option+Down Shortcut Quick Fix Content Assist Show Tooltip Description Show External Javadoc Organize Imports Format Source Correct Indentation Toggle Comment Find and Replace Delete Line Copy Lines Up Move Lines Up Copy Lines Down Move Lines Down The Eclipse SDK is pre-packaged with over 100 plug-ins including plug-ins for basic text editing. Eclipse is made up entirely of plug-ins. which provides a convenient automatic discovery and update service for a consistent and tested set of plug-ins.com DZone. GUI editing. online help. For a small yearly fee you can access the Yoxos Install Manager. J2EE. Pulse 2. Most are downloaded as zip files that need to be manually unpacked like the Eclipse SDK.eclipse.dzone. Java development. This figure shows how everything fits together: Eclipse SDK Eclipse Platform User Interface Navigation Shortcuts Windows F3 Ctrl+Shift+G Ctrl+Shift+R Ctrl+Shift+T Ctrl+H Ctrl+o Ctrl+T Ctrl+L Alt+Left Alt+Right Ctrl+Q Ctrl+.0 Service http://www. There are several places on the web where you can find and install plug-ins. Pulse allows sharing of profiles among multiple computes—great for bringing work home or showing tips to team members. database manipulation. charting. Cmd+. Literally thousands of other plug-ins have been written to add support for other languages.com . and so forth.0 is a free service for discovering. Editor Window Shortcuts Windows Ctrl+E Ctrl+M Ctrl+W Ctrl+Page up oS X Cmd+E Cmd+M Cmd+W Cmd+Page up Cmd+Page Down Cmd+F8 Cmd+Shift+S Cmd+Shift+W F5 Shortcut Open Editor Window Maximize Editor Window Close Editor Window Switch to Tab Left Switch to Tab Right Change Perspective Save All Close All Refresh Debugging Shortcuts Windows F5 F6 F7 F8 F11 Ctrl+F11 Ctrl+R Ctrl+Shift+B oS X F5 F6 F7 F8 F11 Cmd+F11 Cmd+R Cmd+Shift+B Shortcut Step Into Step Over Step Return Resume Debug Last Launched Run Last Launched Run to Line Toggle Breakpoint on Line Ctrl+Page Down Ctrl+F8 Ctrl+Shift+S Ctrl+Shift+W F5 PLUG-INS Aside from a small “bootstrapping” core runtime.poweredbypulse. UML. ratings. Small collections of plug-ins are logically grouped into “features” that are installed and uninstalled as a unit.org. RSS reading. oS X F3 Cmd+Shift+G Cmd+Shift+R Cmd+Shift+T Cmd+H Cmd+o Cmd+T Cmd+L Cmd+[ Cmd+] Cmd+Q Cmd+. reporting.com Description Select “By Project” or “By Topic” to access the plug-ins produced by all projects at eclipse. You can replace any of these (or even switch to Emacs bindings) by selecting Window > Preferences > General > Keys. news. and plug-in development. reviews. downloading. Ctrl+. | www.com Yoxos Subscription Service http://www. forums.
Community Web Sites Eclipse Zone http://eclipsezone. NC 27513 n n ISBN-13: 978-1-934238-04-2 ISBN-10: 1-934238-04-X 50795 The DZone Network is a group of free online services that aim to satisfy the information needs of software developers and architects. Java. stored in a retrieval system. software development. Inc. The Eclipse Foundation’s home page. Part of IBM’s emerging technologies web site. this is dedicated to Eclipse and WebSphererelated projects and plug-ins. North Carolina.6 tech facts at your fingertips Getting Started with Eclipse COMMUNITy WEB SITES By installing Eclipse and reading this guide. After moving to Durham.com Sponsorship opportunities sales@dzone. podcasts. To quote PC magazine. Get peer support from thousands of other users and developers. No part of this publication may be reproduced.eclipse. test and debug applications using the tools provided by Eclipse and other third-party open source plugins. he settled down into the stable world of business software and is currently a Senior Software Developer in the SAS Advanced Computing Lab.com Eclipse Home Page http://www. Publications: Eclipse IDE Pocket Guide (O’Reilly). Eclipse in Action (Manning) Blog: Dev Connection blog at ZDNet: http://blogs. $7. or otherwise. or transmitted. web sites. In his copious spare time. To help you go further. 1251 NW Maynard Cary. and lives of Eclipse users and contributors.0 Copyright © 2008 DZone. Since graduating from NC State University he has programmed everything from compilers and video games to web services and load testers. “DZone is a developer’s dream.zdnet.org Eclipse Newsgroups http://www. Ed enjoys learning and writing about Open Source.apache. developerWorks hosts a variety of tutorials. mechanical.com Description Planet Eclipse is a window into the world. Realistic examples demonstrate how to use Eclipse effectively to build.0399 919.com. Configuration and JSNI Reference DZone. work.com 9 781934 238042 Version 1. you’ve already taken the first steps in joining the Eclipse community. without prior written permission of the publisher. He later enjoyed riding the dot-com wave as a serverside Java developer. source code and more. Ed Burnette Ed Burnette has been hooked on computers ever since he laid eyes on a TRS-80 in the local Radio Shack. The official eclipse. All rights reserved.678. personal weblog BUy NOW books. Hands-On Google Web Toolkit (Dr. Ed is a Principal Systems Developer at the SAS Advanced Computing Lab in Cary. Community Web Sites Planet Eclipse http://planeteclipse. and the two projects collaborate in many areas. and other resources are available to assist you.dzone.com/ developerworks/opensource Apache http://www.oreilly.0 NetBeans IDE 6 Java Editor Groovy n n n n n n Getting Started with Ajax GWT Style. DZone offers everything technology professionals need to succeed. Articles: iPhone Web Development with Eclipse (IBM developerWorks).ibm. From news. Subscribe at refcardz.com/Burnette Adam Houghton Adam Houghton’s high tech career began at age 12. photocopying. Inc.com/ eclipse IBM developerWorks http://www. Apache software is used throughout Eclipse. NC.0300 Refcardz Feedback Welcome firstname.lastname@example.org IBM AlphaWorks http://alphaworks.eclipse. and technology in general. Dobbs Journal) Blog: www.” 888.org wiki.adamhoughton.com Upcoming Refcardz: n FrEE n Spring Configuration Windows PowerShell Dependency Injection in EJB3 Flexible Rails: Flex 3 on Rails 2 RSS and Atom jQuery Selectors Design Patterns MS Silverlight 2. and related information on Eclipse and other open source projects. articles. and forums.org o’Reilly open Source http://opensource. ABOUT THE AUTHOrS rECOMMENDED BOOK Eclipse in Action provides a thorough guide to using Eclipse features and plugins effectively in the context of real-world Java development. in any form or by means electronic.org Eclipsepedia http://wiki.eclipse.com/books/ eclipse-in-action Want More? Download Now. The O’Reilly Resource Center provides a broad range of references and links to publications about open source. blogs.678. tutorials. as are thousands of Eclipse enthusiasts and professionals from around the world.ibm.org/newsgroups Description An online community for Eclipse users that includes exclusive articles. articles.95 . running a multi-line bulletin board system from the family living room.
This action might not be possible to undo. Are you sure you want to continue?
We've moved you to where you read on your other device.
Get the full title to continue reading from where you left off, or restart the preview.