20020910 1 [________________________] eclipse project briefing materials. copyright (c) 2002...

79
20020910 3 Eclipse Project Eclipse Project

Upload: debra-watson

Post on 26-Dec-2015

218 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 3

Eclipse ProjectEclipse Project

Page 2: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 4

Eclipse Project Aims

■ Provide open platform for application development Provide open platform for application development toolstools– Run on a wide range of operating systemsRun on a wide range of operating systems– GUI and non-GUIGUI and non-GUI

■ Language-neutralLanguage-neutral– Permit unrestricted content typesPermit unrestricted content types– HTML, Java, C, JSP, EJB, XML, GIF, …HTML, Java, C, JSP, EJB, XML, GIF, …

■ Facilitate seamless tool integrationFacilitate seamless tool integration– At UI and deeperAt UI and deeper– Add new tools to existing installed productsAdd new tools to existing installed products

■ Attract community of tool developersAttract community of tool developers– Including independent software vendors (ISVs)Including independent software vendors (ISVs)– Capitalize on popularity of Java for writing toolsCapitalize on popularity of Java for writing tools

Page 3: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 5

Platform Runtime

Workspace

Help

Team

Workbench

JFace

SWT

Eclipse Project

JavaDevelopment

Tools(JDT)

Their Tool

Your Tool

AnotherTool

Eclipse Overview

Plug-inDevelopmen

tEnvironment

(PDE)

Eclipse Platform

Debug

Page 4: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 7

Eclipse Origins

■ Eclipse created by OTI and IBM teams responsible Eclipse created by OTI and IBM teams responsible for IDE productsfor IDE products– IBM VisualAge/Smalltalk (Smalltalk IDE) IBM VisualAge/Smalltalk (Smalltalk IDE) – IBM VisualAge/Java (Java IDE)IBM VisualAge/Java (Java IDE)– IBM VisualAge/Micro Edition (Java IDE)IBM VisualAge/Micro Edition (Java IDE)

■ Initially staffed with 40 full-time developersInitially staffed with 40 full-time developers■ Geographically dispersed development teamsGeographically dispersed development teams

– OTI Ottawa, OTI Minneapolis, OTI Zurich, IBM Toronto, OTI Ottawa, OTI Minneapolis, OTI Zurich, IBM Toronto, OTI Raleigh, IBM RTP, IBM St. Nazaire (France)OTI Raleigh, IBM RTP, IBM St. Nazaire (France)

■ Effort transitioned into open source projectEffort transitioned into open source project– IBM donated initial Eclipse code baseIBM donated initial Eclipse code base

• Platform, JDT, PDEPlatform, JDT, PDE

Page 5: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 8

Brief History of Eclipse

19991999

AprilApril - Work begins on Eclipse inside OTI/IBM- Work begins on Eclipse inside OTI/IBM

20002000

June June - Eclipse Tech Preview ships- Eclipse Tech Preview ships

20012001

MarchMarch - - http://www.eclipsecorner.org/http://www.eclipsecorner.org/ opens opens

JuneJune - Eclipse 0.9 ships- Eclipse 0.9 shipsOctoberOctober - Eclipse 1.0 ships- Eclipse 1.0 ships

NovemberNovember - IBM donates Eclipse source base- IBM donates Eclipse source base- eclipse.org board announced- eclipse.org board announced- - http://www.eclipse.org/http://www.eclipse.org/ opens opens

20022002

JuneJune - Eclipse 2.0 ships- Eclipse 2.0 shipsSeptemberSeptember - Eclipse 2.0.1 ships- Eclipse 2.0.1 ships

Page 6: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 10

What is Eclipse?

Java VMStandard Java2Virtual Machine

PlatformEclipse Platform

Java development tools

JDT

PDEPlug-in developmentenvironment

■ Eclipse is a universal platformEclipse is a universal platformfor integrating development toolsfor integrating development tools

■ Open, Open, extensible architecture based on plug-insextensible architecture based on plug-ins

Page 7: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 11

Eclipse Plug-in Architecture

■ Plug-in - Plug-in - smallest unit of Eclipse functionsmallest unit of Eclipse function– Big example: HTML editorBig example: HTML editor– Small example: Action to create zip filesSmall example: Action to create zip files

■ Extension point Extension point - named entity for collecting - named entity for collecting “contributions”“contributions”– Example: extension point for workbench preference UIExample: extension point for workbench preference UI

■ Extension - Extension - a contributiona contribution– Example: specific HTML editor preferencesExample: specific HTML editor preferences

Page 8: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 12

Eclipse Plug-in Architecture

