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

Difference between revisions of "MoDisco/Components/Workflow/Architecture"

(Implementation in MoDisco Workflow)
Line 22: Line 22:
 
The second step was to retrieve the list of existing launch configurations. So we created a dedicated wizard and get the list of existing launch configuration from an instance of org.eclipse.debug.core.ILaunchManager. Instance provided by static access DebugOlugin.getDefault().getLaunchManager(). Using this API, we were able to retrieve an array of ILaunchConfiguration which prodides us enough informations (type, name).
 
The second step was to retrieve the list of existing launch configurations. So we created a dedicated wizard and get the list of existing launch configuration from an instance of org.eclipse.debug.core.ILaunchManager. Instance provided by static access DebugOlugin.getDefault().getLaunchManager(). Using this API, we were able to retrieve an array of ILaunchConfiguration which prodides us enough informations (type, name).
  
The third step was to modify, directly from the workflow definition, a loaded launch configuration. Instead of creating a specific wizard, we would have reused existing tab group defined to the type of selected launch configuration.
+
The third step was to modify, directly from the workflow definition, a loaded launch configuration. Instead of creating a specific wizard for each type of launch configuration, we would would like to reuse existing tab group defined for the type of selected launch configuration. So in our simple wizard, we have a wizard page which should be able to contain the same component that have been used in main list of launch configurations.
 +
However to do that we had to link two classes that shouldn't be accessed:
 +
* LaunchConfigurationDialog
 +
* LaunchConfiguraitonDialogtabViewer
  
  
 
[[Category:MoDisco]]
 
[[Category:MoDisco]]

Revision as of 12:14, 25 February 2010

DEPRECATED use Template:MoDiscoTabs and Template:MoDiscoTab as explain here : Wiki Template for MoDisco

Extension of launch configuration mechanism

A launch configuration is a description of how to launch a program. A workflow could be viewed as a composition of launch configurations. MoDiscoWorkflowPatternCompositeLaunchConfiguration.jpg

Purpose

To be able to propose an interface for a workflow definition dedicated to modernization (strong use of modeling tools), we have extended the notion of launch configuration following a composite pattern: notion of leaf for launch configurations and notion of composite for launch configuration. Extending the mechanism of launch configuration will provide us a nice wizard with all the options. Especially, if the MoDiscoWorkflow is itself a type of launch configuration.

However we had some requirements to be able to implement such workflow mechanism:

  • from a workflow, we should be able to load an existing launch configuration, which implies to retrieve a list of all launch configurations defined (with a filter to keep only the launch configurations whom type has a driver in ModiscoWorkflow).
  • from a workflow, we should be able to modify directly a loaded launch configuration (without having to select it in main list and after go back manually to workflow definition)
  • from a workflow, we should be able to create directly a launch configuration. This new launch configuration should be created in the main list and loaded in the workflow defintion

Implementation in MoDisco Workflow

The first step was to add the MoDiscoWorkflow as a launch configuration. So we followed the eclipse help and provided two classes (one for the type and one for the tab group).

The second step was to retrieve the list of existing launch configurations. So we created a dedicated wizard and get the list of existing launch configuration from an instance of org.eclipse.debug.core.ILaunchManager. Instance provided by static access DebugOlugin.getDefault().getLaunchManager(). Using this API, we were able to retrieve an array of ILaunchConfiguration which prodides us enough informations (type, name).

The third step was to modify, directly from the workflow definition, a loaded launch configuration. Instead of creating a specific wizard for each type of launch configuration, we would would like to reuse existing tab group defined for the type of selected launch configuration. So in our simple wizard, we have a wizard page which should be able to contain the same component that have been used in main list of launch configurations. However to do that we had to link two classes that shouldn't be accessed:

  • LaunchConfigurationDialog
  • LaunchConfiguraitonDialogtabViewer

Back to the top