[Eclipse] 자주쓰는 단축키 모음 Part. 2
Eclipse / 2008. 3. 9. 02:03
part. 1 에서 이어집니다.
※ Alt + Shift + S - Show source Quick Menu
Java source editor 에서 다음 단축 키를 누르면 다음과 같은 메뉴가 나옵니다.
Override/Implement Methods (Ctrl + Shift + S, V)
- 부모클래스나 인터페이스의 메소드의 오버라이드나 구현할 수 있는 형태를 만들어 줍니다.
Generate Getters and Setters (Ctrl + Shift + S, R)
- 많이 알고 계시는 기능입니다. vo의 getter, setter 만들어 줄 때 사용합니다.
나머지 것들은 귀찮기도 하고... 자주 사용하지 않는 거라 말로만 떼웁니다.
Generate hashCode() and equals() (Ctrl + Shift + S, H)
- hashCode() 가 머에썼던 거더라;;; 흠 여튼 두개의 메소드를 추가해줍니다.
Generate Constructor using Fields... (Ctrl + Shift + S, O)
- 클래스의 field 들을 이용하여 생성자를 추가합니다.
Generate Constructor from Superclass... (Ctrl + Shift + S, C)
- 부모클래스의 생성자 유형을 추가합니다.
Externalize Strings... (Ctrl + Shift + S, E)
- 모든 String literal 들을 properties 파일로 추출합니다. (맞나?? ㅎㅎㅎ)
※ Alt + Shift + S - Show source Quick Menu
※ Ctrl + Shift + X / Y - To Upper/Lower Case
일단은 여기까지 제가 주로 쓰는 단축키들이였습니다.
더 좋은 단축키가 있으면 추천 해주세요~~
※ Alt + Shift + S - Show source Quick Menu
Java source editor 에서 다음 단축 키를 누르면 다음과 같은 메뉴가 나옵니다.

Override/Implement Methods (Ctrl + Shift + S, V)
- 부모클래스나 인터페이스의 메소드의 오버라이드나 구현할 수 있는 형태를 만들어 줍니다.

Java Editor 에서 Ctrl + Shift + S 를 누른 후 V 를 누르면 부모 클래스의 메소드들이 나옵니다. 오버로드할 메소드를 체크~

OK 버튼을 누르면 다음과 같이 메소드들이 추가가 됩니다.
Generate Getters and Setters (Ctrl + Shift + S, R)
- 많이 알고 계시는 기능입니다. vo의 getter, setter 만들어 줄 때 사용합니다.

프로퍼티들을 추가합니다.

Ctrl + Shift + S 를 누른 후 R 키를 누르면 다음과 같은 창이 뜹니다.

추가할 메소드들을 체크하고 OK 버튼을 누르면...

다음과 같이 getter 와 setter 가 추가되었습니다.
나머지 것들은 귀찮기도 하고... 자주 사용하지 않는 거라 말로만 떼웁니다.
Generate hashCode() and equals() (Ctrl + Shift + S, H)
- hashCode() 가 머에썼던 거더라;;; 흠 여튼 두개의 메소드를 추가해줍니다.
Generate Constructor using Fields... (Ctrl + Shift + S, O)
- 클래스의 field 들을 이용하여 생성자를 추가합니다.
Generate Constructor from Superclass... (Ctrl + Shift + S, C)
- 부모클래스의 생성자 유형을 추가합니다.
Externalize Strings... (Ctrl + Shift + S, E)
- 모든 String literal 들을 properties 파일로 추출합니다. (맞나?? ㅎㅎㅎ)
※ Alt + Shift + S - Show source Quick Menu

파라미터 이름을 막 짜놓은 메소드가 있습니다.

aa 라는 것이 맘에 들지 않으므로 커서를 위치시킨 후에 Alt + Shift + R 키를 누릅니다.

새로운 String을 타이핑 하면 동시에 변경이 됩니다. Eclipse Europa 부터 이런형식으로 바뀌였습니다.
※ Ctrl + Shift + X / Y - To Upper/Lower Case

대소문자가 맞지 않는 코드가 있습니다. 꼭 String은 아니여도 됩니다. 코드 전체에 적용됩니다.

대문자로 바꾸고 싶은 부분을 블록 처리합니다.

Ctrl + Shift + X 를 누르면 대문자로 변경이 됩니다.

소문자로 바꾸고 싶은 영역을 블록 지정합니다.

Ctrl + Shift + Y 를 누르면 블록 부분의 코드들이 소문자로 변경됩니다.
일단은 여기까지 제가 주로 쓰는 단축키들이였습니다.
더 좋은 단축키가 있으면 추천 해주세요~~