This should be a simple take for any Java Master. Me being a newbie just wanted to confirm one thing.
I have a class implementing Runnable and like many such classes its run() method has an infinite loop. I want to do some task and then sleep for a min and come back again.
What happens if an Interrupted Exception is encountered while a thread is sleeping?
What I think would happen is the thread being suspended and now the infinite loop is of no help to keep the thread runnning. I'd like to confirm if my understanding is correct or not.
If this is what happens, What would be a possible solution to start up the thread up again.?