Getting started

This tutorial is designed to get you started on using the Java Development Toolkit (JDT) in the workbench.

Preparing the workbench

In this section, you will verify that the workbench is properly set up for Java development.

The following is assumed:

If you're not familiar with the basic workbench mechanisms, please see the Getting Started chapter of the Workbench User Guide.

Verifying JRE installation and classpath variables

  1. Open the workbench preferences by selecting the menu item Window > Preferences.
  2. Go to the Installed Java Runtime Environments preference page by selecting Java > Installed JREs in the tree pane on the left.

    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 check mark in the list of installed JREs.

    Installed JREs preference page
  3. Go to the Workbench preference page by selecting Workbench in the tree pane.

    Confirm that the Perform build automatically on resource modification option is checked.

    Workbench preference page
  4. Go to the New Project preference page by selecting New Project in the tree pane.

    Confirm that As source and output location use is set to Project.

    New project preference page
  5. Go to the Java Editor preference page by selecting Java > Editor in the tree pane. On the preference page, press the Problem Indication tab.

    Confirm that all options are checked.

    Java Editor preference page
  6. Leave the preferences by clicking on OK.

Installing the JDT example plug-ins

The JDT example plug-ins contribute a New Wizard that automatically creates a sample project in your workbench. For this tutorial, however, we will perform these steps manually.

  1. Download the Zip file containing the example plug-ins from http://www.eclipse.org/downloads/.

  2. If the workbench is running, shut it down. Plug-ins should not be installed while the workbench is running.

  3. Extract the contents of the Zip file to the root directory of your workbench installation (e.g. c:\eclipse\plugins\).

  4. Start the workbench.

Related concepts

Java projects
Classpath variables
Build classpath

Related tasks

Working with build paths
Working with JREs

Related reference

JRE Installations Preferences
New Project Preferences
Java Editor Preferences