■ Each plug-inEach plug-in– Contributes to 1 or more extension pointsContributes to 1 or more extension points– Optionally declares new extension pointsOptionally declares new extension points– Depends on a set of other plug-insDepends on a set of other plug-ins– Contains Java code libraries and other filesContains Java code libraries and other files– May export Java-based APIs for downstream plug-insMay export Java-based APIs for downstream plug-ins– Lives in its own plug-in subdirectoryLives in its own plug-in subdirectory

■ Details spelled out in the Details spelled out in the plug-in manifestplug-in manifest– Manifest declares contributionsManifest declares contributions– Code implements contributions and provides APICode implements contributions and provides API– plugin.xml file in root of plug-in subdirectoryplugin.xml file in root of plug-in subdirectory

Page 9: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 13

Plug-in Manifest

<plugin id = “com.example.tool" name = “Example Plug-in Tool" class = "com.example.tool.ToolPlugin"> <requires> <import plugin = "org.eclipse.core.resources"/> <import plugin = "org.eclipse.ui"/> </requires> <runtime> <library name = “tool.jar"/> </runtime> <extension point = "org.eclipse.ui.preferencepages"> <page id = "com.example.tool.preferences" icon = "icons/knob.gif" title = “Tool Knobs" class = "com.example.tool.ToolPreferenceWizard“/> </extension> <extension-point name = “Frob Providers“ id = "com.example.tool.frobProvider"/></plugin>

Declare contributionthis plug-in makes

Declare new extension point open to contributions from other plug-ins

Location of plug-in’s code

Other plug-ins needed

Plug-in identification

plugin.xml

Page 10: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 14

Eclipse Plug-in Architecture

■ Plug-in APlug-in A– Declares extension point PDeclares extension point P– Declares interface I to go with PDeclares interface I to go with P

■ Plug-in BPlug-in B– Implements interface I with its own class CImplements interface I with its own class C– Contributes class C to extension point PContributes class C to extension point P

■ Plug-in A instantiates C and calls its I methodsPlug-in A instantiates C and calls its I methods

plug-in A plug-in B

class Cinterface I

extensionpoint P

extension

■ Typical arrangementTypical arrangement

contributes

creates, calls

implements

Page 11: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 15

Eclipse Platform Architecture

■ Eclipse Platform Runtime is micro-kernelEclipse Platform Runtime is micro-kernel– All functionality supplied by plug-insAll functionality supplied by plug-ins

■ Eclipse Platform Runtime handles start upEclipse Platform Runtime handles start up– Discovers plug-ins installed on diskDiscovers plug-ins installed on disk– Matches up extensions with extension pointsMatches up extensions with extension points– Builds global plug-in registryBuilds global plug-in registry– Caches registry on disk for next timeCaches registry on disk for next time

Page 12: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 16

Plug-in Activation

■ Each plug-in gets its own Java class loaderEach plug-in gets its own Java class loader– Delegates to required plug-insDelegates to required plug-ins– Restricts class visibility to exported APIsRestricts class visibility to exported APIs

■ Contributions processed without plug-in activationContributions processed without plug-in activation– Example: Menu constructed from manifest info for Example: Menu constructed from manifest info for

contributed itemscontributed items

■ Plug-ins are activated only as neededPlug-ins are activated only as needed– Example: Plug-in activated only when user selects its Example: Plug-in activated only when user selects its

menu itemmenu item– Scalable for large base of installed plug-insScalable for large base of installed plug-ins– Helps avoid long start up timesHelps avoid long start up times

Page 13: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 17

Plug-in Fragments

■ Plug-in fragmentsPlug-in fragments holds some of plug-in’s files holds some of plug-in’s files– Separately installableSeparately installable

■ Each fragment has separate subdirectoryEach fragment has separate subdirectory– Separate manifest fileSeparate manifest file

■ Logical plug-in = Base plug-in + fragmentsLogical plug-in = Base plug-in + fragments

■ Plug-in fragments used forPlug-in fragments used for– Isolation of OS dependenciesIsolation of OS dependencies– Internalization – fragments hold translationsInternalization – fragments hold translations

Page 14: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 18

Plug-in Install

■ FeaturesFeatures group plug-ins into installable chunks group plug-ins into installable chunks– Feature manifest fileFeature manifest file

■ Plug-ins and features bear version identifiersPlug-ins and features bear version identifiers– major . minor . servicemajor . minor . service– Multiple versions may co-exist on diskMultiple versions may co-exist on disk

■ Features downloadable from web siteFeatures downloadable from web site– Using Eclipse Platform update managerUsing Eclipse Platform update manager– Obtain and install new plug-insObtain and install new plug-ins– Obtain and install updates to existing plug-insObtain and install updates to existing plug-ins

Page 15: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 19

Plug-in Architecture - Summary

