- 585 名前:デフォルトの名無しさん mailto:sage [2007/07/13(金) 05:28:47 ]
- >>583
public class Clock implements java.awt.event.ActionListener { public void actionPerformed(java.awt.event.ActionEvent e) { System.out.println(new java.util.Date()); } public static void main(String[] args) throws InterruptedException { Clock c = new Clock(); new javax.swing.Timer(1000, c).start(); synchronized (c) { c.wait(); } } }
|

|