You are on page 1of 353

Eclipse

Eclipse .doc

1 353

Jacky Lee
2005/03/01

Eclipse .doc

2 353

0............................................................................................................12
1.Eclipse .....................................................................................................13
1.1 ..................................................................................................13
1.2 ........................................................................................14
1.3 Eclipse ......................................................................................15
1.4 ........................................................................................16
2. Eclipse Platform.............................................................................................18
2.1 ........................................................................................................18
2.2 ........................................................................................................19
2.3 ...........................................................................................20
2.4 ..................................................................................................20
2.5 (workspace).................................................................................21
2.6 (workbench).................................................................................22
2.6.1 (View).....................................................................................23
2.6.2 (Editor)................................................................................26
2.6.3 (Perspective)..........................................................................30
2.7 ...............................................................................32
Eclipse .doc

3 353

2.7.1 ........................................................................................32
2.7.2 ..................................................................................33
2.7.3 .....................................................................................34
2.7.4 ..................................................................36
2.7.5 ............................................................................................37
2.8 ...........................................................................................38
2.8.1 ...............................................................................................39
2.8.2 .....................................................................................58
2.9 ........................................................................................................64
2.9.1 ............................................................................................64
2.9.2 ............................................................................................66
2.9.3 ........................................................................................67
2.9.4 ........................................................................................70
2.10 .............................................................................................72
2.10.1 ...............................................................................72
2.10.2 ...................................................................................73
2.10.3 ......................................................................................75
2.11 ......................................................................................................76
2.11.1 .............................................................................76
Eclipse .doc

4 353

2.11.2 ......................................................................................78
2.11.3 ......................................................................................79
2.12 (Fast View)..............................................................................81
2.12.1 ................................................................................82
2.12.2 ................................................................................83
2.13 ......................................................................................................85
2.13.1 ......................................................................................86
2.13.2 ......................................................................................87
2.13.3 ......................................................................................89
2.14 ................................................................................................92
2.15 UI..................................................................................................94
3.(Preferences).....................................................................................98
3.1 (Workbench).................................................................................99
3.1.1 (Appearance).......................................................................102
3.1.2 (Capabilities)........................................................................104
3.1.3 (Colors and Fonts)......................................................106
3.1.4 /(Compare/Patch)...........................................................108
3.1.5 (Editors)............................................................................111
3.1.6 (File Associations)..........................................................113
Eclipse .doc

5 353

3.1.7 (Keys)...................................................................................116
3.1.8 (Label Decorations).......................................................127
3.1.9 (Linked Resources)........................................................128
3.1.10 (Local History).............................................................130
3.1.11 ...........................................................................................132
3.1.12 (Search).............................................................................133
3.1.13 (Startup and Shutdown)...........................................135
3.2 Ant.......................................................................................................136
3.2.1 Ant (Ant Editor).................................................................137
3.2.2 Ant (Ant Runtime).........................................................139
3.3 (Build Order)...........................................................................142
3.4 (Help)............................................................................................144
3.4.1 (Help Server)..............................................................146
3.5 (Install/Update).......................................................................148
3.6 Java ....................................................................................................148
3.6.1 (Appearance).......................................................................150
3.6.2 (Classpath variables)...............................................151
3.6.3 (Code Formatter)...........................................153
3.6.4 (Code generation)...................................................155
Eclipse .doc

6 353

3.6.5 (Compiler).........................................................................158
3.6.6 Java (Java editor)..............................................................165
3.6.7 JRE (JRE installations)..........................................................177
3.6.8 JUnit ..........................................................................................178
3.6.9 (New project)....................................................................179
3.6.10 (Organize imports).......................................................180
3.6.11(Refactoring preferences)................................181
3.6.12 (Task Tags)..................................................................182
3.7 (Team)...........................................................................................183
3.7.1 CVS............................................................................................184
3.7.2 (Ignored Resources)...................................................191
3.7.3 (File Content).................................................................192
4. Java ................................................................................................194
4.1 Java ........................................................................................195
4.2 Java ........................................................................................197
4.3 ...................................................................................199
4.3.1 Code Completion.......................................................................199
4.3.2 Code Assist................................................................................199
4.4 Java ........................................................................................201
Eclipse .doc

7 353

4.5 Java (Java Scrapbook Page)...........................................205


4.6 .........................................................................................212
4.6.1 ................................................................................212
4.6.2 ..........................................................................214
4.6.3 Javadoc ...............................................................................217
4.7 getter setter.............................................................................222
4.8 JAR ........................................................................................224
4.8.1 JAR .........................................................................224
4.8.2 ................................................................................227
4.8.3 JAR manifest................................................................229
4.8.4 JAR ............................................................................233
4.9. Javadoc .................................................................................235
4.9.1 Javadoc ...........................................................235
4.9.2 doclet Javadoc ................................................236
4.9.3 Javadoc .....................................................................238
4.10 (Working Sets).........................................................................239
4.10.1 .................................................................................240
4.10.2 ........................................................242
4.10.3 ........................................................244
Eclipse .doc

8 353

5................................................................................................................245
5.1 .............................................................................................245
5.2 (Breakpoints).......................................................................247
5.3 ................................................................................................252
5.3.1 Step Into....................................................................................253
5.3.2 Step Over...................................................................................253
5.3.3 Step Return................................................................................253
5.3.4 Drop to Frame............................................................................253
5.3.5 Use Step Filters/Step Debug......................................................254
5.4 ................................................................................................256
5.5 Hit Count..........................................................................258
5.6 ......................................................................................265
5.7 (Watchpoint)..............................................................................268
5.8 (Method Breakpoint).........................................................271
5.9 (Exception Breakpoint)........................................................274
5.10 Java ......................................................................276
6.(Refactoring)..........................................................................................280
6.1 ................................................................................................281
6.1.1 (Local Variable)..............................................................281
Eclipse .doc

9 353

6.1.2 (Field)...................................................................................283
6.1.3 (Method)..............................................................................285
6.1.4 (Class)(Interface).....................................................287
6.1.5 (Package).............................................................................289
6.2 (Extracting)...................................................................................291
6.2.1 (Extracting a Constant)..................................................291
6.2.2 (Extracting a Local Variable)...................................295
6.2.3 (Extracting a Method)....................................................299
6.3 (Inlining)........................................................................................305
6.3.1 (Inlining a Constant)......................................................307
6.3.2 (Inlining a Local Variable)........................................309
6.3.3 (Inlining a Method).........................................................311
6.4 (Signature)........................................................................314
6.5 Java (Moving Java Elements)..................................................319
6.5.1 (Field)...................................................................................320
6.5.2 Static Members..........................................................................321
6.6 (Self Encapsulating a Field)..............................................324
7.(Tips and Tricks)...........................................................................328
7.1 (Editing Source)................................................................328
Eclipse .doc

10 353

7.2 (Searching)....................................................................................334
7.3 (Code navigation and reading)................................337
7.4 Java (Java views)...........................................................................341
7.5 (Debugging)..................................................................................344
7.6 (Various)........................................................................................347

Eclipse .doc

11 353

0.

Microsoft Windows XP Professional


Service Pack 2

Eclipse

VersionEclipse 3.0.1 SDK (Release)


Build id200409161125
File Nameeclipse-SDK-3.0.1-win32.zip

Eclipse's Help
O'REILLY Eclipse
Eclipse - Java

Eclipse .doc

12 353

1.Eclipse

Eclipse
Eclipse
- Eclipse (Eclipse
)

1.1

Eclipse IBM
IBM 4 IDE(Integrated
Development Environment) 1.0 2001 11

Eclipse (Open Source Project)