■ All functionality provided by plug-insAll functionality provided by plug-ins– Includes all aspects of Eclipse Platform itselfIncludes all aspects of Eclipse Platform itself

■ Communication via extension pointsCommunication via extension points– Contributing does not require plug-in activationContributing does not require plug-in activation

■ Packaged into separately installable featuresPackaged into separately installable features– DownloadableDownloadable

Eclipse has open, Eclipse has open, extensibleextensible architecture based on plug-insarchitecture based on plug-ins

Page 16: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 21

Eclipse Platform

■ Eclipse Platform is the common baseEclipse Platform is the common base■ Consists of several key componentsConsists of several key components

Platform Runtime

Eclipse Platform

Workspace

Workbench

SWTJFace

Team Help Debug

Ant“Core”

“UI”

Page 17: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 22

Workspace Component

■ Tools operate on files in user’s Tools operate on files in user’s workspaceworkspace

■ Projects map to Projects map to directories in file systemdirectories in file system

■ {Files, Folders, Projects} {Files, Folders, Projects} termed termed resourcesresources

■ Workspace holds 1 or Workspace holds 1 or more top-level more top-level projectsprojects

■ Tools read, create, modify, and delete Tools read, create, modify, and delete resources in workspaceresources in workspace

■ Plug-ins access via workspace and Plug-ins access via workspace and resource APIsresource APIs

■ Tree of Tree of foldersfolders and and filesfiles

Page 18: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 23

Workspace and Resource API

■ Allows fast navigation of workspace resource treeAllows fast navigation of workspace resource tree■ Resource change listener for monitoring activityResource change listener for monitoring activity

– Resource deltas describe batches of changesResource deltas describe batches of changes■ Maintains limited history of changed/deleted filesMaintains limited history of changed/deleted files■ Several kinds of extensible resource metadataSeveral kinds of extensible resource metadata

– Persistent resource propertiesPersistent resource properties– Session resource propertiesSession resource properties– MarkersMarkers– Project naturesProject natures

■ Workspace session lifecycleWorkspace session lifecycle– Workspace save, exit, restoreWorkspace save, exit, restore

■ Incremental project buildersIncremental project builders

Page 19: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 24

Incremental Project Builders

■ Problem: coordinated analysis and transformation of Problem: coordinated analysis and transformation of thousands of filesthousands of files– Compiling all source code files in projectCompiling all source code files in project– Checking for broken links in HTML filesChecking for broken links in HTML files

■ Scalable solution requires incremental reanalysisScalable solution requires incremental reanalysis■ Incremental project builder API/frameworkIncremental project builder API/framework

– Builders are passed resource deltaBuilders are passed resource delta– Delta describes all changes since previous buildDelta describes all changes since previous build– Basis for incremental toolsBasis for incremental tools

■ Extensible – plug-ins define new types of buildersExtensible – plug-ins define new types of builders– JDT defines Java builderJDT defines Java builder

■ Configurable – any number of builders per projectConfigurable – any number of builders per project

Page 20: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 25

Workbench Component

■ SWT – generic low-level graphics and widget setSWT – generic low-level graphics and widget set■ JFace – UI frameworks for common UI tasksJFace – UI frameworks for common UI tasks■ Workbench – UI personality of Eclipse PlatformWorkbench – UI personality of Eclipse Platform

Workbench

SWTJFace

Page 21: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 26

SWT

■ SWT = Standard Widget ToolkitSWT = Standard Widget Toolkit■ Generic graphics and GUI widget setGeneric graphics and GUI widget set

– buttons, lists, text, menus, trees, styled text...buttons, lists, text, menus, trees, styled text...

■ SimpleSimple■ SmallSmall■ FastFast■ OS-independent APIOS-independent API■ Uses native widgets where availableUses native widgets where available■ Emulates widgets where unavailableEmulates widgets where unavailable

Page 22: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 27

Why SWT?

■ Consensus: hard to produce professional looking Consensus: hard to produce professional looking shrink-wrapped products using Swing and AWTshrink-wrapped products using Swing and AWT

■ SWT providesSWT provides– Tight integration with native window systemTight integration with native window system– Authentic native look and feelAuthentic native look and feel– Good performanceGood performance– Good portabilityGood portability– Good base for robust GUIsGood base for robust GUIs

■ The proof of the pudding is in the eating…The proof of the pudding is in the eating…

Page 23: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 28

Why SWT?

■ Eclipse Platform on Windows XPEclipse Platform on Windows XP

Page 24: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 29

Why SWT?

■ Eclipse Platform on Windows XP (skinned)Eclipse Platform on Windows XP (skinned)

Page 25: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 30

Why SWT?

■ Eclipse Platform on Linux - GTK 2.0Eclipse Platform on Linux - GTK 2.0

Page 26: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 31

Why SWT?

