I have two classes (A & B) which implements Runnable.
Both threads are executed in this way:
A a = new A();
new Thread(a).start();
B b = new B();
new Thread(b).start();
I need to stop/wait/resume thread A inside thread B.
How does it's possible?
Actually, you can't just stop tread.As markspace commented, it is possible, but you should do it carefully and in some special cases
Java Thread Primitive Deprecation