Source Attachment Property Page

To browse the source of a type contained in library you can attach a source archive or source folder to this library. The editor will then show the source instead of the decompiled code. Setting the source attachment also allows source level stepping with the debugger.

The Source Attachment dialog can be reached in several ways:

Depending of how a JAR was contributed to the classpath, you can see different types of Source attachment dialogs:

JAR

In the Path field, enter the path of an archive or a folder containing the source. Use either the Workspace, External File or the External Folder button to browse for a location.

For a source attachment in an external location you can also specify an optional Encoding for reading the source attachment. By default the workspace encoding is used.

Variable

In the Location Variable Path field enter a variable path that points to the source attachment's location. A variable path has as first segment a variable (which will resolve to a folder or file), the rest is an optional path extension (e.g.MYVARIABLE/src.jar ). Use either the Variable button to select an existing variable and the Extension button to select the extension path. The Extension button is only enabled when the variable can be extended (resolves to a folder)

JRE_SRC is a reserved variable that points to a JRE selected in the Installed JREs preference page ( Opens the Installed JRE preference page Java > Installed JREs). Go to this preference page to configure the source attachment for the JRE's library..

Related concepts

Build classpath

Related reference

Installed JREs preferences
Java build path properties