■ Eclipse Platform on Linux - MotifEclipse Platform on Linux - Motif

Page 27: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 32

Why SWT?

■ Eclipse Platform on Mac OS X - CarbonEclipse Platform on Mac OS X - Carbon

Page 28: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 33

JFace

■ JFace is set of UI frameworks for common UI tasksJFace is set of UI frameworks for common UI tasks■ Designed to be used in conjunction with SWTDesigned to be used in conjunction with SWT■ Classes for handling common UI tasksClasses for handling common UI tasks■ API and implementation are window-system API and implementation are window-system

independentindependent

Page 29: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 34

JFace APIs

■ Image and font registriesImage and font registries■ Dialog, preference, and wizard frameworksDialog, preference, and wizard frameworks■ Structured viewersStructured viewers

– Model-aware adapters for SWT tree, table, list widgetsModel-aware adapters for SWT tree, table, list widgets■ Text infrastructureText infrastructure

– Document model for SWT styled text widgetDocument model for SWT styled text widget– Coloring, formatting, partitioning, completionColoring, formatting, partitioning, completion

■ ActionsActions– Location-independent user commandsLocation-independent user commands– Contribute action to menu, tool bar, or buttonContribute action to menu, tool bar, or button

Page 30: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 35

Workbench Component

■ Workbench is UI personality of Eclipse PlatformWorkbench is UI personality of Eclipse Platform

■ UI paradigm centered aroundUI paradigm centered around– EditorsEditors– ViewsViews– PerspectivesPerspectives

Page 31: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 36

Workbench Terminology

Tool bar

PerspectiveandFast Viewbar

ResourceNavigatorview

Stackedviews

Propertiesview

Tasksview

Outlineview

Bookmarksview

Menu bar

Messagearea

EditorStatusarea

Texteditor

Page 32: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 37

Editors

■ Editors appear in workbench editor areaEditors appear in workbench editor area■ Contribute actions to workbench menu and tool barsContribute actions to workbench menu and tool bars■ Open, edit, save, close lifecycleOpen, edit, save, close lifecycle■ Open editors are stackedOpen editors are stacked

■ Extension point for contributing new types of editorsExtension point for contributing new types of editors■ Example: JDT provides Java source file editorExample: JDT provides Java source file editor■ Eclipse Platform includes simple text file editorEclipse Platform includes simple text file editor■ Windows only: embed any OLE document as editorWindows only: embed any OLE document as editor■ Extensive text editor API and frameworkExtensive text editor API and framework

Page 33: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 38

Views

■ Views provide information on some objectViews provide information on some object■ Views augment editorsViews augment editors

– Example: Outline view summarizes contentExample: Outline view summarizes content■ Views augment other viewsViews augment other views

– Example: Properties view describes selectionExample: Properties view describes selection

■ Extension point for new types of viewsExtension point for new types of views■ Eclipse Platform includes many standard viewsEclipse Platform includes many standard views

– Resource Navigator, Outline, Properties, Tasks, Resource Navigator, Outline, Properties, Tasks, Bookmarks, Search, …Bookmarks, Search, …

■ View API and frameworkView API and framework– Views can be implemented with JFace viewersViews can be implemented with JFace viewers

Page 34: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 39

Perspectives

■ Perspectives are arrangements of views and editorsPerspectives are arrangements of views and editors■ Different perspectives suited for different user tasksDifferent perspectives suited for different user tasks■ Users can quickly switch between perspectivesUsers can quickly switch between perspectives■ Task orientation limits visible views, actionsTask orientation limits visible views, actions

– Scales to large numbers of installed toolsScales to large numbers of installed tools■ Perspectives controlPerspectives control

– View visibilityView visibility– View and editor layoutView and editor layout– Action visibilityAction visibility

■ Extension point for new perspectivesExtension point for new perspectives■ Eclipse Platform includes standard perspectivesEclipse Platform includes standard perspectives

– Resource, Debug, …Resource, Debug, …■ Perspective APIPerspective API

Page 35: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 40

Other Workbench Features

■ Tools may alsoTools may also– Add global actionsAdd global actions– Add actions to existing views and editorsAdd actions to existing views and editors– Add views, action sets to existing perspectivesAdd views, action sets to existing perspectives

■ Eclipse Platform is accessible (Eclipse Platform is accessible (Section 508Section 508))■ Accessibility mechanisms available to all plug-insAccessibility mechanisms available to all plug-ins

Page 36: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 41

Workbench Responsibilities

■ Eclipse Platform manages windows and Eclipse Platform manages windows and perspectivesperspectives

■ Eclipse Platform creates menu and tool barsEclipse Platform creates menu and tool bars– Labels and icons listed in plug-in manifestLabels and icons listed in plug-in manifest– Contributing plug-ins not activatedContributing plug-ins not activated

