2013-09-25から1日間の記事一覧

Thread の割り込みフラグは InterruptedException の throw によりクリアされる

例えば自身で作っているコード内で、呼び出し元の処理をブロックしたいようなケースはよくある。 String send(final String msg) throws IOException { Thread thread = new Thread() { private response; public void run() { os.print(msg); // 送信に不定…