I am writing a Java Applet which requires to have one second of delay before repaint(). Now, I, of course, thought about using Thread.sleep(). However, the problem now is that I don't know where should I put the throws InterruptedException statement. In an application, it is after the public static void main(String args).
I tried to put it in the actionPerformed method and use the try-catch statement but it went into an infinite loop. I wonder where should I add the throws InterruptedException in an applet?