# 3.0 JDT Launching Change Notes

This document describes important changes in the 3.0 JDT launching support, relative to the 2.1 release.

## API Changes

### VMRunnerConfiguration contains environment

Two methods have been added to the `VMRunnerConfiguration` type to support the setting and retrieving of environment variables.

Implementors of `IVMRunner` should call `VMRunnerConfiguration.getEnvironment()` and pass that environment into the executed VM. Clients who use `DebugPlugin#exec(String[] cmdLine, File workingDirectory)` can do this by calling `DebugPlugin#exec(String[] cmdLine, File workingDirectory, String[] envp)` instead. Simply passing in the result from `getEnvironment()` is sufficient.

### VMRunnerConfiguration and Bootstrap Classes

In prior releases, the `VMRunnerConfiguration` had one attribute to describe a boot path. The attribute is a collection of `Strings` to be specified in the -`Xbootclasspath` argument. Three new attributes have been added to the VM specific attributes map to support VMs that allow for prepending and appending to the boot path. The newly added attributes are defined in `IJavaLanuchConfigurationConstants`:

- `ATTR_BOOTPAH_PREPEND` - an array of strings describing paths in the local file system to be prepended to the boot path (the `-Xbootclasspath/p` argument)
- `ATTR_BOOTPATH` - an array of strings describing paths in the local file system to be placed on the boot path (the `-Xbootclasspath` argument)
- `ATTR_BOOTPATH_APPEND` - an array of strings describing paths in the local file system to be appended to the boot path (the `-Xbootclasspath/a` argument)

The old attribute,`getBootClassPath()` still exists, and contains a complete path equivalent to that of the three new attributes. However, `VMRunners` that support the new boot path options should take advantage of the new attributes, found in the VM specific attributes map (i.e. `VMRunnerConfiguration.getVMSpecificAttributesMap()`). The attributes are computed dynamically at launch time based on the classpath attribute associated with a launch configiuration. The boothpath attributes themselves are not stored in launch configurations.

### Default VM Arguments

To allow a specific set of VM arguments to be used every time a specific VM is launched (without having to specify the arguments on all associated launch configurations), a new "VM arguments" attribute has been added to `IVMInstall`, along with getter and setter methods. Although clients may implement this interface, the additional API is intended to be non-breaking, since clients who implement the interface should be subclassing `AbstractVMInstall`, where the new feature is implemented. Existing VM runners need to honor the new attributes when launching a VM. A convenience method (`combineVmArgs`) has been added to `AbstractVMRunner` to combine VM arguments specified on a runner configuration and a VM install.