IntelliJ IDEA and eclipse mapping manBypanshuai

Intellij IDEA and eclipse mapping manual made by shuai.pan

migrating from eclipse to Intellij IDEA

Overview

Switching from Eclipse to IntelliJ IDEA, especially if you’ve been using Eclipse for a long time, requires understanding some fundamental differences between the two IDEs, including their user interfaces, compilation methods, shortcuts, project configuration and other aspects.

No workspace

The first thing you’ll notice when launching IntelliJ IDEA is that it has no workspace concept. This means that you can work with only one project at a time. While in Eclipse you normally have a set of projects that may depend on each other, in IntelliJ IDEA you have a single project that consists of a set of modules.
If you have several unrelated projects, you can open them in separate windows.
If you still want to have several unrelated projects opened in one window, as a workaround you can configure them all in IntelliJ IDEA as modules.

Intellij idea vs eclipse terminology

EclipseIntelliJ IDEA
WorkspaceProject
ProjectModule
FacetFacet
LibraryLibrary
JRESDK
Classpath variablePath variable

Templates

TemplateEclipseIntelliJ IDEA
Define a main methodmainpsvm
Iterate over an arrayforitar
Iterate over a collectionforitco
Iterate over a listforitli
Iterate over an iterable using foreach syntaxforeachiter
Print to System.outsysoutsout
Print to System.errsyserrserr
Define a static fieldstatic_finalpsf

Shortcuts between eclipse and Intellij IDEA

Eclipse ActionEclipse ShortcutIntelliJ IDEA ActionIntelliJ IDEA Shortcut
Code completionCtrl+SpaceBasic completionCtrl+Space
--Smart completionCtrl+Shift+Space
--Statement completionCtrl+Shift+Enter
Quick accessCtrl+3Search everywhereShift x 2
Maximize active view or editorCtrl+MHide all tool windowsCtrl+Shift+F12
Open typeCtrl+Shift+TNavigate to classCtrl+N
Open resourceCtrl+Shift+RNavigate to fileCtrl+Shift+N
--Navigate to symbolCtrl+Shift+Alt+N
Next viewCtrl+F7--
--Recent filesCtrl+E
--SwitcherCtrl+Tab or Ctrl+Shift+Tab
Quick outlineCtrl+OFile structureCtrl+F12
Move linesAlt+Up/DownMove linesShift+Alt+Up/Shift+Alt+Down
Delete linesCtrl+DDelete linesCtrl+Y
Quick fixCtrl+1Show intention actionAlt+Enter
Quick switch editorCtrl+ESwitcherCtrl+Tab or Ctrl+Shift+Tab
--Recent filesCtrl+E
Quick hierarchyCtrl+TNavigate to type hierarchyCtrl+H
--Navigate to method hierarchyCtrl+Shift+H
--Show UML popupCtrl+Alt+U
Last edit locationCtrl+QLast edit locationCtrl+Shift+Backspace
Next editorCtrl+F6Select next tabAlt+Right
RunCtrl+Shift+F11RunShift+F10
DebugCtrl+F11DebugShift+F9
Correct indentationCtrl+IAuto-indent linesCtrl+Alt+I
FormatCtrl+Shift+FReformat codeCtrl+Alt+L
Surround withCtrl+Alt+ZSurround withCtrl+Alt+T
--Surround with live templateCtrl+Alt+J
Open declarationF3Navigate to declarationCtrl+B, Ctrl+Button1 Click or Button2 Click
--Quick definitionCtrl+Shift+I
Open type hierarchyF4Navigate to type hierarchyCtrl+H
--Show UML popupCtrl+Alt+U
References in workspaceCtrl+Shift+GFind usagesAlt+F7
--Show usagesCtrl+Alt+F7
--Find usages settingsCtrl+Shift+Alt+F7
Open search dialogCtrl+HFind in pathCtrl+Shift+F
Occurrences in fileCtrl+Alt+UHighlight usages in fileCtrl+Shift+F7
Copy linesCtrl+Alt+DownDuplicate linesCtrl+D
Extract local variableCtrl+Alt+LExtract variableCtrl+Alt+V
Assign to fieldCtrl+2/Ctrl+FExtract fieldCtrl+Alt+F
Show refactor quick menuCtrl+Alt+TRefactor thisCtrl+Shift+Alt+T
RenameCtrl+Alt+RRenameShift+F6
Go to lineCtrl+LNavigate to lineCtrl+G
Structured selectionShift+Alt+Up/Shift+Alt+DownSelect word at caretCtrl+W/Ctrl+Shift+W
Find nextCtrl+JFind nextF3 or Ctrl+L
Show inCtrl+Alt+WSelect inAlt+F1
BackCtrl+[BackCtrl+Alt+Left or Button4 Click
ForwardCtrl+]ForwardCtrl+Alt+Right or Button5 Click
  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值