Inscrivez-vous ou connectez-vous pour rejoindre votre communauté professionnelle.
lets asume you have a variable of thread in java say it "ThreaD"
ThreaD.start();
right after that write
While(Thread/isAlive());
this will end up in a lopp that rung untill thread is running
refference http://docs.oracle.com/javase/7/docs/api/java/lang/Thread.html#isAlive()