Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | |||||
3 | 4 | 5 | 6 | 7 | 8 | 9 |
10 | 11 | 12 | 13 | 14 | 15 | 16 |
17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 | 25 | 26 | 27 | 28 | 29 | 30 |
31 |
Tags
- 클래스
- 스프링부트
- Swing
- event
- SSL
- 프로그래머스스쿨
- 객체
- class
- 메소드
- AssertJ
- StringBuilder
- array
- synchronized
- docker
- 배열
- 자바
- JS
- Python
- c#
- JavaScript
- 저장소
- Java
- 자바스크립트
- GIT
- SpringBoot
- thread
- Docker Desktop
- Dict
- 파이썬
- join()
Archives
- Today
- Total
목록인터페이스 (1)
정리노트
[자바/java] 인터페이스
interface RemoteControl { void turnOn(); void turnOff(); } // 인터페이스 사용시 메소드를 구현하지 않으면 에러가 발생한다. public class Radio implements RemoteControl { boolean on; public void turnOn() { on = true; System.out.println("라디오가 켜졌습니다."); } public void turnOff() { on = false; System.out.println("라디오가 꺼졌습니다."); } public void status() { System.out.println("현재의 상태: " +on); } public static void main(String[] args) ..
프로그래밍/Java
2022. 12. 28. 22:53