■ Eclipse Platform creates views and editorsEclipse Platform creates views and editors– Instantiated only as neededInstantiated only as needed

■ Scalable to large numbers of installed toolsScalable to large numbers of installed tools

Page 37: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 42

Team Component

■ Version and configuration management (VCM)Version and configuration management (VCM)■ Share resources with team via a Share resources with team via a repositoryrepository■ Repository associated at project levelRepository associated at project level■ Extension point for new types of repositoriesExtension point for new types of repositories■ Repository provider API and frameworkRepository provider API and framework■ Eclipse Platform includes CVS repository providerEclipse Platform includes CVS repository provider■ Available repository providers*Available repository providers*

– ChangeMan (Serena)ChangeMan (Serena)– ClearCase (Rational)ClearCase (Rational)– CM Synergy (Telelogic)CM Synergy (Telelogic)– PVCS (Merant)PVCS (Merant)– StarTeam (Starbase)StarTeam (Starbase)

* September 2002

Page 38: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 43

Team Component

■ Repository providers have wide latitudeRepository providers have wide latitude– Provide actions suited to repositoryProvide actions suited to repository– No built-in process modelNo built-in process model

■ Integrate into workbench UI viaIntegrate into workbench UI via– Share project configuration wizardShare project configuration wizard– Actions on Team menuActions on Team menu– Resource decoratorsResource decorators– Repository-specific preferencesRepository-specific preferences– Specialized views for repository browsing, …Specialized views for repository browsing, …

Page 39: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 44

Debug Component

■ Common debug UI and underlying debug modelCommon debug UI and underlying debug model

Page 40: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 45

Debug Component

■ Launch configurationsLaunch configurations– How to run a program (debug mode option)How to run a program (debug mode option)

■ Generic debug modelGeneric debug model– Standard debug events: suspended, exit, …Standard debug events: suspended, exit, …– Standard debug actions: resume, terminate, step, …Standard debug actions: resume, terminate, step, …– BreakpointsBreakpoints– ExpressionsExpressions– Source code locatorSource code locator

■ Generic debug UIGeneric debug UI– Debug perspectiveDebug perspective– Debug views: stack frames, breakpoints, …Debug views: stack frames, breakpoints, …

■ Example: JDT supplies Java launcher and debuggerExample: JDT supplies Java launcher and debugger– Java debugger based on JPDAJava debugger based on JPDA

■ Debug mechanisms available to other plug-insDebug mechanisms available to other plug-ins

Page 41: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 46

Ant Component

■ Eclipse incorporates Eclipse incorporates Apache AntApache Ant■ Ant is Java-based build toolAnt is Java-based build tool

– ““Kind of like Make…without Make's wrinkles”Kind of like Make…without Make's wrinkles”■ XML-based build files instead of makefilesXML-based build files instead of makefiles■ Available from workbench External Tools menuAvailable from workbench External Tools menu■ Run Ant targets in build files inside or outside Run Ant targets in build files inside or outside

workspaceworkspace■ PDE uses Ant for building deployed form of plug-inPDE uses Ant for building deployed form of plug-in

Page 42: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 47

Help Component

■ Help is presented in a standard web browserHelp is presented in a standard web browser

Page 43: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 48

Help Component

■ Help books are HTML websHelp books are HTML webs■ Extension points for contributingExtension points for contributing

– entire booksentire books– sections to existing bookssections to existing books– F1-help pop upsF1-help pop ups

■ Eclipse Platform contributesEclipse Platform contributes– ““Workbench User Guide”Workbench User Guide”– ““Platform Plug-in Developer Guide” (APIs)Platform Plug-in Developer Guide” (APIs)– F1-help for views, editors, dialogs, …F1-help for views, editors, dialogs, …

■ JDT and PDE contribute their own helpJDT and PDE contribute their own help■ Help mechanisms available to all plug-insHelp mechanisms available to all plug-ins

■ Help search engine based on Help search engine based on Apache Apache LuceneLucene■ Headless help server based on Headless help server based on Apache TomcatApache Tomcat

Page 44: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 49

Internationalization

■ Eclipse Platform is internationalizedEclipse Platform is internationalized■ 1.0 translations available for following languages1.0 translations available for following languages

EnglishEnglish GermanGerman

SpanishSpanish ItalianItalian

FrenchFrench Portugese (Brazil)Portugese (Brazil)

JapaneseJapanese KoreanKorean

Chinese (Traditional)Chinese (Traditional) Chinese (Simplified)Chinese (Simplified)■ Translations live in plug-in fragmentsTranslations live in plug-in fragments

– Separately shippableSeparately shippable■ Internalization mechanisms available to all plug-insInternalization mechanisms available to all plug-ins

