eclipse

Fixing Eclipse 'Organize Imports' Annoyance For Static Imports

posted Jun 20, 2010, 7:24 PM by Kuwon Kang

Trustin Lee
Seongnam, Kyunggi, South Korea  

Static import 문에 대한 이클립스의 'Organize Import' 문제 해결하기

CTRL+SHIFT+O is probably the most pressed shortcut in Eclipse JDT. It cleans up any unused imports, expands ugly asterisks, and reorganizes the import statements in order. It was very nice until asterisks were considered ugly. Since static imports are introduced in Java 5, things have been changed dramatically. Who will ever want his or her static import statement with an asterisk to be expanded? Unfortunately, Eclipse JDT gets rid of the asterisks in static imports mercilessly.

CTRL+SHIFT+O는 아마도 이클립스 JDT에서 가장 많이 눌리는 단축키일 것입니다. 이 단축키를 누르면 더이상 쓰이지 않는 import 문은 사라지고, 보기 흉한 별표 import 문은 전개되고, import문은 순서에 맞게 재정렬됩니다. 별표 import 문이 보기 흉하다고 생각될 때까지는 참 좋았지요. Static import 문이 Java 5에 등장한 이후로 상황이 완전히 바뀌었습니다. 누가 별표 static import 문이 전개되길 상상이나 했겠어요? 안타깝게도 이클립스 JDT는 무자비하게 static import 문의 별표까지 없애버립니다.

What is fortunate though is that there's an option that changes this default behavior.

그나마 다행스러운 것은 이 디폴트 값을 바꾸는 옵션이 있다는 겁니다.

  1. Choose 'Window -> Preferences...' menu.
  2. Choose 'Java -> Code Style -> Organize Imports' in the left pane.
  3. Set the 'Number of static imports needed for .*' to '1' in the right pane.
  4. Click 'OK' button.
  1. 'Window -> Preferences...' 메뉴를 선택합니다.
  2. 왼쪽에서 'Java -> Code Style -> Organize Imports'를 선택합니다.
  3. 오른쪽에서 'Number of static imports needed for .*'를 '1'로 설정합니다.
  4. 'OK' 버튼을 누릅니다.

EclEmma 1.3.1

posted Jun 20, 2010, 7:24 PM by Kuwon Kang

예전에 마소에서 읽었던 EclEmma툴이다.

코드 커버리지를 측정하고 분석한다.

 프로젝트, 폴더, 패키지 단위로 지정가능하다.

 코드 커버리지에 대한 정보가 매우 유용하다.

아직 Clover를 사용해보지 못했지만 많은 사람들이 나름 훌륭하다고 하니

복잡하거나 코드량이 많은 모듈에서 테스트는 필수가 되겠다.

  • Local Java application
  • Eclipse/RCP application
  • JUnit test
  • JUnit plug-in test
  • TestNG test
  • Equinox OSGi framework

모두 Code coverage가 가능하니 좋다.ㅋㅋ

짬을 내어 Refactoring을 하다가 가끔은 사용하지 않는 코드를 찾아 지우고 수정하는 일도 매우 중요한듯 한다.

Chapter 3. Adding Context Menus to Other Views

posted Jun 20, 2010, 7:23 PM by Kuwon Kang

Eclipse에 자신의 플러그인 메뉴을 추가하는 기능이다.

 이 기능은 참으로 간단한 것이지만 매우 막강하기도 한 것 같다.

요즘 나만의 플러그린을 만들고 있는데 참으로 기발한 것 같다.

감사하다. 이클립스..

<a href="http://docs.jboss.org/jbosside/cookbook/build/en/html/Example2.html">http://docs.jboss.org/jbosside/cookbook/build/en/html/Example2.html</a>

Class elements

posted Jun 20, 2010, 7:22 PM by Kuwon Kang

Other elements correspond to the items that make up a Java compilation unit. The figure below shows a Java compilation unit and a content outliner that displays the source elements in the compilation unit.An editor and a content outliner illustrating the relation between corresponding source elements

Eclipse Ganymede SVN Connector Installation

posted Jun 20, 2010, 7:22 PM by Kuwon Kang

Eclispe Ganymede설치 프로그램.

3.4부터는 Subversive와 Connector를 별도로 설치한다.

JAVAHL버전과 SNVKit모두 설치 가능하다.

http://www.polarion.org/projects/subversive/download/eclipse/2.0/update-site/

선택적 사용은 Preference->Team->SVN->SVN Connector를 선택하여 사용할 수 있다.

Eclipse Plugin - Open Window Explorer

posted Jun 20, 2010, 7:21 PM by Kuwon Kang   [ updated Jun 20, 2010, 7:21 PM ]

하나 만들까 하다가 찾아보니 역시 있군요.

Eclipse에서 Window Explorer직접 열지 못해 Alt Enter로 Path복사해서 Window Explorer에 붙여서 사용했는데
늘 불만 이었다.

Cmd도 되고.ㅋㅋ

http://startexplorer.sourceforge.net/update

1-6 of 6