| <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> |
| <html lang="en"> |
| <head> |
| <meta name="copyright" content="Copyright (c) IBM Corporation and others 2000, 2007. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." > |
| <link rel="stylesheet" href="../book.css" charset="ISO-8859-1" type="text/css"> |
| <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> |
| <meta http-equiv="Content-Style-Type" content="text/css"> |
| <title> |
| Preparing Eclipse |
| </title> |
| <script language="JavaScript" type="text/javascript" src="PLUGINS_ROOT/org.eclipse.help/livehelp.js"> </script> |
| </head> |
| <body> |
| <h1> |
| Preparing Eclipse |
| </h1> |
| <p> |
| In this section, you will verify that Eclipse is properly set up for Java development. |
| </p> |
| <p> |
| The following is assumed: |
| </p> |
| <ul> |
| <li> |
| You are starting with a new Eclipse installation with default settings. |
| </li> |
| <li> |
| You are familiar with the basic Eclipse workbench mechanisms, such as views and perspectives. |
| </li> |
| </ul> |
| <p> |
| If you're not familiar with the basic workbench mechanisms, please see the |
| <a href="PLUGINS_ROOT/org.eclipse.platform.doc.user/gettingStarted/qs-01.htm">Getting Started</a> chapter of the Workbench User Guide. |
| </p> |
| <h2> |
| Verifying JRE installation and classpath variables |
| </h2> |
| <ol> |
| <li> |
| If you still see the Eclipse Welcome page, click the arrow icon to begin using Eclipse. |
| </li> |
| <li> |
| Select the menu item |
| <a class="command-link" href='javascript:executeCommand("org.eclipse.ui.window.preferences(preferencePageId=org.eclipse.ui.preferencePages.Workbench)")'> |
| <img src="PLUGINS_ROOT/org.eclipse.help/command_link.svg" alt="Goto workbench preferences"> |
| <b>Window > Preferences...</b></a> |
| to open the workbench preferences. |
| </li> |
| <li> |
| Select the |
| <a class="command-link" href='javascript:executeCommand("org.eclipse.ui.window.preferences(preferencePageId=org.eclipse.jdt.debug.ui.preferences.VMPreferencePage)")'> |
| <img src="PLUGINS_ROOT/org.eclipse.help/command_link.svg" alt="Goto the installed JREs preference page"> |
| <b>Java > Installed JREs</b></a> |
| preference page to display the installed Java Runtime Environments. Confirm |
| that a JRE has been detected. By default, the JRE used to run the workbench will be used to build and run |
| Java programs. It should appear with a checkmark in the list of installed JREs. We recommend that you |
| use a Java SDK instead of a JRE. An SDK is designed for development and contains the source code for the |
| Java library, easing debugging. Additional SDKs can be added by searching the hard drive for installed |
| SDKs. To do so, simply click the <strong>Search...</strong> button and specify a root folder for the search. |
| <br>If you work with code that does not yet use generics (as we do in this tutorial), we recommend |
| that you install a Java SDK 1.4 as well, but leave the most recent version checked as default. |
| <p> |
| <img src="images/pref_jre.png" alt="Installed JREs preference page"> |
| </p> |
| </li> |
| <li> |
| Select the |
| <a class="command-link" href='javascript:executeCommand("org.eclipse.ui.window.preferences(preferencePageId=org.eclipse.ui.preferencePages.Workspace)")'> |
| <img src="PLUGINS_ROOT/org.eclipse.help/command_link.svg" alt="Goto the workspace preference page"> |
| <strong>General > Workspace</strong></a> |
| preference page. Confirm that the <strong>Build automatically</strong> option is checked. |
| <p> |
| <img src="images/pref_workspace.png" alt="Workbench preference page"> |
| </p> |
| </li> |
| <li> |
| Select the |
| <a class="command-link" href='javascript:executeCommand("org.eclipse.ui.window.preferences(preferencePageId=org.eclipse.jdt.ui.preferences.BuildPathPreferencePage)")'> |
| <img src="PLUGINS_ROOT/org.eclipse.help/command_link.svg" alt="Goto the Java build path preference page"> |
| <b>Java > Build Path</b></a> |
| preference page. Confirm that <strong>Source and output folder </strong> is set to <strong>Folders</strong>. |
| <p> |
| <img src="images/pref_buildpath.png" alt="New project build patch preference page"> |
| </p> |
| </li> |
| <li> |
| Select the |
| <a class="command-link" href='javascript:executeCommand("org.eclipse.ui.window.preferences(preferencePageId=org.eclipse.jdt.ui.preferences.JavaEditorPreferencePage)")'> |
| <img src="PLUGINS_ROOT/org.eclipse.help/command_link.svg" alt="Goto the Java editor preference page"> |
| <strong>Java > Editor</strong></a> |
| preference page. |
| Confirm that option <STRONG>Report problems as you type</STRONG> is checked. |
| <p> |
| <img src="images/pref_editor.png" alt="Java editor preference page"> |
| </p> |
| </li> |
| <li> |
| Select the |
| <a class="command-link" href='javascript:executeCommand("org.eclipse.ui.window.preferences(preferencePageId=org.eclipse.jdt.ui.preferences.CompliancePreferencePage)")'> |
| <img src="PLUGINS_ROOT/org.eclipse.help/command_link.svg" alt="Goto the Java compiler preference page"> |
| <strong>Java > Compiler</strong></a> |
| preference page. |
| Confirm that option <STRONG>Compiler compliance level</STRONG> matches your default JRE version (usually <strong>1.6</strong>). |
| <p> |
| <img src="images/pref_compiler.png" alt="Java compiler settings preference page"> |
| </p> |
| </li> |
| <li> |
| Click on <strong>OK</strong> to save the preferences. |
| </li> |
| </ol> |
| <P class="nav_footer" id="nav_footer">Next Section: <A href="qs-3.htm">Creating your first Java project</A> |
| </P> |
| <h3 class="related">Related concepts</h3> |
| <a href="../concepts/concept-java-project.htm">Java projects</a><br> |
| <a href="../concepts/concept-classpath-variables.htm">Classpath variables</a><br> |
| <a href="../concepts/concept-build-classpath.htm">Build classpath</a> |
| |
| <h3 class="related">Related tasks</h3> |
| <a href="../tasks/tasks-JREs.htm">Working with JREs</a> |
| |
| <h3 class="related">Related references</h3> |
| <a href="../reference/preferences/java/debug/ref-installed_jres.htm">Installed JREs Preferences</a><br> |
| <a href="../reference/preferences/java/ref-preferences-editor.htm">Java Editor Preferences</a> |
| |
| </body> |
| </html> |
| |