Page 45: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 50

Product Information

Splashscreen

Aboutproduct

info

Welcomepages

Aboutfeature

info

Windowimage

Page 46: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 51

Product Information

■ Primary feature controls product informationPrimary feature controls product information– Splash screenSplash screen– Window imageWindow image– About product infoAbout product info– Initial welcome pageInitial welcome page– Default perspectiveDefault perspective– Preference default overridesPreference default overrides

■ All features can provideAll features can provide– Welcome pageWelcome page– About feature infoAbout feature info

Page 47: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 52

Eclipse Platform - Summary

■ Eclipse Platform is the nucleus of IDE productsEclipse Platform is the nucleus of IDE products■ Plug-ins, extension points, extensionsPlug-ins, extension points, extensions

– Open, Open, extensible architectureextensible architecture■ Workspace, projects, files, foldersWorkspace, projects, files, folders

– Common place to organize & store development Common place to organize & store development artifactsartifacts

■ Workbench, editors, views, perspectivesWorkbench, editors, views, perspectives– Common user presentation and UI paradigmCommon user presentation and UI paradigm

■ Key building blocks and facilitiesKey building blocks and facilities– Help, team support, internationalization, …Help, team support, internationalization, …

Eclipse is a universal platform Eclipse is a universal platform forfor

integrating development toolsintegrating development tools

Page 48: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 54

Java Development Tools

■ JDT = Java development toolsJDT = Java development tools■ State of the art Java development environmentState of the art Java development environment

■ Built atop Eclipse PlatformBuilt atop Eclipse Platform– Implemented as Eclipse plug-insImplemented as Eclipse plug-ins– Using Eclipse Platform APIs and extension pointsUsing Eclipse Platform APIs and extension points

■ Included in Eclipse Project releasesIncluded in Eclipse Project releases– Available as separately installable featureAvailable as separately installable feature– Part of Eclipse SDK dropsPart of Eclipse SDK drops

Page 49: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 55

JDT Goals

■ Goal: To be #1 Java IDEGoal: To be #1 Java IDE

■ Goal: To make Java programmers smileGoal: To make Java programmers smile

Page 50: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 56

Java Perspective

■ Java-centric view of files in Java projectsJava-centric view of files in Java projects– Java elements meaningful for Java programmersJava elements meaningful for Java programmers

Javaproject

package

class

field

method

Javaeditor

Page 51: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 57

Java Perspective

■ Browse type hierarchiesBrowse type hierarchies– ““Up” hierarchy to supertypesUp” hierarchy to supertypes– ““Down” hierarchy to subtypesDown” hierarchy to subtypes

Typehierarchy

Selectedtype’s

members

Page 52: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 58

Java Perspective

■ Search for Java elementsSearch for Java elements– Declarations or referencesDeclarations or references– Including libraries and other projectsIncluding libraries and other projects

Hitsflaggedin marginof editor

All search results

Page 53: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 59

Java Editor

■ Hovering over identifier shows Javadoc specHovering over identifier shows Javadoc spec

Page 54: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 60

Java Editor

■ Method completion in Java editorMethod completion in Java editor

List of plausible methods Doc for method

Page 55: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 61

Java Editor

■ On-the-fly spell check catches errors earlyOn-the-fly spell check catches errors early

Preview

Clickto seefixes

ProblemQuickfixes

Page 56: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 62

Java Editor

■ Code templates help with drudgeryCode templates help with drudgery

Statementtemplate Preview

Page 57: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 63

Java Editor

Method stub insertionfor inherited methods

Method stub insertion for anonymous inner types

■ Java editor creates stub methodsJava editor creates stub methods

Page 58: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 64

Java Editor

Variable namesuggestion

Argument hints andproposed argumentnames

JavaDoccode assist

■ Java editor helps programmers write good Java codeJava editor helps programmers write good Java code

Page 59: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 65

Java Editor

■ Other features of Java editor includeOther features of Java editor include– Local method historyLocal method history– Code formatterCode formatter– Source code for binary librariesSource code for binary libraries– Built-in refactoringBuilt-in refactoring

Page 60: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 66

Refactoring

■ JDT has actions for refactoring Java codeJDT has actions for refactoring Java code

Page 61: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 67

Refactoring

■ Refactoring actions rewrite source codeRefactoring actions rewrite source code– Within a single Java source fileWithin a single Java source file– Across multiple interrelated Java source filesAcross multiple interrelated Java source files

■ Refactoring actions preserve program semanticsRefactoring actions preserve program semantics– Does not alter what program doesDoes not alter what program does– Just affects the way it does itJust affects the way it does it

■ Encourages exploratory programmingEncourages exploratory programming■ Encourages higher code qualityEncourages higher code quality

