Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Debug/Plan/3.6/Launch Templates

< Debug‎ | Plan/3.6
Revision as of 09:47, 14 October 2009 by Darin Wright.ca.ibm.com (Talk | contribs) (Assign a default template to a workspace)

Launch Configuration Template Use Cases

Create a new template

Creating a new template is just like creating a new launch configuration. Use the "New" or "Duplicate" button in the launch configuration dialog (LCD) to create a new configuration and then click the "Template" check box to indicate that the configuration is a template.

Create a template from an existing configuration

Select the configuration in the LCD and click the "Template" check box to indicate that the configuration is a template.

Assign a default template to a project

A default template can be set for each launch configration type, for each project. From the "Properties > Run/Debug Settings" for a project, the user can use check boxes to select the default configuration for a project (the viewer in the properties page will become a check box list).

An API will be available to set a default template per launch configuration type for any given scope (using IScopeContext's - the same construct used for workspace preference settings). This allows a default template per launch configuration type to be set using a project scope.

Assign a default template to a workspace

A default template can be set for each launch configuration type in the workspace. When a launch configuration type is selected in the LCD, the tab area will be enhanced to display a check box list of all templates of that type. The check box can be used to select one template as workspace default for that type.

Create a configuration based on a specific template

Select the template in the LCD and press the "New" button. This will create a new configuration associated with the selected template, initialized with attributes from the template.

Create a configuration based on a project/workspace default template

When a new template is created in the LCD or from invoking a launch shortcut, project and workspace default template settings should be taken into account to initialize newly created configurations. The debug platform can leverage configuration resource mappings to determine what template should be used to initialize newly created configurations.

  • Select a launch configuration type node in the LCD and press the "New" button. This will create a new configuration and initialize it with default settings - ususally based on the selected resource or active editor in the workbench and usually sets a resource mapping for the configuration. The platform will locate a template based on project and workspace default settings for the configuration type and copy attributes from the first template found into the new configuration.
  • Similarly, when a launch shortcut creates a configuration and sets a resource mapping, this will trigger template initialization.

Additionally, and API will be available to create a configuration based on a set of scopes (the same as preference scopes - project, workspace, etc.), and set a default configuration for a given scope. A launch shortcut could use the new API to explicitly control what template is used (if any) when creating a new configuration. However, to allow existing shortcuts to benefit from launch templates, resource mappings will be used to trigger template initialization.

Update a configuration from its associated template

Update all configurations made from a template

Rename a template

Delete a template

Remove the template attribute

Disconnect a configuration from its template

Associate a configuration with an existing template

Back to the top