Eclipse – State of the union- with a little, little focus on LinuxLars Vogelhttp://www.vogella.dehttp://www.twitter.com/vogella
	Lars VogelWorking for SAP AG as a product managerPrivately contributing to in the Java and Eclipse ecosystemPublish programming tutorials on  http://www.vogella.deWho am I ?
I used to use Linux / Unix quite a bit but this a while agoEmacs and KDE rules!My server for http://www.vogella.de runs on Ubuntu I still think that the command line is coolMe and Linux
Todays talk will be about Java and programming for and based on Eclipse
Eclipse is written in Javain little pieces (plugins)
Mini-Agenda The Eclipse EcosystemEclipse and modularityEclipse Plugin and RCP developmentEclipse 4.0 / Eclipse e4
The Eclipse Ecosystem
Successful Open Source Projects
Unlike other (successful) OpenSource Projects Eclipse has no mascotThis is NOT the animal representing Eclipse
ImpactEclipse – History BookVery disruptive for the pay IDE Eclipse is a vendor independent Open Source ProjectNov. 2001 – Code released as Open Source, still lead by companiesFebr. 2004 – Eclipse Foundation created
ImpactEclipse – History BookStart of Eclipse as a platform, e.g. NASA starts using Eclipse for it‘s Mars missionMarket leader with a strong ecosystemRe-gain innovation speedJuni 2004 – Eclipse 3.0 based on OSGi and enables Eclipse RCP 2010 - Current Eclipse 3.5.2 (aka Ganymede)06.2010 Release of Eclipse 3.607.2010 Planned first release of Eclipse 4.0
Eclipse Foundation The Eclipse Foundation is a not-for-profit, member supported corporation that hosts the Eclipse projects and helps cultivate both an open source community and an ecosystem of complementary products and services.
Eclipse Foundation does not pay developersMember companies and private persons develop the code
STRATEGIC MEMBERS
ALL MEMBERS
Members, there are 160 as of today.14 Strategic3 Enterprise74 Solutions69 Associate
Eclipse ProjectsOver 100 Eclipse projectsOriginally very IDE focused but start getting divershttp://www.eclipse.org/projects/listofprojects.php
CDT C and C++ developmentJDT Java Development Toolsand much, much more…EgitGit with JavaPHPRuntimeEquinox (OSGi)RAP…WebtoolsPlatformJSF JPAWebservicesHTMLJavaScriptPDE  Plugin Development Tools
Eclipse Download StatisticsDownloads bundle several projects
All Eclipse.org source code is released under the Eclipse Public License (EPL)
EPL is business friendlyDo what you want with the codeModification of  the original code must be contributed back NOT viral like the GPL which companies like
22Eclipse & third partiesGoogleGWTGoogle App EngineAndroid Dev toolsZENDPHP Studio	IBMWebspereJazzAnd many more
The Eclipse communityVery welcomingEclipse forumsPlanetEclipse.org#eclipse at IRCSeems to be individual driven rather then company driven
I use Eclipse for Kernel Development* Quote complete made up by Lars
The modular architecture of Eclipse
Extensible Application - FirefoxPluginsThe Browser
In Eclipse everything is a plugin (except the core runtime)PluginPluginPluginPluginPluginRuntime
Platformvrs. Extensible ApplicationPlatformExtensible ApplicationApplicationRuntime
Eclipse IDEHelpP2 UpdateTextCompareDebugSearchTeam/ cvsIDE personalityWorkbenchResourcesJFaceRuntime / Equinox (OSGi)SWT
Each Plugin defines its available API
Each Plugin defines also its dependencies
Runtime (OSGi) makes sure the API contacts are fulfilled
Plugin and RCP Development
Your pluginsEclipse IDE
MANIFEST.MF – Defines OSGi bundleplugin.xml – Defines Eclipse extensions and extension pointsPDE (Plug-in Development Environement) provides editors for these files.Configuration files
Extensions Extension PointsProvide functionality to predefined slots (== extension points)Define places where others (== extensions) can provide functionality
Eclipse extensibility is a little bit like Emacs, you can add easily functionalityBut not in LISP
Thin layer upon the native GUI libraries JNI callsNot a lot of convenient functionalitySWT - Standard Widget ToolkitExample Gnome GTK+ for Linux*Screenshot from the Internet
Eclipse RCPHelpP2 Update………………Workbench…JFaceRuntime / Equinox (OSGi)SWT
JFaceUI toolkit that provides helper classes for developing UI featuresTables / TreeViewer / Dialogs / Can be based on modelsDatabindingWorkbench multi-window environment manages views, editors, perspectives  JFace & Workbench
Viewer: Table / Treeviewer: Responsible for the UILabelProvider: How is the domain model representedModelProvider: Delivery the domain modelViewerSorter: Sorts values in the viewerViewerFilter: Filters valuesExample: JFace ViewerContentProvider – „Dao“ for viewer LabelProvider – Which data is represented howViewer – UI, shows data
The future of Eclipse – Problems & Solutions
All Eclipse code must be free of IP problemsIP Due Dilligence take a lot of time
Eclipse.org moving to git (jgit)Does Eclipse need a fork?Hope to enrich the ecosystem by making forking easy
Eclipse.org moving towards gitHope to enrich the ecosystem by making forking easy
Eclipse development got more and more complex over the years Eclipse 4.0 (aka e4)Developer Productivity
Eclipse 4.0
Eclipse e4 ScopeTargets developmentfor Eclipse (plugins) or based on Eclipse (Eclipse RCP).
Eclipse e4 TargetsMake Eclipse development more effective and the result more visual appealing.
Eclipse e4 – Building blocksDeclarative StylingRendering EngineModeled WorkbenchDependecy InjectionIEclipseContextCore Services
The Modeled Workbench
Eclipse 4.0 Application modelModels the Application (UI) and the behavior (commands)EMF basedModeled WorkbenchContent of the view not part of the e4 model
The e4 Workbench ModelEach application has it‘s live modelWorkbench window Menu with menu items Window Trim, e.g. toolbar with toolbar items Parts Sash ContainerPartsPart Stack (CTabFolder)PartsHandlersKey BindingsCommands
Model is FlexibleNo distinction between View and EditorPerspectives are optionalStack / Sash are optionalSeveral windows easily possibleFlexible Toolbars
Parts in Eclipse 4.0Plain Old Java Objects (POJO‘s)
InherianceHierachy of Views Parts before Eclipse 4.0ObjectEventManagerWorkbenchPartViewPartView
Model available at runtime
How is this model translated into UI components?© Lars Vogel and others, Licensed under Creative Commons by-nc-nd-3.0 (de)
Widget RendererEach UI elements gets a renderer Renderer manage Lifecycle of the UI-ElementCreationModel to widget bindingRenderingDisposal
Renderer: flexible but complex
e4 CSS Styling
Eclipse3.X  - IDE feelingEclipse e4 – CSS StylingExample from Kai ToedterSome elements cannot currently not be styled: Menu bar background
 Table headers e4 supports theme switching during runtime