– Makes it easier to rewrite poor codeMakes it easier to rewrite poor code

Page 62: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 68

Refactoring

■ Full preview of all ensuing code changesFull preview of all ensuing code changes– Programmer can veto individual changesProgrammer can veto individual changes

List of changes

“before” vs. “after”

Page 63: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 69

Refactoring

■ Growing catalog of refactoring actionsGrowing catalog of refactoring actions– Organize importsOrganize imports– Rename {field, method, class, package}Rename {field, method, class, package}– Move {field, method, class}Move {field, method, class}– Extract methodExtract method– Extract local variableExtract local variable– Inline local variableInline local variable– Reorder method parametersReorder method parameters

Page 64: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 70

Eclipse Java Compiler

■ Eclipse Java compilerEclipse Java compiler– JCK-compliant Java compiler (selectable 1.3 and 1.4)JCK-compliant Java compiler (selectable 1.3 and 1.4)– Helpful error messagesHelpful error messages– Generates runnable code even in presence of errorsGenerates runnable code even in presence of errors– Fully-automatic incremental recompilationFully-automatic incremental recompilation– High performanceHigh performance– Scales to large projectsScales to large projects

■ Multiple other uses besides the obviousMultiple other uses besides the obvious– Syntax and spell checkingSyntax and spell checking– Analyze structure inside Java source fileAnalyze structure inside Java source file– Name resolutionName resolution– Content assistContent assist– RefactoringRefactoring– SearchesSearches

Page 65: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 71

Eclipse Java Debugger

■ Run or debug Java programsRun or debug Java programs

Threads and stack

frames

Editor with breakpoint

marks

Console I/O

Local variables

Page 66: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 72

Eclipse Java Debugger

■ Run Java programsRun Java programs– In separate target JVM (user selectable)In separate target JVM (user selectable)– Console provides stdout, stdin, stderrConsole provides stdout, stdin, stderr– Scrapbook pages for executing Java code snippetsScrapbook pages for executing Java code snippets

■ Debug Java programsDebug Java programs– Full source code debuggingFull source code debugging– Any JPDA-compliant JVMAny JPDA-compliant JVM

■ Debugger features includeDebugger features include– Method and exception breakpointsMethod and exception breakpoints– Conditional breakpointsConditional breakpoints– WatchpointsWatchpoints– Step over, into, return; run to lineStep over, into, return; run to line– Inspect and modify fields and local variablesInspect and modify fields and local variables– Evaluate snippets in context of methodEvaluate snippets in context of method– Hot swap (if target JVM supports)Hot swap (if target JVM supports)

Page 67: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 73

JDT APIs

■ JDT APIs export functionality to other plug-insJDT APIs export functionality to other plug-ins

■ Java modelJava model– Java-centric analog of workspaceJava-centric analog of workspace– Tree of Java elements (down to individual methods)Tree of Java elements (down to individual methods)– Java element deltasJava element deltas– Type hierarchiesType hierarchies– Model accurate independent of buildsModel accurate independent of builds

■ Building blocksBuilding blocks– Java scannerJava scanner– Java class file reader Java class file reader – Java abstract syntax trees (down to expressions)Java abstract syntax trees (down to expressions)

■ Many others…Many others…

Page 68: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 74

Eclipse JDT - Summary

■ JDT is a state of the art Java IDEJDT is a state of the art Java IDE■ Java views, editor, refactoringJava views, editor, refactoring

– Helps programmer write and maintain Java codeHelps programmer write and maintain Java code■ Java compilerJava compiler

– Takes care of translating Java sources to binariesTakes care of translating Java sources to binaries■ Java debuggerJava debugger

– Allows programmer to get inside the running programAllows programmer to get inside the running program

Eclipse Javaprogrammmers

Page 69: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 76

Plug-in Development Environment

■ PDE = Plug-in development environmentPDE = Plug-in development environment■ Specialized tools for developing Eclipse plug-insSpecialized tools for developing Eclipse plug-ins

■ Built atop Eclipse Platform and JDTBuilt atop Eclipse Platform and JDT– Implemented as Eclipse plug-insImplemented as Eclipse plug-ins– Using Eclipse Platform and JDT APIs and extension Using Eclipse Platform and JDT APIs and extension

pointspoints

■ Included in Eclipse Project releasesIncluded in Eclipse Project releases– Separately installable featureSeparately installable feature– Part of Eclipse SDK dropsPart of Eclipse SDK drops

Page 70: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 77

PDE Goals

■ Goal: To make it easier to develop Eclipse plug-insGoal: To make it easier to develop Eclipse plug-ins

■ Goal: Support self-hosted Eclipse developmentGoal: Support self-hosted Eclipse development

