분류 전체보기336 0526실습 2023. 5. 26. 05.24 FXML 요소 정보를 필드 에 초기화 후 init()호출됨. bundle : 다국어 지원에 쓰임 2023. 5. 25. 0523. 스레드풀을 이용한 서버프로그램 / JavaFx 설치 Hashtable 특징 키 객체 만드는 법은 HashMap과 동일 Hashtable은 스레드 동기화(synchronization)가 된 상태 복수의 스레드가 동시에 Hashtable에 접근해서 객체를 추가, 삭제하더라도 스레드에 안전(thread safe) powerShell에서 jar 파일 실행 시 'java -jar 파일이름.jar' 입력 2023. 5. 23. 05.22 스레드 풀,inet_address , tcp/ip이용한 서버 프로그램생성 package t09_thread_pool; import java.util.concurrent.ExecutionException; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.Future; import java.util.concurrent.ThreadPoolExecutor; import java.util.concurrent.TimeUnit; public class ExecutorsExample { public static void main(String[] args) { // 스레드 풀 기능을 정의 해놓은 interface final ExecutorSe.. 2023. 5. 23. 05.19 스레드,네트워크 동기화 메소드 및 동기화 블록 – synchronized 단 하나의 스레드만 실행할 수 있는 메소드 또는 블록 다른 스레드는 메소드나 블록이 실행이 끝날 때까지 대기해야 package t04_sync; public class ThreadSyncEX { public static void main(String[] args) { Runnable work = new WithDrawThread(); Thread thread1 = new Thread(work); Thread thread2 = new Thread(work); thread1.setName("스레드 1"); thread2.setName("스레드 2"); thread1.start(); thread2.start(); } } class Account{ // .. 2023. 5. 23. 05.18 람다표현식, 스레드 package l1_example; public class MessageButton { private String title; public MessageButton(String title) { this.title = title; } public void onTouch() { System.out.println("메세지를 전달합니다."); } @Override public String toString() { return "MessageButton [title=" + title + "]"; } } package l1_example; public class MessageListener implements OnClickListener { @Override public void onClick() { System.o.. 2023. 5. 18. 이전 1 ··· 42 43 44 45 46 47 48 ··· 56 다음