New Look & Feel for Eclipse e4 – SDK https://bugs.eclipse.org/bugs/show_bug.cgi?id=293481
The e4 Programming Model
Dependency InjectionInversion of control: The necessary functionality is injected into the classJava Class
Dependency Injection in e4JSR 330 compatible injection implementation@javax.inject.Inject – Field, Constructor and Method injection@javax.inject.Named – Specify a custom qualifier to context object (default is fully qualified classname of the injected type)e4 specific annotations, e.g. @Optional
Java Class	Services are injected via the the e4 frameworkpublicclassListView {   @Inject   privateIEclipseContextcontext;@Inject    private Loggerlogger;   @Inject   publicListView(Composite parent) {// ...
Eclipse and the webEclipse e4 targets to bring the Eclipse IDE closer to the webOne way would be to run Eclipse in the web, e.g. via Eclipse RAPAnother way would be to run the web inside Eclipse
OpenSocial Gadgets
OpenSocial Gadgets in Eclipse
Photo creditsNot the Eclipse mascot http://www.sxc.hu/photo/666565Blue Sky with corn: http://www.sxc.hu/photo/570500Headless business man http://www.sxc.hu/photo/713927Money http://www.sxc.hu/photo/767230Old Book http://www.sxc.hu/photo/1273173Plug 1 http://www.sxc.hu/photo/603920Plug 2 http://www.sxc.hu/photo/182575USB Plug http://www.sxc.hu/photo/951745Lots of Plugs http://www.sxc.hu/photo/721092Police 1 http://www.sxc.hu/photo/860421Police 2 http://www.sxc.hu/photo/596144Boy in the water http://www.sxc.hu/photo/1022035Eye with the world in them http://www.sxc.hu/photo/928425Electronic parts http://www.sxc.hu/photo/643720Snail 1 http://www.sxc.hu/photo/1181451Snail 2 http://www.sxc.hu/photo/1181452Fork http://www.sxc.hu/photo/1186818Hammer http://www.sxc.hu/photo/604247Corn http://www.sxc.hu/photo/939151Thinking man http://www.sxc.hu/photo/324541

Eclipse Overview

  • 1.
    Eclipse – Stateof the union- with a little, little focus on LinuxLars Vogelhttp://www.vogella.dehttp://www.twitter.com/vogella
  • 2.
    Lars VogelWorking forSAP AG as a product managerPrivately contributing to in the Java and Eclipse ecosystemPublish programming tutorials on http://www.vogella.deWho am I ?
  • 3.
    I used touse Linux / Unix quite a bit but this a while agoEmacs and KDE rules!My server for http://www.vogella.de runs on Ubuntu I still think that the command line is coolMe and Linux
  • 4.
    Todays talk willbe about Java and programming for and based on Eclipse
  • 5.
    Eclipse is writtenin Javain little pieces (plugins)
  • 6.
    Mini-Agenda The EclipseEcosystemEclipse and modularityEclipse Plugin and RCP developmentEclipse 4.0 / Eclipse e4
  • 7.
  • 8.
  • 9.
    Unlike other (successful)OpenSource Projects Eclipse has no mascotThis is NOT the animal representing Eclipse
  • 10.
    ImpactEclipse – HistoryBookVery disruptive for the pay IDE Eclipse is a vendor independent Open Source ProjectNov. 2001 – Code released as Open Source, still lead by companiesFebr. 2004 – Eclipse Foundation created
  • 11.
    ImpactEclipse – HistoryBookStart of Eclipse as a platform, e.g. NASA starts using Eclipse for it‘s Mars missionMarket leader with a strong ecosystemRe-gain innovation speedJuni 2004 – Eclipse 3.0 based on OSGi and enables Eclipse RCP 2010 - Current Eclipse 3.5.2 (aka Ganymede)06.2010 Release of Eclipse 3.607.2010 Planned first release of Eclipse 4.0
  • 12.
    Eclipse Foundation TheEclipse Foundation is a not-for-profit, member supported corporation that hosts the Eclipse projects and helps cultivate both an open source community and an ecosystem of complementary products and services.
  • 13.
    Eclipse Foundation doesnot pay developersMember companies and private persons develop the code
  • 14.
  • 15.
  • 16.
    Members, there are160 as of today.14 Strategic3 Enterprise74 Solutions69 Associate
  • 17.
    Eclipse ProjectsOver 100Eclipse projectsOriginally very IDE focused but start getting divershttp://www.eclipse.org/projects/listofprojects.php
  • 18.
    CDT C andC++ developmentJDT Java Development Toolsand much, much more…EgitGit with JavaPHPRuntimeEquinox (OSGi)RAP…WebtoolsPlatformJSF JPAWebservicesHTMLJavaScriptPDE Plugin Development Tools
  • 19.
  • 20.
    All Eclipse.org sourcecode is released under the Eclipse Public License (EPL)
  • 21.
    EPL is businessfriendlyDo what you want with the codeModification of the original code must be contributed back NOT viral like the GPL which companies like
  • 22.
    22Eclipse & thirdpartiesGoogleGWTGoogle App EngineAndroid Dev toolsZENDPHP Studio IBMWebspereJazzAnd many more
  • 23.
    The Eclipse communityVerywelcomingEclipse forumsPlanetEclipse.org#eclipse at IRCSeems to be individual driven rather then company driven
  • 24.
    I use Eclipsefor Kernel Development* Quote complete made up by Lars
  • 25.
  • 26.
    Extensible Application -FirefoxPluginsThe Browser
  • 27.
    In Eclipse everythingis a plugin (except the core runtime)PluginPluginPluginPluginPluginRuntime
  • 28.
  • 29.
    Eclipse IDEHelpP2 UpdateTextCompareDebugSearchTeam/cvsIDE personalityWorkbenchResourcesJFaceRuntime / Equinox (OSGi)SWT
  • 30.
    Each Plugin definesits available API
  • 31.
    Each Plugin definesalso its dependencies
  • 32.
    Runtime (OSGi) makessure the API contacts are fulfilled
  • 33.
    Plugin and RCPDevelopment
  • 34.
  • 35.
    MANIFEST.MF – DefinesOSGi bundleplugin.xml – Defines Eclipse extensions and extension pointsPDE (Plug-in Development Environement) provides editors for these files.Configuration files
  • 36.
    Extensions Extension PointsProvidefunctionality to predefined slots (== extension points)Define places where others (== extensions) can provide functionality
  • 37.
    Eclipse extensibility isa little bit like Emacs, you can add easily functionalityBut not in LISP
  • 38.
    Thin layer uponthe native GUI libraries JNI callsNot a lot of convenient functionalitySWT - Standard Widget ToolkitExample Gnome GTK+ for Linux*Screenshot from the Internet
  • 39.
  • 40.
    JFaceUI toolkit thatprovides helper classes for developing UI featuresTables / TreeViewer / Dialogs / Can be based on modelsDatabindingWorkbench multi-window environment manages views, editors, perspectives  JFace & Workbench
  • 41.
    Viewer: Table /Treeviewer: Responsible for the UILabelProvider: How is the domain model representedModelProvider: Delivery the domain modelViewerSorter: Sorts values in the viewerViewerFilter: Filters valuesExample: JFace ViewerContentProvider – „Dao“ for viewer LabelProvider – Which data is represented howViewer – UI, shows data
  • 42.
    The future ofEclipse – Problems & Solutions
  • 43.
    All Eclipse codemust be free of IP problemsIP Due Dilligence take a lot of time
  • 44.
    Eclipse.org moving togit (jgit)Does Eclipse need a fork?Hope to enrich the ecosystem by making forking easy
  • 45.
    Eclipse.org moving towardsgitHope to enrich the ecosystem by making forking easy
  • 46.
    Eclipse development gotmore and more complex over the years Eclipse 4.0 (aka e4)Developer Productivity
  • 47.
  • 48.
    Eclipse e4 ScopeTargetsdevelopmentfor Eclipse (plugins) or based on Eclipse (Eclipse RCP).
  • 49.
    Eclipse e4 TargetsMakeEclipse development more effective and the result more visual appealing.
  • 50.
    Eclipse e4 –Building blocksDeclarative StylingRendering EngineModeled WorkbenchDependecy InjectionIEclipseContextCore Services
  • 51.
  • 52.
    Eclipse 4.0 ApplicationmodelModels the Application (UI) and the behavior (commands)EMF basedModeled WorkbenchContent of the view not part of the e4 model
  • 53.
    The e4 WorkbenchModelEach application has it‘s live modelWorkbench window Menu with menu items Window Trim, e.g. toolbar with toolbar items Parts Sash ContainerPartsPart Stack (CTabFolder)PartsHandlersKey BindingsCommands
  • 54.
    Model is FlexibleNodistinction between View and EditorPerspectives are optionalStack / Sash are optionalSeveral windows easily possibleFlexible Toolbars
  • 55.
    Parts in Eclipse4.0Plain Old Java Objects (POJO‘s)
  • 56.
    InherianceHierachy of ViewsParts before Eclipse 4.0ObjectEventManagerWorkbenchPartViewPartView
  • 57.
  • 58.
    How is thismodel translated into UI components?© Lars Vogel and others, Licensed under Creative Commons by-nc-nd-3.0 (de)
  • 59.
    Widget RendererEach UIelements gets a renderer Renderer manage Lifecycle of the UI-ElementCreationModel to widget bindingRenderingDisposal
  • 60.
  • 61.
  • 62.
    Eclipse3.X -IDE feelingEclipse e4 – CSS StylingExample from Kai ToedterSome elements cannot currently not be styled: Menu bar background
  • 63.
    Table headerse4 supports theme switching during runtime
  • 64.
    New Look &Feel for Eclipse e4 – SDK https://bugs.eclipse.org/bugs/show_bug.cgi?id=293481
  • 65.
  • 66.
    Dependency InjectionInversion ofcontrol: The necessary functionality is injected into the classJava Class
  • 67.
    Dependency Injection ine4JSR 330 compatible injection implementation@javax.inject.Inject – Field, Constructor and Method injection@javax.inject.Named – Specify a custom qualifier to context object (default is fully qualified classname of the injected type)e4 specific annotations, e.g. @Optional
  • 68.
    Java Class Services areinjected via the the e4 frameworkpublicclassListView { @Inject privateIEclipseContextcontext;@Inject private Loggerlogger; @Inject publicListView(Composite parent) {// ...
  • 69.
    Eclipse and thewebEclipse e4 targets to bring the Eclipse IDE closer to the webOne way would be to run Eclipse in the web, e.g. via Eclipse RAPAnother way would be to run the web inside Eclipse
  • 70.
  • 71.
  • 72.
    Photo creditsNot theEclipse mascot http://www.sxc.hu/photo/666565Blue Sky with corn: http://www.sxc.hu/photo/570500Headless business man http://www.sxc.hu/photo/713927Money http://www.sxc.hu/photo/767230Old Book http://www.sxc.hu/photo/1273173Plug 1 http://www.sxc.hu/photo/603920Plug 2 http://www.sxc.hu/photo/182575USB Plug http://www.sxc.hu/photo/951745Lots of Plugs http://www.sxc.hu/photo/721092Police 1 http://www.sxc.hu/photo/860421Police 2 http://www.sxc.hu/photo/596144Boy in the water http://www.sxc.hu/photo/1022035Eye with the world in them http://www.sxc.hu/photo/928425Electronic parts http://www.sxc.hu/photo/643720Snail 1 http://www.sxc.hu/photo/1181451Snail 2 http://www.sxc.hu/photo/1181452Fork http://www.sxc.hu/photo/1186818Hammer http://www.sxc.hu/photo/604247Corn http://www.sxc.hu/photo/939151Thinking man http://www.sxc.hu/photo/324541