Page 71: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 78

PDE

■ PDE templates for creating simple plug-in projectsPDE templates for creating simple plug-in projects

Page 72: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 79

PDE

■ Specialized PDE editor for plug-in manifest filesSpecialized PDE editor for plug-in manifest files

Page 73: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 80

PDE

■ PDE runs and debugs another Eclipse workbenchPDE runs and debugs another Eclipse workbench

1. Workbenchrunning PDE

(host)

2. Run-timeworkbench

(target)

Page 74: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 81

PDE - Summary

■ PDE makes it easier to develop Eclipse plug-insPDE makes it easier to develop Eclipse plug-ins

■ PDE also generates Ant build scriptsPDE also generates Ant build scripts– Compile and create deployed form of plug-inCompile and create deployed form of plug-in

PDE is basis for self-hostedPDE is basis for self-hostedEclipse developmentEclipse development

Page 75: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 83

Eclipse Operating Environments

■ Eclipse Platform currently* runs onEclipse Platform currently* runs on– Microsoft® Windows® XP, 2000, NT, ME, 98SEMicrosoft® Windows® XP, 2000, NT, ME, 98SE– Linux on Intel x86 - Motif, GTK 2.0Linux on Intel x86 - Motif, GTK 2.0

• RedHat Linux 7.2 x86RedHat Linux 7.2 x86• SuSE Linux 7.3 x86SuSE Linux 7.3 x86

– Sun Solaris 8 SPARC – MotifSun Solaris 8 SPARC – Motif– HP-UX 11i hp9000 – MotifHP-UX 11i hp9000 – Motif– IBM® AIX 5.1 on PowerPC – MotifIBM® AIX 5.1 on PowerPC – Motif

* September 2002

Page 76: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 84

Other Operating Environments

■ Most Eclipse plug-ins are 100% pure JavaMost Eclipse plug-ins are 100% pure Java– Freely port to new operating environmentFreely port to new operating environment– Java2 and Eclipse APIs insulate plug-in from OS and Java2 and Eclipse APIs insulate plug-in from OS and

window systemwindow system

■ Gating factor: porting SWT to native window systemGating factor: porting SWT to native window system■ Under development*Under development*

– Mac OS X PowerPC – Carbon window systemMac OS X PowerPC – Carbon window system– QNX Intel x86 - Photon window systemQNX Intel x86 - Photon window system

* September 2002

■ Eclipse Platform also runs “headless”Eclipse Platform also runs “headless”– Example: help engine running on serverExample: help engine running on server

Page 78: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 87

Who’s Shipping on Eclipse?

■ Rational® XDE™ Professional v2002: Java™ Platform EditiRational® XDE™ Professional v2002: Java™ Platform Editionon

■ Rational® Clearcase® Plug-in for Eclipse: WindowsRational® Clearcase® Plug-in for Eclipse: Windows■ Instantiations CodePro Studio V1.1Instantiations CodePro Studio V1.1■ Parasoft Jtest 4.5aParasoft Jtest 4.5a■ Versant enJin 2.2.3Versant enJin 2.2.3■ Merant PVCS Version Manager 6.8Merant PVCS Version Manager 6.8■ SerenaSerena™™ ChangeMan ChangeMan™™ DS DS■ Starbase StarTeam WebSphere Studio Integration Version 1.0Starbase StarTeam WebSphere Studio Integration Version 1.0■ Telelogic Technologies North America, Telelogic CM Synergy 6.2 Telelogic Technologies North America, Telelogic CM Synergy 6.2

* September 2002

Page 79: 20020910 1 [________________________] Eclipse project briefing materials. Copyright (c) 2002 International Business Machines Corp. All rights reserved

20020910 88

Who’s Shipping on Eclipse?

■ IBM uses Eclipse for WebSphere Studio FamilyIBM uses Eclipse for WebSphere Studio Family– IBM WebSphere® Studio Application Developer, IBM WebSphere® Studio Application Developer,

Version 4.0.3Version 4.0.3– IBM WebSphere® Studio Application Developer IBM WebSphere® Studio Application Developer

Integration Edition for Windows®, v4.1Integration Edition for Windows®, v4.1– IBM WebSphere® Studio Site Developer Advanced for IBM WebSphere® Studio Site Developer Advanced for

Windows®, V4.0.3Windows®, V4.0.3– IBM WebSphere® Studio Device Developer 4.0IBM WebSphere® Studio Device Developer 4.0– IBM WebSphere® Development Studio for iSeries IBM WebSphere® Development Studio for iSeries

Version 5 Release 2Version 5 Release 2– IBM WebSphere® Studio Enterprise Developer (in IBM WebSphere® Studio Enterprise Developer (in

beta)beta)

* September 2002