Free tutorials for Java, Eclipse and Web programming



Follow me on twitter

3. Eclipse UI Overview

Eclipse provides perspectives, views and editors. Views and editors are grouped into perspectives. All projects are located in a workspace.

3.1. Workspace

The workspace is the physical location (file path) you are working in. You can choose the workspace during startup of eclipse or via the menu (File-> Switch Workspace-> Others). All your projects, sources files, images and other artifacts will be stored and saved in your workspace.

You can predefine the workspace via the startup parameter -data path_to_workspace, e.g. "c:\eclipse.exe -data "c:\temp" Please note that you have to put the path name into brackets. To see the current workspace directory in the title of Eclipse use -showLocation as additional parameter.

3.2. Perspective

A perspective is a visual container for a set of views and editors. You can change the layout within a perspective (close / open views, editors, change the size, change the position, etc.). Eclipse allow you to switch to another perspective via the menu Window->Open Perspective -> Other. For Java development you usually use the "Java Perspective".

Tip

A common problem is that you closed a view and don't know how to re-open this view. You can reset a perpective it to it original state via the menu "Window" -> "Reset Perspective".

3.3. Views and Editors

A view is typically used to navigate a hierarchy of information or to open an editor. Changes in a view are directly applied to the underlying data structure. Editors are used to modify elements. Editors can have code completion, undo / redo, etc. To apply the changes in an editor to the underlying resources, e.g. Java source file, you usually have to save.