Q. In what situation, an IllegalThreadStateException will be thrown?
A:
1) If the thread was already started, you call start() again.
2) If this thread is active, you call setDaemon().
3) A deprecated method countStackFrames() also throws
IllegalThreadStateException.
A:
1) If the thread was already started, you call start() again.
2) If this thread is active, you call setDaemon().
3) A deprecated method countStackFrames() also throws
IllegalThreadStateException.