IBM eclipse.org
(http://www.eclipse.org)
Eclipse .doc

13 353

Eclipse Project Management Committee(PMC)


Eclipse 3

-Platform

-Java Development Toolkit(JDT)

-Plug-in Development Environment(PDE)

Platform
CompareHelp SearchJDT
User Interface(UI)(Core)(Debug)PDE
UI Core

1.2

Eclipse

(copyright)
(copyleft)
Eclipse .doc

14 353


Eclipse
-Common Public License(CPL)
CPL Eclipse

CPL Open Software Initiative(OSI)

1.3 Eclipse

eclipse.org
(http://www.eclipse.org/downloads)
-
(build)

(Release builds)
Eclipse Release builds

Eclipse .doc

15 353

(Stable builds)
Release build Eclipse

beta

(Integration builds)
Eclipse

Stable build

(Nightly builds)

bug

1.4

Eclipse Java IDE Eclipse


Java IDE( JDT) PDE Eclipse
JDT Eclipse Eclipse
Eclipse (Eclipse Platform)
Eclipse .doc

16 353

Java

Java Eclipse JDT


CDT(C
Development Toolkit) C/C++
Eclipse

(plug-in fragment)IBM (
)()
Eclipse Java
Eclipse
SWT(Standard Widget Toolkit)
Eclipse
SWT
WindowsLinux/MotifLinux/GTK2SolarisQNXAIXHP-UX
Mac OS X

Eclipse .doc

17 353

2. Eclipse Platform

Eclipse
Eclipse
Eclipse
Eclipse
(
extension points)(contributions))

2.1

Eclipse Eclipse workspace

Eclipse

Eclipse .doc

18 353

release notes
workspace workspace
Eclipse

2.2

Eclipse (platform kernel)


(workbench)(workspace)(tram
component)(help)

2.0

Eclipse .doc

19 353

2.3

Eclipse
/
Eclipse

workspace
Eclipse

2.4

Eclipse

Eclipse .doc

20 353

2.5 (workspace)

()
Eclipse

(project nature)Java

Eclipse .doc

21 353

2.6 (workbench)

Eclipse (workbench) 2.1


Eclipse Eclipse
Eclipse
workbench
()
JDT

2.1

Eclipse .doc

22 353

Eclipse
Eclipse
Eclipse (Standard Widget
Toolkit-SWT) JFace( SWT )SWT
(look-and-feel)
Java
Swing

2.6.1 (View)

(view)
-(editor)
2.1Outline
Java Navigator

Eclipse .doc

23 353

Navigator

2.2

2.3

Eclipse .doc

24 353

2.4

2.5

WindowReset Perspective

Eclipse .doc

25 353

WindowShow View
Show
ViewShow ViewOther...

2.6

2.6.2 (Editor)

Eclipse
Eclipse ( 2.7)
Eclipse .doc

26 353

Java JDT Java ( 2.8)


Word Word ( 2.9) Word
Object Linking and Embedding-OLE Eclipse

2.7

Eclipse .doc

27 353

2.8

Windows
OLE(Object Linking and Embedding)
Microsoft Word DOC
Microsoft Word( 2.9) Microsoft
Word Word Pad

Eclipse .doc

28 353

2.9

(*)( 2.9)

Ctrl+F6

Ctrl+F6

Eclipse .doc

29 353

Macinosh Command+F6

2.6.3 (Perspective)

Eclipse
(perspective)
Java
2.10

2.10

Eclipse .doc

30 353

Debug

2.11

2.11

Eclipse .doc

31 353

2.7

2.7.1

Eclipse .doc

32 353

2.7.2

Navigator
I. Navigator

II.

III.

IV.

V. NavigatorOutline
Navigator
Outline

Eclipse .doc

33 353

2.7.3

I. Navigator

II.

III.

IV.

V.

VI.

VII.
Eclipse .doc

34 353


-
Windows XP -

Outline

VIII.

2.12

Eclipse .doc

35 353

2.12

2.7.4

I. WindowReset PerspectiveResource

II. OutlineNavigator
OutlineNavigator
II. NavigatorOutline

IV. Outline

NavigatorOutline

Eclipse .doc

36 353

2.7.5

Maximize

Minimize

Restore

Eclipse .doc

37 353

2.8

1
6

2
3

2.13

1.(Menu Bar)
2.(Tool Bar)
3.(Fast View)
4.Package Explorer
5.Editor
Eclipse .doc

38 353

6.(Shortcut Toolbar)
7.Outline
8.Tasks Console

2.8.1

File

New()

Close()

Java
WindowPreferences Java

Close All()

Save()

Save As()
Save All()

Revert()

Eclipse .doc

39 353

Move()

Java Java
RefactorMove
EditCut/Paste

Rename() Java
Java RefactorRename

Refresh()

Print()

Switch

workspace(
)
Open external

file()
Import()

JDT

Export()

JDT JAR
Javadoc

Properties()

Java Java
Javadoc JAR
JAR Javadoc

Recent file list( File


File
Exit()

Eclipse

Edit
Eclipse .doc

40 353

Undo()

Redo()

Cut()

Copy()

Paste ()

Delete()

Select All()

Find / Replace( /
/)
Find Next(
)
Find Previous(
)

Incremental Find
Next(
)
Incremental Find
Previous(
)
Add Bookmark(
)
Add Task()
Expand Selection
to()

Eclipse .doc

Java

41 353

Show Tooltip
Description(
)

Content Assist( Java


)

WindowPreferencesJavaEditorT
emplates
WindowPreferencesJavaEditor
Code Assist
Quick Fix()

Parameter
Hints()

Encoding()

Source

Toggle
Comment()

Eclipse .doc

42 353

Add Block

Comment(
)
Remove Block

Comment(
)
Shift Right(
)

Shift Left()

Format()

Code Formatter
WindowPreferencesJavaCode
Formatter

Format

Element()
Sort Members( Window
PreferencesJavaAppearance
)
Members Sort Order

Organize

Imports() Organize Import


WindowPreferencesJavaOrganize
Import
Organize Import

Add Import(
)

Eclipse .doc

43 353


Add ImportOrganize Import

Override/Implem Override Method


ent Methods(/
)
Generate Getter Generate Getter and Setter
and Setter( Getter Setter
Getter Setter)
Generate
Generate Delegate Methods
Delegate

Methods(
)
Add Constructor Super
from

Superclass(
Super
)
Surround with
try/catch(
try/catch )

try catch

Externalize
Externalize Strings
Strings(
)
Find Strings to

Externalize(
)
Convert Line

Delimiters To(
)
CRLF(Windows)

Eclipse .doc

44 353

LFUnixMacOSX

CR MacOS

Java
OS

Refactor
Java

Undo()

Undo

Redo()

Rename()

Rename Refactoring

Move()

Move

Static Static

Eclipse .doc

45 353

Change Method
Change Method Signature
Signature(
)

Convert
Convert Anonymous Class to Nested
Anonymous Class
to Nested(
)
Convert Nested
Type to Top
Level(
)

Convert Nested Type to Top Level


Java
static

Push Down()

Push Down

Pull Up()

Pull Up
Super Super
abstract

Extract Interface( Extract Interface


)

Use Supertype
Use Supertype Where Possible
Where Possible(
Super ) Super
Inline()

Eclipse .doc

Inline
static final
46 353

static final
Extract Method( Extract Method
)

Extract Local
Extract Local Variable
Variable(
)

Extract Constant( Extract Constant


)
static final

static final static final

Convert Local
Convert Local Variable to Field
Variable to Field(
)

Encapsulate
Field()

Encapsulate Field
getting setting

Navigate

Go Into()

Eclipse .doc

47 353

Go To()

Go
Into

Go
Into Go IntoBack

JUnit

Package Explorer

Package Explorer


Open()

Open Type

Hierarchy( Type Hierarchy


)
Java Java

Open Call

Hierarchy( Call Hierarchy


Eclipse .doc

48 353

)
Open Super

Implementation( super
super )
super
Open External
Javadoc(
Javadoc)

Javadoc JAR
Javadoc JAR Javadoc
Location
Javadoc
Javadoc Javadoc
Java Javadoc

Open Type() Open Type

Open Type In
Open Type
Hierarchy( Type Hierarchy Open
)
Type
Show in Package Package Explorer
Explorer(
)
Quick Outline(
)

Quick Type

Hierarchy(
)
Next Annotation ( Java
)
Previous Annotation
()

Java

Go to Last Edit

Location(
)

Eclipse .doc

49 353

Go to Line(
)

Back()

Web

Forward(

Web

Search

Search...(...)

File...(...)

Java...(Java...)

Java

References()

Java

Declarations()

Java

Implementors()

Read Access()

Write Access()

Referring Tests...()

Java

Occurrences in File(
)

Java

Exception
Java
Occurrences(
)

Search Scopes Submenu()

Workspace(
)
Eclipse .doc

50 353

Project()

Hierarchy()
Workings Set(
)

Java

Package Explorer

Outline

Search Result

Hierarchy

Browsing

Java Search
Java
Java SearchJava
Java

Project

Eclipse .doc

51 353

Open Project(
)
Close Project(
)
Build All()

(incremental)

Build Project( (incremental)


)

Build Workings
(incremental)
Set()

Clean()

Build

Automatically(
)
Generate
Javadoc...(
Javadoc...)

Generate Javadoc

Properties()

Run

Toggle Line
Java
Breakpoint( Java
Eclipse .doc

52 353

)
Toggle Method

Breakpoint( Java
)
Outline

Toggle
Java
Watchpoint( Java
)
Outline
Skip All
Breakpoints(
)

Add Java Exception


Breakpoint( Java
)
VM

Add Class Load


Breakpoint

Class Load

Run Last

Launched(
)
Debug Last

Launched(
)
Run History()

Run As()

Run...(...)

Debug History(
Eclipse .doc

53 353

Debug As()

Debug...(...)

Inspect()

Display()

Display

Java
Snippet Editor(Java )

Execute()

Step into Selection


Externakl Tools(
)

Windows

New Window(
)

Open Perspective(
)
WindowPreferencesWorkbenchPer
Eclipse .doc

54 353

spectives

Show View()
WindowPreferencesWorkbenchPer
spectives

...
Show View
Customize

Perspective()
Save Perspective
As()

WindowShow
ViewOther...

Reset

Perspective()
Close Perspective(
)
Close All

Perspectives(
)
Navigation()

Eclipse .doc

55 353

Eclipse .doc

56 353

Preferences(
)

Help

Welcome()
Help Contents(
)

Tips and Tricks(


)

Cheat Sheets()
Software
Updates()

About Eclipse
Platform(
Eclipse )

Eclipse .doc

57 353

2.8.2

Navigator
Navigator

Tasks
Eclipse .doc

58 353

Tasks

Ant

Eclipse .doc

59 353

Ant

Ant
Ant

Ant
Ant
Jar
Ant
Ant
Ant
Ant
Ant macrodef

Eclipse .doc

60 353

Ant

Ant

Ant

Eclipse .doc

61 353

)

(
)

Return

(
)

Eclipse .doc

62 353

Static

VM


(
)
(
)

Eclipse .doc

63 353

2.9

2.9.1

Open Perspective

WindowOpen Perspective

I. Open Perspective

II. WindowOpen
PerspectiveOther...

2.14

Eclipse .doc

64 353

III. Select Perspective Debug


OK

2.15

Debug
IV.

Debug
Resource
DebugDebug

Eclipse .doc

65 353

Show Text

2.16

V. Resource
Resource

2.9.2

WindowPreferencesWorkbenchPerspectives

Eclipse .doc

66 353

2.17

2.9.3

I. ResourceResource

II. OutlineNavigator
III. WindowSave Perspective As...
Eclipse .doc

67 353

IV. Save Perspective As...

OK Resource
OK

2.18

V. ResourceOutline

VI. WindowReset PerspectiveOutline


Navigator

Eclipse .doc

68 353

Outline
VII. WindowNew Window

VIII.
Resource
Resource
I. WindowPreferences
II. Workbench Perspective
III. Resource Reset OK

Eclipse .doc

69 353

2.19

IV.
Resource
WindowReset Perspective

2.9.4

New Window

WindowOpen Perspective

WindowShow View

I. Resource
II. WindowCustomize Perspective...
III. Commands
IV. Launch OK

Eclipse .doc

70 353

2.20

V. /

VI. Customize Perspective...


WindowReset Perspective

Eclipse .doc

71 353

2.10

Tasks
Tasks

2.10.1

I. TasksAdd Task

II. Enter
EscTasks

Eclipse .doc

72 353

2.21

2.10.2

Hello.java
I. Navigator Java (Hello.java)
II.

III. Add Task


/

Eclipse .doc

73 353

2.22

IV. Description

2.23

V. OK
VI.
Tasks
VII.
Eclipse .doc

74 353


VIII.
IX.
Tasks

X. Tasks
XI. Mark Completed
XII. Delete Completed Tasks
XIII. Tasks

2.10.3

Tasks

Go To

Eclipse .doc

75 353

2.11

Bookmarks
Bookmarks
BookmarksResource
Window

Show ViewBookmarks

2.11.1

Bookmarks
I. WindowShow
ViewBookmarksBookmarks

II. Hello.java
III.
Add Bookmark
Eclipse .doc

76 353

2.24

Add Bookmark

IV.

2.25

Eclipse .doc

77 353

Bookmarks

2.26

V. Navigator Hello.java
EditAdd Bookmark

Bookmarks

2.27

2.11.2

I.
II. Bookmarks
Eclipse .doc

78 353


III.

Bookmarks
Go To
Bookmarks
I. Bookmarks
II. Shoe in Navigator
III. Navigator
Hello.java Hello.java

2.11.3

I. Bookmarks Hello.java



Delete
Bookmarks

Eclipse .doc

79 353

2.28

II. Hello.java

Hello.java Remove Bookmark


Add
Bookmark

2.29

Eclipse .doc

80 353

Bookmarks

III. Hello.java

IV. Bookmarks Hello.java



Bookmarks Hello.java

2.12 (Fast View)

Navigator

Eclipse .doc

81 353

2.12.1

Navigator

I. Navigator

II. ""

Navigator
Fast View

Eclipse .doc

82 353

2.30

2.12.2

Navigator

I. Navigator
II. Navigator

Eclipse .doc

83 353

2.31

III. Navigator

IV.

Navigator

Eclipse .doc

84 353

2.13

I. file1.txt
file1.txt

This is line 1.
This is line 2.
This is line 3.
This is line 4.
This is line 5.
II. file1.txt Ctrl+C
III. Ctrl+V
file2.txt
Mac Command+C Command+V
file1.txt file2.txt

Eclipse .doc

85 353

2.13.1

file1.txt file2.txt
Compare WithEach Other

2.32

file1.txt
I. 1 "This is line 1."
II. 3 "This is a much better line 3."
III. 4a 5 "This is line 4a
and it is new"
(file1.txt)
This is line 2.
This is a much better line 3.
This is line 4.
This is line 4a and it is new
Eclipse .doc

86 353

This is line 5.
FileSave Ctrl+S
file1.txt file2.txt
Compare WithEach Other

2.33

2.13.2

file1.txt file2.txt
file1.txt file2.txt

Eclipse .doc

87 353

3 21

2.34

I.

#1 "This is line 1"


II. "This is line 2."
III.
#2
IV. 4
V.
#3
Eclipse .doc

88 353

2.13.3

file1.txt file2.txt

2.35

Eclipse .doc

89 353

I.
II.
III.

I.

Eclipse .doc

90 353

2.36

II.

2.37

III. OK
Eclipse .doc

91 353

FileSave (Ctrl+S)

2.14

I. sampleFile.txt
II. sampleFile.txt "change1"

III. "change2"
IV. "change3"
V. NavigatorReplace
WithLocal History...
VI.

Eclipse .doc

92 353

2.38

VII.

Eclipse .doc

93 353

VIII. sampleFile.txt

IX. sampleFile.txt

2.15 UI

Eclipse
UI
Eclipse UI

Eclipse

Eclipse .doc

94 353

2.39

Project Run in
Background UI Eclipse

2.40

Details

Eclipse .doc

95 353

Detail

2.41

Progress Information

Eclipse .doc

96 353

2.42

WindowPreferencesWorkbench Always
run in background

2.43

Eclipse .doc

97 353

3.(Preferences)

Preferences
WindowPreferences

Import

Export

Eclipse .doc

98 353

3.1

3.1 (Workbench)

Eclipse .doc

99 353

Always run in

background(
)
Build

automatically(
)
Refresh

workspace

automatically(
)

Save

automatically

before build(
)
Keep

next/previous

part dialog

open(
/
)
Workspace save 5
interval (in

minutes)(

)
Open mode...(
...)

Eclipse .doc

100 353

Eclipse .doc

101 353

3.2

3.1.1 (Appearance)

Tab positions
Editors( -
)
Tab positions Views( Eclipse .doc

102 353

)
Perspective

switcher
position(
)

Current
3.0
presentation(

)
Current theme( 3.0
)
Show text on
perspective
bar(
)

Show traditional
style tabs(
)

Eclipse .doc

103 353

3.3

3.1.2 (Capabilities)

Java

Java

Eclipse .doc

104 353

3.4

Confirm Enablement
Details

Eclipse .doc

105 353

3.5

3.1.3 (Colors and Fonts)

Eclipse

Use System Font


Change
Reset
Eclipse .doc

106 353


Reset

3.6

Eclipse .doc

107 353

3.7

3.1.4 /(Compare/Patch)

/
(General)

Open structure
compare

Eclipse .doc

108 353

automatically
(
)
Show additional
compare

information in
the status

line(
)
Off()
Ignore white

space()

Automatically
save dirty

options before
patching(

Synchronize

scrolling
(lock scroll)
between panes
in compare
viewers(

)
Eclipse .doc

109 353

Initially show
ancestor

pane(
)

Show pseudo
conflicts(
)

Connect

ranges with

single line(
)

Eclipse .doc

110 353

3.8

3.1.5 (Editors)

Size of recently
opened files

list(
)

Show multiple
editor tabs(
) chevron
Eclipse .doc

111 353

Close all editors


on exit(
) Eclipse Eclipse

Close editors

automatically
() 8

Text File

Encoding(
)

(CP1252)

Eclipse .doc

112 353

3.9

3.1.6 (File Associations)

(File Associations)
Eclipse .doc

113 353

"*."".xml" "*.xml" "xml"

3.10

(Associated Editors)

Browse

Eclipse .doc

114 353

3.11

Eclipse .doc

115 353

3.12

3.1.7 (Keys)

Eclipse Eclipse

(Key Strokes)(Key Sequences)


(Key Bindings)

Eclipse .doc

116 353

CtrlAlt Macintosh OptionShift


Command Macintosh Ctrl
A Ctrl+A

emacs
emacs
Ctrl+X Ctrl+C
Ctrl+X Ctrl+C
Eclipse

(Configurations)
Eclipse

Emacs

Ctrl+A
Ctrl+S
Emacs Emacs
Eclipse .doc

117 353

Ctrl+X H Ctrl+X S
Emacs
Emacs

Emacs
Emacs

Emacs Emacs
Emacs
(Contexts)
Eclipse
Java
HTML
Ctrl+B Java
Ctrl+B HTML

Eclipse .doc

118 353


Eclipse



Java

Java

Java


Ctrl+X
Ctrl+W
Eclipse .doc

119 353

(Platform and Locale)

Macintosh Command+S
Ctrl+S (zh)Alt+/
Ctrl+
Eclipse
Eclipse
(Customizing Key Bindings)

WindowPreferencesWorkbenchKeys

Eclipse .doc

120 353

3.13

Emacs

Ctrl+F4 Ctrl+W Emacs Ctrl+X K

Ctrl+F4 Ctrl+W Ctrl+X K


Emacs Ctrl+X K
Emacs
Eclipse .doc

121 353

Ctrl+F4 Ctrl+W
Emacs "Ctrl+W"
Emacs

Ctrl+W
Ctrl+W
Ctrl+W
Ctrl+W
Ctrl+W

Ctrl+W Emacs

Ctrl+W

Eclipse .doc

122 353

3.14

Eclipse .doc

123 353

3.15

Emacs
Ctrl+Alt+W

Eclipse .doc

124 353

3.16

(The Dynamic Nature of Key


Bindings)
Eclipse

Eclipse
Emacs Ctrl+Alt+W
Ctrl+Alt+W
Eclipse
Eclipse .doc

125 353


(Conflict Resolution)

Ctrl+B
Ctrl+B
Ctrl+B Eclipse

Ctrl+F4
Ctrl+F4
Eclipse

Ctrl+F4

"[]"
Eclipse .doc

126 353

Emacs Ctrl+X
Ctrl+H K Ctrl+X H
Emacs
Ctrl+X Emacs
Ctrl+X Ctrl+X
Emacs Ctrl+X

Ctrl+X
Emacs

3.1.8 (Label Decorations)

Eclipse .doc

127 353

3.17

3.1.9 (Linked Resources)

Enable linked
Resources

Eclipse .doc

128 353

New Edit
Remove

""
Refresh

Eclipse .doc

129 353

3.18

3.1.10 (Local History)

Days To Keep
Files(

Eclipse .doc

130 353

)
Entries Per
File(
)

50

Maximum File
Size(MB)(
(MB))

3.19

Eclipse .doc

131 353

1 MB

3.1.11

Open a new
perspective
()

Open a new
view(
)

New project
options(
)

Make

Default(
)

Reset()

...

n/a

Delete()

n/a

Eclipse .doc

132 353

3.20

3.1.12 (Search)

Reuse
editors to show matches()

Emphasize inexact matches()


Eclipse .doc

133 353

Foreground color for inexact matches (


) Ignore inexact
matches ()Default perspective for the
Search view()

3.21
Eclipse .doc

134 353

3.1.13 (Startup and Shutdown)

Prompt for

workspace on
startup(
)

Refresh

workspace on
startup(
)

Confirm exit
when closing
last
window(

Eclipse .doc

135 353

3.22

3.2 Ant

Ant
Ant "-find"
Eclipse .doc

136 353

Ant

3.23

3.2.1 Ant (Ant Editor)

Ant
(Appearance Options)

Print margin
Ant
column(
)
Displayed tab Ant
width(
)
Eclipse .doc

137 353

80

Insert spaces
Ant
for tabs when
typing(
)

Show overview Ant


ruler(
)

Show line
Ant
numbers(
)

Highlight

current line(
)

Show print

margin(
)

Appearance

color options(
)

Ant

Eclipse .doc

138 353

3.24

3.2.2 Ant (Ant Runtime)

Ant

Eclipse .doc

139 353

3.25

Eclipse .doc

140 353

3.26

3.27

Ant

Eclipse .doc

141 353

3.28

3.3 (Build Order)

Java

Eclipse .doc

142 353

Add Projec
Remove Project

Eclipse .doc

143 353

3.29

3.4 (Help)

Eclipse .doc

144 353

Always use
Web
external

browsers(
)

Current web Web


browser

adapter(
Web

)
Custom
"C:\Progra
browser

m
command( URL Files\Inter
) "%1" URL
net

Explorer\I
EXPLORE.
EXE" %1 Windows
mozilla
%1 -

Eclipse .doc

145 353

3.30

Internet Explorer Mozilla


JavaScript

3.4.1 (Help Server)

Eclipse .doc

146 353

Host()

IP

Port ()

IP 0

3.31

Eclipse .doc

147 353

3.5 (Install/Update)

Automatically
search for

updates and
notify me (

)
Update
Schedule

()

3.6 Java

Java

Update Java
Eclipse .doc

(On save only)

148 353


views(
Java )

Java

(While editing)
Java

Action on
(Go into the selected

double click in element)

the Package
Explorer( Go Into

Go Into
)
(Expand the selected
element)

When opening (Open a new

a Type
Type Hierarchy Perspective)

Hierarchy(

Eclipse .doc

149 353

(Show
the Type Hierarchy View in the
current perspective)

3.6.1 (Appearance)

Java

Show method
return
types(
)

Eclipse .doc

150 353

Show override
indicators in

outline and
hierarchy(

Show
members in
Package
Explorer(

Java
Java

Compress

package name
segments(
)

Stack views
Java
vertically in

the Java
Browsing
perspective(
Java
)

3.6.2 (Classpath variables)

(Configurable variables)
Eclipse .doc

151 353

Java

New...(
...)

File Folder

Edit...(
...)

File Folder

Remove
()

(Reserved class path variables)

JRE_LIB JRE JAR

JRE_SRC JRE

JRE_SRCROOT JRE

Eclipse .doc

152 353

3.6.3 (Code Formatter)

Java

Insert a new
line before
an opening
brace(

Insert new
lines in
control
statements
(
)

ifelsecatchfinally

Clear all

blank lines(
)

Insert new
else-if "else" "if"
line between
'else
if'('else if'
)

Insert a new
line inside an

Eclipse .doc

153 353


empty
block(
)

Maximum

line length( 0
)
Compact
assignment
()

80

a= b;

Insert a

space after a
cast(
)

Insert tabs
tab
for
indentation,
not spaces(
tab
)

Number of
tab
spaces

representing
an
indentation
level(

)
Preview

pane( Java
Eclipse .doc

154 353

n/a

3.6.4 (Code generation)


(Names)
Static Static

Getter Setter

Edit...(...)

(Code and Comments)

Eclipse .doc

155 353

Edit...(...)
Import...(
...)

Export...(
...)

Export
All...(
...)

Automaticall
y add
comments
for new
methods and
types(

Javadoc
Java

(Comment templates)
${tags}
Javadoc (@param, @return..)
${see_to_overridden}

Eclipse .doc

156 353

Java

Javadoc Javadoc

Javadoc
Java (New Java files template)
Java

${typecomment}

Catch (Catch block body template)


catch Catch
${exception_type} ${exception_var}
(Method body template)

return / super ${body_statement}


Eclipse .doc

157 353


(Constructor body templates)

super ${body_statement}
(Code Template dialog)

Description()
Pattern()

Insert

Variables...(
...)

3.6.5 (Compiler)

Eclipse .doc

158 353

(Problems)

Unreachable
code(
)

Java

Unresolvable
import
statements(
import )

import

Java import

Unused local

variables (i.e.

never read)(

)
Unused

parameters (i.e.

never read)(

)
Unused imports(
)

Unused private
Private
types, methods or
fields (

private
)
Usage of nonEclipse .doc


159 353

externalized
strings(
)

//$NONNLS-<n>$

Usage of

deprecated API( API
API )
Signal use of
deprecated API
inside deprecated
code(

API )


API
API

Maximum number
of problems
reported per
compilation
unit(
)

100

(Style)

Methods

overridden but
not package

visible(

)
Methods with a
constructor

name(
Eclipse .doc

160 353

)
Conflict of

interface

method with

protected

'Object'
method( interface I {

) int clone();
}
Hidden catch
blocks(
catch )

try
catch

try { throw new


java.io.CharConversionException();
} catch (java.io.CharConversionException
e) {
} catch (java.io.IOException e) {}.

Non-static
Static
access to a

static
Static
member(Static
Static
)
Eclipse .doc

161 353

Access to a

non-accessible
member of an
enclosing
type(

)
Assignment
'x = x'
has no effect

(e.g. 'x = x')(

'x=x')
Using a char

array in string char[]


concatenation
(
char )
"hello" + new char[]{'w','o','r','l','d'}

(Compliance and Class files)

Compiler
JDK
compliance
level(
)

1.3

Use default

compliance

settings(
)

Generated

1.1

Eclipse .doc

162 353

class files
compatibility
(
)
Source
1.3 1.4 1.4
compatibility
"assert"
()

1.3

Report 'assert'
as
identifier
('assert'
)

'assert' JDK 1.4

Add variable
attributes to
generated
class files(

.class

Add line
number
attributes to
generated
class files(

Add source file


name to

generated
class file(

)
Eclipse .doc

163 353

Preserve

unused local

variables(
)

(Build Path)

Incomplete

build path(
)

Circular
dependencies
()

Duplicated
resources(
)

Abort building
on build path
errors(

)
Scrub output
folders on full
build(

Java

Enable using
exclusion
patterns in

Eclipse .doc

164 353

source
folders(

)
Enable using

multiple output
locations for
source
folders(

)
Filtered
resources(
)

3.6.6 Java (Java editor)

Java

(Appearance)
Java
Eclipse .doc

165 353

''

Displayed tab Tab


width(Tab
)

Print margin
column(
)

80

Show print
margin
Appearance color options

Synchronize
Java
outline
Java
selection on
cursor move(

)
Show overview Java
ruler(
)

Show line
numbers(
)

Java

Appearance color options

Highlight

matching

brackets(
) Appearance color options

Eclipse .doc

166 353

Highlight
current line(
)

Appearance color options

Show print
margin(
)

Print margin column Appearance


color options

Appearance
color
options(
)

Java

Line number foreground()

Matching brackets highlight(


)

Current line highlight()

Eclipse .doc

Print margin()

167 353

Find scope()

Linked position()

Link()

(Syntax)
Java

Background
System default()
color()

Custom()
Foreground(
)

Java

Multi-line comment()
'/*...*/'

Single-line comment()
'//'

Eclipse .doc

Keywords() Java

168 353

Strings()Java

Others() Java

Task tags()

Javadoc keywords(Javadoc )
Javadoc '@'

Javadoc HTML tags(Javadoc HTML


)Javadoc HTML

Javadoc links(Javadoc ){@link


reference}

Javadoc others(Javadoc )
Javadoc

Preview()

Java n/a

(Code assist)

Eclipse .doc

169 353


Completion
inserts/Comple
tion
overwrites(
/)

(Completion inserts)
(^)

(Completion
overwrites) (^)

Insert single

proposals

automatically
(
)

Show only
proposals
visible in the
invocation
context(

Java
private

Present
proposals in
alphabetical
order(
)

Automatically
add import
instead of
qualified
name(

Eclipse .doc

170 353

Fill argument
names on
method
completion(

Enable auto
activation(
)

(Auto activation delay)


Java (Auto activation
triggers for Java) Javadoc
(Auto activation triggers for Javadoc)

Auto activation
delay(
)

Auto activation
triggers for
Java(
Java )

500

Java '.'
Javadoc

Auto activation Javadoc '@'


triggers for

Javadoc(
Javadoc )
Code assist

Eclipse .doc

UI

171 353

color
options(

Completion proposal background(


)

Completion proposal foreground(


)

Method parameter background(


)

Method parameter foreground(


)

Completion overwrite background(


)

Completion overwrite foreground(


)

(Annotations)

Analyze

annotations
Java
while typing(
Eclipse .doc

172 353

)
Indicate

annotations
Java
solvable with

Quick Fix in
vertical ruler(

)
Annotation

presentation(
)

(Templates)

New...(...)

Edit...(...)

Remove()

Eclipse .doc

173 353

Import...(...)
Export...(...)
Export All...(
...)

Enable All(
)

Disable All(
)
Use Code
Formatter(

(Code Formatter)

(Template dialog)

Name()

Context(
)

Eclipse .doc

JavaJava

174 353

JavadocJavadoc

Description(
)

Pattern()

Insert
Variables...(
...)

(Template variables)
Java Javadoc

${cursor}

${date}

${dollar}

'$'
'$$'

${enclosing_m
ethod}
${enclosing_m
ethod_argume log
nts}
${enclosing_pa
Eclipse .doc

175 353

ckage}
${enclosing_pr
oject}
${enclosing_ty
pe}
${file}

${return_type}
${time}

${user}

Java

${array}

${array_eleme
nt}
${array_type}

${collection}

java.util.Collection

${index}

${iterator}

Eclipse .doc

176 353

3.6.7 JRE (JRE installations)

Add...(...)

JRE

JRE VM

JRE JRE

JRE JRE

Javadoc URL URL


Javadoc
Javadoc JRE

JRE

Eclipse .doc

JAR classes.zip
source.zip

177 353

Browse

Edit...(...)

JRE

Remove()

JRE

Search...(...) JRE
JRE

3.6.8 JUnit

Show the JUnit


results view
JUnit
only when an
error or failure
occurs (

JUnit
)

Stack trace

filter

patterns(

Eclipse .doc

178 353

3.6.9 (New project)

Source and

output
folder(
)

(Source folder name)


(Output location name)

Source folder

name(
)

'src'

Output

location
name(
)

'bin'

As JRE library
use( JRE
)

JRE

JRE
JRE
JRE
JRE_LIB
JRE_LIB JRE

Eclipse .doc

179 353

3.6.10 (Organize imports)

import

Import order
Java java
list() javax

org
com
New...(...)

n/a

Edit...(...)

n/a

Up()

n/a

Down()

n/a

Remove()

n/a

Load...(...)

n/a

Save...(...)

n/a

Number of
<package>.* 99
imports needed import
before .* is
used(.*
)
Eclipse .doc

180 353

Do not create

imports for
types starting
with a lower
case letter(

3.6.11(Refactoring preferences)

WindowPreferencesJavaRefactoring

Confirm the
execution of the
refactoring if(


Finish

Eclipse .doc

181 353

Save all

modified

resources

automatically
prior to
refactoring(

3.6.12 (Task Tags)

Java

New...(
...)

Remove
()

Edit...(
...)

TODO Normal
Eclipse .doc

182 353

3.7 (Team)

Use

compressed

folders as

default
Synchronize
view layout(

)
Show all

synchronizatio
n information
in a resource's
text label(

)
Switch to the
associated
perspective
when a
synchronize
operation
Eclipse .doc

Always()

183 353

completes(

Never()
Prompt()

Perspective

Switching(

3.7.1 CVS

CVS CVS
CVS (General CVS Preferences)

Prune empty
directories(
)

CVS

Consider file
contents in
comparison(

CVS

CVS

Delete

Eclipse .doc

184 353

unmanaged
CVS
resources on
replace(

)
Treat all new
files as

binary(

)
Validate server CVS
version

compatibility
on first

connection(

)
Confirm move
tag on tag

operation(

)
Display
CVS
detailed

protocol
output to
stdout(

)
Convert text
Eclipse .doc


185 353

files to use
Windows
platform line *nix
neding(

)
Show revision
comparisons in
dialog(
)
Communicatio 60
n timeout( CVS
)
Quietness
CVS
level() (Somewhat quiet)

(Very quiet)

(Very quiet) CVS

(Somewhat
quiet)
Default

keyword

-kkv
substitution(
ASCII
)
Save dirty
editors before
CVS
operations(
CVS

Eclipse .doc

CVS

Never() CVS

186 353

Prompt()

Auto-save() CVS

(Console preferences)

Console text
CVS
color

settings(

)

Show CVS
CVS
output in

Console

view(
CVS
)

Ext (Ext Connection Method


Eclipse .doc

187 353

preferences)
Use external
program vs.
Use internal
connection
method(

ext

extssh
CVS

CVS_RSH(CVS_ CVS ssh


RSH)
RSH

CVS_RSH CVS_SERVER
Parameters( CVS_RSH {host} -l
)
{host} -l
{user}
{user}
{host}{user}{password} {port}

CVS_SERVER(C CVS cvs


VS_SERVER)
CVS

Connection

type() ext

(Label Decorations preferences)


Text() CVS

Icons()
CVS

Eclipse .doc

188 353

General
()

(Compute deep outgoing state for


folders)

(Password Management)

SSH2 (SSH2 Connection Method)


General() ssh

Proxy

HTTP SOCKS5 Proxy

Key

Management
()

/(Watch/Edit preferences)
Configure
projects to
use
Watch/edit
on

Eclipse .doc

189 353

checkout(

/)
When read- cvs
only files

are modified
in an
cvs (Send a cvs
editor(

edit notification to the server)


)
cvs

(Edit the file


without informing the server)

Before a

CVS edit
CVS
notification (Send a cvs edit notification to the
is sent to
server)
the
server( Always Prompt()
CVS

)
Only prompt if there are other
editors()

Eclipse .doc

190 353

Never Prompt()

3.7.2 (Ignored Resources)

TeamIgnored Resources

"*" "?" "*"


"?" "*~"
"~"

Add
*.class

Remove
Eclipse .doc

191 353

3.7.3 (File Content)

TeamFile
ASCII
CVS
ASCII CVS
OS

htmlgif

Add

Change
Remove
Eclipse .doc

192 353

Eclipse .doc

193 353

4. Java

Eclipse Eclipse
( EJB C/C++)

Java Project Java

Plug-in Project plug-in

Sample Project

4.1

4.1

Eclipse .doc

194 353

4.1 Java

Java
I. FileNewProject
(Package Explorer
NewProject)
( New Java Project

II. New Project ( 4.1) Java Project


( Java Java Project 4.2)

4.2

Eclipse .doc

195 353

III. New Java Project Project 4.3

III

IV

4.3

IV. Project Layout


4.3
V. Finish

Eclipse .doc

196 353

4.2 Java

Java
I. FileNewClass
(Package Explorer
NewClass)
( New Java Class

II. New Java Class Source Folder

III. Package
IV. Name Class Name
V. Which method would you like te creat
public static void main(String[] args) generate
main method
VI. Finish Java

Eclipse .doc

197 353

II

III
IV

VI

4.4

Package Explorer

Navigator

Eclipse .doc

198 353

4.3

4.3.1 Code Completion

Eclipse ()
()

4.3.2 Code Assist

System.out.println
Eclipse
Javadoc
Enter

4.5

Eclipse .doc

199 353

Alt - /

4.6

Alt - /
for
Alt - /

Eclipse .doc

200 353

4.7

4.4 Java

(Launch Configuration)
()

I. RunRun asJava Application


II. Eclipse
Eclipse .doc

201 353

III. Tasks Consol

Java Runtim...

I. RunRun Run

Main

main Stop in main

JRE

(Arguments)

JRE JRE
JRE JRE JRE

(Classpath)
bootstrap

Eclipse .doc

202 353

(Source) Java

(Environment) Java

Eclipse

(Common)

4.8

Eclipse .doc

203 353

II. Arguments

4.9

Eclipse .doc

204 353

4.10

4.5 Java (Java

Scrapbook Page)

debugEclipse
Java (Java Scrapbook Page)
Java

I. Java
II.FileNewOther...JavaScrapbook Page
(
New Other... Java Scrapbook Page)

Eclipse .doc

205 353

4.11

III.
IV.
IV. Finish

Eclipse .doc

206 353

III

IV

4.12

Package ExplorerNavigator
JackyTest.jpage

Eclipse .doc

207 353

4.13

Java
for (int i = 0; i < 5; i++) {
System.out.println(Integer.toString(i));
}

I.
II. Execute
III. Consol

Eclipse .doc

208 353

4.14

I. Set Import...

Eclipse .doc

209 353

4.15

II. Java Snippet Imports Add Packages

Eclipse .doc

210 353

4.16

III. Add Packages as Imports import


package

Eclipse .doc

211 353

4.17

IV. OK

4.6

4.6.1

WindowPreferencesJavaCode
Style Code Formatter

Eclipse .doc

212 353

4.18

Show Show Profile


Java Code Style

Eclipse .doc

213 353

4.19

Export Java
Code Style Import

4.6.2

Java API

System.out.println()
I.
Eclipse .doc

214 353

WindowPreferencesJavaEditorTemplat
es

4.20

II. Preferences New

Eclipse .doc

215 353

IV

III
V
VI

VI

4.21

III. Name
IV. Context java
V. Description
VI. Pattern System.out.println("")
Insert Variable
cursor
VII. OK
${cursor}

s( sop) Alt - / sop


Enter

Eclipse .doc

216 353

4.22

4.6.3 Javadoc

To change the template for


this generated... Javadoc
I. WindowPreferencesJavaCode
Style Code Templates
II. CodeNew Java files Edit

Eclipse .doc

217 353

4.23

III.

Eclipse .doc

218 353

4.24

IV. OK
New Java file -
(Typecomment)
I. WindowPreferencesJavaCode
Style Code Templates
II. CommentsTypes Edit

4.25

III.

Eclipse .doc

219 353

4.26

IV. OK

Eclipse .doc

220 353

4.27

Javadoc 4.6.2
Context javadoc

Eclipse .doc

221 353

4.28

eic Alt - /

4.29

4.7 getter setter

Java
(accessors getter setter method)
I. SourceGenerate Getter and Setter...
Eclipse .doc

222 353

( Java SourceGenerate Getter and


Setter...)

II

III
IV
V
VI

4.30

II. getter setter method


III. method
IV.
V. Access modifier
VI.
VII. OK

Eclipse .doc

223 353

4.31

4.8 JAR

4.8.1 JAR

JAR
I. Package Explorer
Eclipse .doc

224 353

Java IV JAR Package


Specification
II. File Export
III. JAR file Next

4.32

IV. JAR Package Specification Select the


resources to export
V. Export generated class files
and resourcess Export java source files and
resources
VI. Select the export destination
Eclipse .doc

225 353

Browse JAR
VII. Compress the contents of the JAR file
VIII. Overwrite existing files without warning

IX. JAR JAR Manifest

X.

Finish JAR
NextJAR
JAR manifest

Eclipse .doc

226 353

IV

VI

VII
VIII

4.33

4.8.2

I. JAR
NextJAR
II. JAR Save the description of
this JAR in the workspace
Eclipse .doc

227 353

III. CLASS
CLASS

IV. CLASS

V. Create source
folder structure
VI. JAR
Build projects if not built automatically
VII. Finish JAR
manifest Next

Eclipse .doc

228 353

III
IV
V
VI
II

4.34

4.8.3 JAR manifest

JAR Manifest
Manifest
Manifest
I. JAR
NextJAR
II. NextJAR
Eclipse .doc

229 353

manifest
III. Generate the manifest file
IV. Manifest
Manifest Save the manifest in the
workspace Manifest file Browse
Manifest
V. Manifest
JAR JAR
Manifest Reuse and save the manifest in
the workspace JAR JAR
Manifest
JAR
VI. JAR

VII. Main Class Browse

VIII. Finish JAR JAR


Manifest
Eclipse .doc

230 353

4.35

manifest
Manifest
I. JAR
NextJAR
II. NextJAR
manifest
Eclipse .doc

231 353

III. Use existing manifest from workspace


IV. Browse Manifest
V. Finish JAR JAR

4.36

Eclipse .doc

232 353

4.8.4 JAR

JAR JAR
Create JAR JAR

Eclipse .doc

233 353

4.37

Eclipse .doc

234 353

4.9. Javadoc

Javadoc

FileExport...

Javadoc

4.9.1 Javadoc

I. Javadoc
II. Javadoc
III. Javadoc
IV. doclet
( doclet)
V. Javadoc

Eclipse .doc

235 353

II

III

IV

4.38

4.9.2 doclet Javadoc

I.
II. Javadoc
Eclipse .doc

236 353

III. Javadoc

Javadoc
IV. CSS
V. Javadoc
Javadoc

II

III

IV
V

Eclipse .doc

237 353

4.39

4.9.3 Javadoc

I.
II. Javadoc

III. Javadoc Ant Script


IV. Ant Script
V. Javadoc
Javadoc
Console

Eclipse .doc

238 353

I
II

III
IV

4.40

4.10 (Working Sets)

Navigate

Tasks
Eclipse .doc

239 353

Navigate

4.10.1

I.

II. Select Working Set Select Working Set

Eclipse .doc

240 353

III. Java Next

VI. New Working Set


Finish

Eclipse .doc

241 353

4.10.2

I.

Eclipse .doc

242 353

II.

Select Working Set Select Working Set

III.

Eclipse .doc

243 353

4.10.3

I.

II. Deselect Working Set

Eclipse .doc

244 353

5.

Hot Code
Replacement()
IDE

5.1

(n! = n * (n-1) * (n-2) *... * 1)


(stack frame)

public class ErrorTest {


public static void main(String[] args) {
System.out.println(factorial(6));
}

Eclipse .doc

245 353

public static int factorial(int value) {


if (value == 0) {
return value;
} else {
return value * factorial(value - 1);
}
}
}

factorial(n)
6 720
0

Eclipse .doc

246 353

5.1

5.2 (Breakpoints)

(Breakpoints)
Marker Bar(Run
Toggle Line Breakpoint)
Eclipse .doc

247 353


return value * factorial(value - 1)
factorial()
Marker Bar
RunDebug AsJava Application(

Debug AsJava Application)

Debug

5.2

Eclipse .doc

248 353


Debug
DebugDebug

factorial() mail()Debug

Suspend ()
Disconnet

Resume ()
Terminate ()

Remove All Terminated Launches (

debug session)
Debug
Variables

BreakpointsExpressions

5.3

Variables
Eclipse .doc

249 353

()
Eclipse (
) Variables(Detail
Pane)
Breakpoints
Enable
Disable
Remove
Remove All

5.4

Expressions()
Inspect
Expressions

Eclipse .doc

250 353

5.5

Display Display
DebugJava
Debug

Eclipse .doc

251 353

5.6

5.3

(singlesteping)Eclipse

Eclipse .doc

252 353

5.3.1 Step Into

( F5)

5.3.2 Step Over

( F6)

5.3.3 Step Return

( F7)
return

5.3.4 Drop to Frame

Eclipse .doc

253 353

Drop
to Frame

Static

VM

5.3.5 Use Step Filters/Step Debug

( Shift - F5)

overintoreturn

Window Preferences Java DebugStep


Filtering

Eclipse .doc

254 353

5.7

debug session return value *


factorial(value - 1) F5
factorial(value - 1)value
5

Eclipse .doc

255 353

5.8

5.4

factorial()
Debug
Eclipse .doc

256 353

Resume

Watch
Expressions

5.9

Resume
value 5 factorial()
Resume value

Eclipse .doc

257 353

5.10

5.5 Hit Count

factorial() 6 6 Resume
Hit Count 2
Breakpoints
Properties
Eclipse .doc

258 353

5.11

Breakpoints Properties Hit Count


6

Eclipse .doc

259 353

5.12

( Hit Count

Eclipse .doc

260 353

5.13

Set Breakpoint Hit Count 6

5.14)

debug session 6
value 1Debug
Eclipse .doc

261 353

factorial()

5.15

Debug
(active frame)
value = 1
value = 2

Eclipse .doc

262 353

5.16

Step Into
factorial()Expressions
value 0Value 0

Eclipse .doc

263 353

5.17

factorial() value = 1
0

Eclipse .doc

264 353

5.18

5.6

Hit Count
Breakpoints
Properties

Eclipse .doc

265 353

5.19

Breakpoints Properties Enable Condition

Suspend when

condition istrue()

value of condition changes()

Suspend Policy

Suspend Thread Thread


Thread

Eclipse .doc

266 353

Suspend VM

5.20

value == 0

Eclipse .doc

267 353

5.7 (Watchpoint)

Line Breakpoint Line


Breakpoint (Watchpoint)
(Method Breakpoint)(Exception Breakpoint)

Java
RunToggle Watchpoint

Eclipse .doc

268 353

5.21

Marker Bar
DebugBreakpoints
Properties

Eclipse .doc

269 353

5.22

Breakpoints Properties
Suspend on

Field Access

Field Modification

Eclipse .doc

270 353

5.23

5.8 (Method Breakpoint)

(Method Breakpoint)

Java
RunToggle Method Breakpoint

Eclipse .doc

271 353

5.24

Marker Bar
DebugBreakpoints
Properties

Eclipse .doc

272 353

5.25

Breakpoints Properties
Suspend on

Method Entry

Method Exit

Eclipse .doc

273 353

5.26

5.9 (Exception Breakpoint)

Null ()
Eclipse .doc

274 353

JavaRunAdd
Java Exception Breakpoint
DebugBreakpoints
Properties

5.27

Breakpoints Properties
Suspend on
Eclipse .doc

275 353

Caught Exception

Uncaught Exception

5.28

5.10 Java

Expressions
Inspect
6 value +
1 Inspect
Eclipse .doc

276 353

5.29

value + 1 Expressions

Eclipse .doc

277 353

5.30

Variables
Set Value
value 5

5.31

Eclipse .doc

278 353

Eclipse .doc

279 353

6.(Refactoring)

Java
Eclipse
Martin Fowler Refactoring:
Improving the Design of Existing Code, Addison Wesley
1999

Java

Java

Eclipse .doc

280 353

6.1

6.1.1 (Local Variable)

I. Java
II. RefactorRename
(RefactorRename)
Rename Local Variable

III
IV
V

6.1

III. Name
IV.
Eclipse .doc

281 353


V. OK Preview

VI.
VII.

VI

VII

6.2

Eclipse .doc

282 353

6.1.2 (Field)

I. Java
II. RefactorRename
(RefactorRename)
Rename Field
III
IV
V
VI

VII

6.3

III. Name
IV.

V.

Eclipse .doc

283 353

VI. (getter/setter)

Getter Getter

Setter Setter

VII. OK Preview

VIII.
IX.

Eclipse .doc

284 353

VIII

IX

6.4

6.1.3 (Method)

I. Java
II. RefactorRename
(RefactorRename)
Eclipse .doc

285 353

Rename Method

III
IV
V

6.5

III. Name
IV.

V. OK Preview

Eclipse .doc

286 353

VI

VII

6.6

VI.
VII.

6.1.4 (Class)(Interface)

I. Java
Eclipse .doc

287 353

II. RefactorRename
(RefactorRename)
Rename Type
III
IV
V
VI

VII

6.7

III. Name
IV.

V.

VI. Javadoc

VII.

Eclipse .doc

288 353

VIII

IX

6.8

VIII.
IX.

6.1.5 (Package)

I. Java
II. RefactorRename
Eclipse .doc

289 353

(RefactorRename)
Rename Package
III
IV
V
VI

VII

6.9

III. Name
IV.

V.

VI. Javadoc

VII.

Eclipse .doc

290 353

VIII

6.10

VIII.

6.2 (Extracting)

6.2.1 (Extracting a Constant)

I. Java
II. RefactorExtract Constant...
(RefactorExtract
Eclipse .doc

291 353

Constant...)

6.11

Extract Constan
III
IV
V
VI
VII
VIII
IX

6.12

III. Name
IV.
Eclipse .doc

292 353

publicdefaultprotected private
V.

VI.

Qualify constant reference with class name

6.13

Qualify constant reference with class name

6.14

VII.
VIII.
Java

Eclipse .doc

293 353

6.15

IX.

XI

Eclipse .doc

294 353

6.16

X.
XI.

public class Extracting {


static int jackyInt = 10;

public static void main(String[] args) {


System.out.println("This's Extracting class.");
System.out.println(jackyInt);
}
}

6.2.2 (Extracting a Local Variable)

I. Java
II. RefactorExtract Local Variable...
Eclipse .doc

295 353

(RefactorExtract Local
Variable...)

6.17

Extract Local Variable


III
IV
V
VI
VII

6.18

III. Name
Eclipse .doc

296 353

IV.

V. 'final'
VI.
Java

6.19

VII.

Eclipse .doc

297 353

VIII

IX

6.20

VIII.
IX.

public class Extracting {


static int jackyInt = 10;
String jackyString = "jacky";

Eclipse .doc

298 353

public static void main(String[] args) {


System.out.println("This's Extracting class.");
System.out.println(jackyInt);
}

public void jackyMethod() {


System.out.println(jackyString);
}
}

6.2.3 (Extracting a Method)

I. Java
II. RefactorExtract Method...
(RefactorExtract Method...)

Eclipse .doc

299 353

6.21

Extract Methode
III
IV

VI
VII
VIII
IX

Eclipse .doc

300 353

6.22

III. Name
IV.
public default protected private
V.

6.23

Eclipse .doc

301 353

6.24

VI.

VII. Javadoc
VIII.
IX.
Java

Eclipse .doc

302 353

6.25

X.

Eclipse .doc

303 353

XI

XII

6.26

XI.
XII.

public class Extracting {


static int jackyInt = 10;

String jackyString = "jacky";


Eclipse .doc

304 353

public static void main(String[] args) {


System.out.println("This's Extracting class.");
System.out.println(jackyInt);
}

public void jackyMethod(String str1, int int1) {


if (str1 != null) {
if (int1 > 0) {

}
}
}
}

6.3 (Inlining)

Eclipse .doc

305 353

public class Inlining {


static final int jackyInt = 10;

public static void main(String[] args) {


System.out.println("This's Inlining class.");
System.out.println(jackyInt);
}

public void jackyMethod() {


jackyMethod("jacky", 5);
}

public void jackyMethod(String str1, int int1) {


String jackyString = "Jacky";
if (jackyString != null) {
System.out.println(jackyString);
}
}
}
Eclipse .doc

306 353

6.3.1 (Inlining a Constant)

I. Java
II. RefactorExtract Inlining...
(RefactorExtract Inlining...)

6.27

Inline Constant

Eclipse .doc

307 353

6.28

Delete constant declaration

6.29

Delete constant declaration

6.30

Eclipse .doc

308 353

6.31

6.3.2 (Inlining a Local Variable)

I. Java
II. RefactorExtract Inlining...
(RefactorExtract Inlining...)

Eclipse .doc

309 353

6.32

Inline Local Variable

6.33

Eclipse .doc

310 353

6.34

6.3.3 (Inlining a Method)

I. Java
II. RefactorExtract Inlining...
(RefactorExtract Inlining...)

Eclipse .doc

311 353

6.35

Inline Constant

6.36

Delete method declaration

Eclipse .doc

312 353

6.37

Delete method declaration

6.38

Eclipse .doc

313 353

6.39

6.4 (Signature)

I. Java
II. RefactorChange Method Signature...
Eclipse .doc

314 353

(RefactorChange Method
Signature...)

6.40

Inline Constant

Eclipse .doc

315 353

IV
III

VI
VII

VIII
IX
X

6.41

III. Access modifier


IV. Return type
V. Method Name
VI. Parameters

Eclipse .doc

316 353

6.42

VII. Exceptions
Exception

6.43
Eclipse .doc

317 353

VIII.
IX.
X.

XI

XII

6.44

XI.
XII.

Eclipse .doc

318 353

6.5 Java (Moving Java

Elements)

public class Moving {


static int jackyInt;
String jackyString = "Jacky";

public static void main(String[] args) {


System.out.println("This's Moving class.");
System.out.println(jackyInt);
}

public void jackyMethod() {


System.out.println(jackyString);
}
Eclipse .doc

319 353

6.5.1 (Field)

I. Java
II. RefactorChange Move...
(RefactorMove...)

6.45

Textual Move

Eclipse .doc

320 353

6.46

III.

6.5.2 Static Members

Static Members
I. Java Static Members
II. RefactorChange Move...
(RefactorMove...)

Eclipse .doc

321 353

6.47

Move Static Members

6.48

III. Choose Type

Eclipse .doc

322 353

6.49

IV.
V.

Eclipse .doc

323 353

6.50

6.6 (Self Encapsulating a

Field)

Eclipse .doc

324 353

I. Java
II. RefactorEncapsulate Field...
(RefactorEncapsulate Field...)

6.51

Encapsulate Field
III
IV
V
VI
VII
VIII
IX

Eclipse .doc

325 353

6.52

III. Getter Getter


IV. Setter Setter
V. Getter
Setter
VI.
VII.
Getter Setter

Getter
Setter Getter Setter

VIII. Javadoc
IX.

Eclipse .doc

326 353

XI

6.53

X.
XI.

Eclipse .doc

327 353

7.(Tips and Tricks)

7.1 (Editing Source)

(Parameter
Hints)

Java
Ctrl+Shift+
Edit Parameter Hints

(Suppress
types in
code assist)

Java Type Filters

Package ExplorerType
Hierarchy

Getter Setter
Getter Alt+/
Eclipse .doc

328 353

Setter(Use
content
assist to
create
Getter and
Setters)

Getter Setter Stub

Getters

Setter(Delet
e Getters
and Setters
together
with a field)

Eclipse Getter
Setter
Code Style
Window PreferencesJavaCode Style


(Create
SourceGenerate Delegate Methods
Delegate

Methods)


(Use WindowPreferencesJavaEditorTempl
Templates to ates Stub(Alt+/)
create a

method)

'private_method''public_method''protected_method

Eclipse .doc

329 353

'
Tab

(Alt+/)

(Use Quick
Fix to create
a new
method)

'implements'
Java
(Use
Quick Fix to Ctrl+1EditQuick Fix
change a
abstract
method
signature)

Eclipse .doc

330 353

Stub(Use
Content
Assist to
create a
constructor
stub)

(Alt + /)

(Use Content
Assist to
override a
method)


(Create (Ctrl+1)
new fields
Eclipse
from
parameters)

(Rename Java
in File)

Ctrl+1EditQuick Fix

Eclipse .doc

331 353



(Less
work with

cast
expressions)

(Surround
Lines)

if/while/for
Ctrl+1EditQuick Fix
${line_selection}


(Remove Ctrl+1EditQuick Fix
Surrounding
Statement)

(Find the
Matching
Bracket)

Ctrl+Shift+PNavigateGo ToMatching
Bracket

(Sort

Eclipse .doc

332 353


Members)

WindowPreferencesJavaAppearanceMe
mbers Sort Order Java

SourceSort Members

Java
(Find
Unused
WindowPreferencesJava Compiler
Code)

Javadoc Java Javadoc doc


(Javadoc
Comment WindowPreferencesJava CompilerJavadoc
Handling)
ProjectPropertiesJava
CompilerJavadoc

Eclipse .doc

333 353

Javadoc Java
EditQuick Fix(Ctrl+1)

7.2 (Searching)

(Locate
variables and
their
read/write
Eclipse .doc

ID
SearchOccurrences in File

334 353

access)

SearchReferences

(Search for
methods with
a specific
return type)

"*<return type>"

Java Search

Search string '*'

Case sensitive

Method Declarations
Search

Eclipse .doc

335 353

Java Java Java Javadoc


Javadoc
Javadoc
(Remove

Javadoc resultsWindowPreferencesJavaCompiler
from Java
Javadoc Process Javadoc comments
search)

(Trace method
call chains withNavigateOpen Call Hierarchy(Ctrl+Alt+H)
the Call

Hierarchy)

Eclipse .doc

336 353

7.3 (Code

navigation and reading)

Java Java

F3NavigateOpen
(Open on a
selection in
the Java
editor)

(Inplace
outlines)

Declaration

Ctrl

Java Ctrl+F3
Ctrl+ONavigateQuick
Outline

Ctrl+O Ctrl+F3
(In-
Eclipse .doc

337 353

place outlines
show
inherited
members)

(Inplace
hierarchy)

Quick Hierarchy
Ctrl+TNavigateQuick
Outline

Ctrl+TSupertype hierarchy

(Mark
(Alt+Shift+O)
Occurrences)

/
(Go to Ctrl+Shift+NavigateGo ToPrevious
next /
Member Ctrl+Shift+NavigateGo
previous
ToNext Member
method)
Eclipse .doc

338 353

Java ShiftCtrlAlt Java

(Hovers in the
Java editor) Java

Javadoc Ctrl

WindowPreferencesJavaEditorHovers

Shift+F2NavigateOpen External
Javadoc Javadoc Javadoc
(Open and
JAR
configure

external

Javadoc
documentatio
Project PropertiesJava Build Path
n)
'Javadoc '

Web

Eclipse .doc

339 353

Project PropertiesJavadoc Location


( )

Java
Show Source jackyMethod()
of Selected
Element
Only)

Java

Eclipse .doc

340 353

7.4 Java (Java views)

(Declaration
view)

WindowShow
ViewOther...JavaDeclaration Java
Java

Javadoc Javadoc WindowShow


(Javadoc
ViewOther...JavaJavadoc Java
Eclipse .doc

341 353


view)

Java JavadocJavadoc SWT


HTML


(Tricks in
the type
hierarchy)

F4NavigateOpen Type
Hierarchy
Hierarchy
JAR Java

Hierarchy

Hierarchy



(Find out
where a
F4NavigateOpen
method is
Type Hierarchy
implemented
in the
hierarchy)
Eclipse .doc

342 353

Lock View and


Show Members in Hierarchy

''
'isEmpty()''List'
'ArrayList''Vector''AbstractList'


(Compress

package
WindowPreferencesJavaAppearance
names)

Eclipse .doc

343 353

7.5 (Debugging)

Java
(Environment
Variables)

VM VM JRE
(Default VM VM
Arguments)

Eclipse .doc

344 353

Pin
(Controlling
your console)


(Threads
and Monitors
view)

Eclipse .doc

345 353

(Step filters)
Window PreferencesJavaDebugStep
Filtering

Filter Type Filter


Package

(Running

code with
JavaDebug'Suspend
compile
errors)
execution on compilation errors'

VM Hot Code Replace

'unresolved compilation'

Java
(Stack trace
hyperlinks)
Java

Eclipse .doc

346 353

7.6 (Various)

JUnit

JUnit
Run JUnit TestRunRun
AsJUnit Test

JUnit JUnit

(Hide JUnit view
until errors or
failures occur)

JUnit JavaJUnit

(Alt+/) Java
(Content
assist in dialog
Eclipse .doc

347 353

fields)

New Java Class New Java


InterfaceNew JUnit Test
Static
Extract Local Variable
Convert Local Variable to
FieldIntroduce Parameter

Eclipse .doc

348 353


Java

(Structural
compare of
Java source)

Java Java

Java

Java (compilation units)


Compare WithEach Other
Compare Editor
Java

CVS
Java

Eclipse .doc

349 353

Compare EditorCVS
Synchronization
(Ignore Whitespace)

Java .properties
(Structural

compare of

property files)

Package ExplorerNavigator
Compare WithEach
Other Compare Editor

CVS

Eclipse .doc

350 353

Static

(Define
JavaCode Style
prefixes or

suffixes for
fields,
parameters and
local variables)


(Use
Java
project specific ProjectPropertiesJava Compiler
compiler
settings)

Eclipse .doc

351 353

JREPreferences
JRE(Use a
JavaInstalled JRE's JRE
specific JRE for JREJava Build Path
a project)
ProjectPropertiesJava Build Path
LibrariesEdit
Library JRE
JRE

JDT
(Recovering

from abnormal
Java Search Open Type
inconsistencies)

Eclipse .doc

352 353

1.
2.

Eclipse

3.
4.

Project

Eclipse .doc

Clean...

353 353

You might also like