Eclipse Launching Framework <ul><li>brief introduction and prototype example </li></ul>[email_address] 2010.08
1. Introduction What is Launching? debug.core LaunchConfigurationTypes LaunchConfiguration debug.ui LaunchConfigurationDia...
1. Introduction
What is Launching? Launching   - running or debugging a program from within Eclipse Launcher   - a set of Java classes tha...
debug.core: Launching Framework’s model LaunchConfigurationTypes   - cookie cutters   - how to launch certain types of lau...
LaunchConfigurationTypes Extension point:  org.eclipse.debug.core.launchConfigurationTypes Interface:  org.eclipse.debug.c...
debug.ui: Launching Framework’s UI LaunchConfigurationDialog Icon TabGroup   - utilize “Jigloo” Shortcuts   - ‘Run As’   -...
Icon Extension point:  org.eclipse.debug. ui.launchConfigurationTypeImages <extension   point=&quot;org.eclipse.debug.ui.l...
TabGroup (1) Extension point:  org.eclipse.debug.ui.launchConfigurationTabGroups Interface:  org.eclipse.debug.ui.ILaunchC...
TabGroup (2) Steps:   1. write your own tab   - must implement  ILaunchConfigurationTab   - write UI code in  createContro...
Time to launch Steps:   1. write your own launcher   - must implement  ILaunchConfigurationDelegate   - write code in  lau...
Advanced concepts Launch Group   - “category”   - built-in: Run, Debug, External Tools Comparator
2. Prototype Demo (Run)
Steps to run Edit MANIFEST.MF Require-Bundle : org.eclipse.ui,  org.eclipse.core.runtime,  org.eclipse.debug.core;bundle-v...
References & ToDo Item References:   - We Have Lift-off: The Launching Framework in Eclipse   http://www.eclipse.org/artic...
Upcoming SlideShare
Loading in …5
×

Eclipse Launching Framework

3,768 views

Published on

Published in: Technology
2 Comments
2 Likes
Statistics
Notes
  • Sorry, I didn't have sources now. I think you can find useful source snippets in http://www.eclipse.org/articles/Article-Launch-Framework/launch.html.
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • Thank you for sharing this great presentation. Is the prototype source code also available somewhere?
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
No Downloads
Views
Total views
3,768
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
0
Comments
2
Likes
2
Embeds 0
No embeds

No notes for slide
  • D:works
    untime-EclipseApplication.metadata.pluginsorg.eclipse.debug.core.launches config1.launch
  • Eclipse Launching Framework

    1. 1. Eclipse Launching Framework <ul><li>brief introduction and prototype example </li></ul>[email_address] 2010.08
    2. 2. 1. Introduction What is Launching? debug.core LaunchConfigurationTypes LaunchConfiguration debug.ui LaunchConfigurationDialog TabGroup Shortcuts 2. Prototype Demo (Run)
    3. 3. 1. Introduction
    4. 4. What is Launching? Launching - running or debugging a program from within Eclipse Launcher - a set of Java classes that live in an Eclipse plug-in that performs launching - launcher for Java application, JUnit test suites, ... - What for YOUR application? Launching Framework - extension mechanism - Separating model and UI - debug.core - debug.ui
    5. 5. debug.core: Launching Framework’s model LaunchConfigurationTypes - cookie cutters - how to launch certain types of launch - Java Application LaunchConfigurations - cookie made from cutters - information necessary to perform a launch - it’s just key/value pair - boolean, int, Map, List, String - main class, JRE, VM arguments, ...
    6. 6. LaunchConfigurationTypes Extension point: org.eclipse.debug.core.launchConfigurationTypes Interface: org.eclipse.debug.core.model.ILaunchConfigurationDelegate Method: launch(ILaunchConfiguration configuration, ...) <extension point=&quot;org.eclipse.debug.core.launchConfigurationTypes&quot;> <launchConfigurationType delegate=&quot;test.launch.LaunchConfigurationDelegate&quot; delegateName=&quot;test.launch.LaunchConfigurationDelegate&quot; id=&quot;test.launch.launchConfigurationType&quot; modes=&quot;debug,run&quot; name=&quot;Test Launcher&quot;> </launchConfigurationType> </extension>
    7. 7. debug.ui: Launching Framework’s UI LaunchConfigurationDialog Icon TabGroup - utilize “Jigloo” Shortcuts - ‘Run As’ - no Dialog - create, set to default values and launch in a click - launch(ISelection selection, ...) - launch(IEditorPart editor, ...)
    8. 8. Icon Extension point: org.eclipse.debug. ui.launchConfigurationTypeImages <extension point=&quot;org.eclipse.debug.ui.launchConfigurationTypeImages&quot;> <launchConfigurationTypeImage configTypeID=&quot;test.launch.launchConfigurationType&quot; icon=&quot;res/emu.png&quot; id=&quot;test.launch.launchConfigurationIcon&quot;> </launchConfigurationTypeImage> </extension>
    9. 9. TabGroup (1) Extension point: org.eclipse.debug.ui.launchConfigurationTabGroups Interface: org.eclipse.debug.ui.ILaunchConfigurationTabGroup Method: createTabs(ILaunchConfigurationDialog dialog, ...) <extension point=&quot;org.eclipse.debug.ui.launchConfigurationTabGroups&quot;> <launchConfigurationTabGroup class=&quot;test.launch.LaunchTabGroup&quot; id=&quot;test.launch..LaunchTabGroup&quot; type=&quot;test.launch.launchConfigurationType&quot;> </launchConfigurationTabGroup> </extension>
    10. 10. TabGroup (2) Steps: 1. write your own tab - must implement ILaunchConfigurationTab - write UI code in createControl() // Jigloo comes in! - value copying methods - setDefaults() ; called when a new config is created - performApply() ; read from GUI - initializeFrom() ; read from config 2. write createTabs() - construct an array of ILaunchConfigurationTab - setTabs() Notice: - Extend AbstractLaunchConfigurationTab - Include [common] tab
    11. 11. Time to launch Steps: 1. write your own launcher - must implement ILaunchConfigurationDelegate - write code in launch() - ILaunchConfiguration ; config - mode ; Run or Debug - ILaunch ; DebugTarget/Process - IProgressMonitor ; monitor - Construct a command line and pass it to Runtime.exec() - Create debug targets/processes and add to the ILaunch object Notice: - Extend LaunchConfigurationDelegate - Check monitor ex.)) user cancelled
    12. 12. Advanced concepts Launch Group - “category” - built-in: Run, Debug, External Tools Comparator
    13. 13. 2. Prototype Demo (Run)
    14. 14. Steps to run Edit MANIFEST.MF Require-Bundle : org.eclipse.ui, org.eclipse.core.runtime, org.eclipse.debug.core;bundle-version=&quot;3.5.1&quot;, org.eclipse.debug.ui;bundle-version=&quot;3.5.2&quot;, org.eclipse.jdt.launching;bundle-version=&quot;3.5.1“ org.eclipse.jdt.debug.ui;bundle-version=&quot;3.4.1&quot; Run Eclipse Application - Create project - Choose [Run Configurations...]
    15. 15. References & ToDo Item References: - We Have Lift-off: The Launching Framework in Eclipse http://www.eclipse.org/articles/Article-Launch-Framework/launch.html ToDo: - Debug artifacts - IDebugElement, IDebugTarget, IProcess - ISuspendResume, IBreakpointListener

    ×