Hi All
I have a problem related to a
java code. Please help me to solve the problem..
I have a java code which is say a
thread which runs continously...
say
class MyRun extends Thread{
///////definition of MyRun class
//main method here
}
when i run this program, say
java MyRun Now my file is running properly.
Now i need to run another file say
class StopMyRun {
///class definition
//main method here
}
and i will run this file as
java StopMyRun Now these two files are independent files having their own main method.
My problem is that, I have to stop MyRun Thread from my StopMyRun file.
For ex. I run MyRun program on one shell and when i run StopMyRun on other shell, The first one should stop their function.
How to do that, Any idea
