i have a problem about java multithread let's see scenario: 1 Thread server (locally, shared memory it's just a simulation)
class server extends Thead
syncronized public operation1
synchronized public operation2
.......public operationX
with run method to decide which op1,op2..opX "enable"
3 Thread client
-class client extend Thread
client call direct op1,op2..opX to the same server thread (offcourse) created and passed by main..So op1,opX are exectud IN the client server, it's not the server thread to execute it..
so after all Server in the run method decide to enable or disable op1,op2..opX. Client in the run method just call serverreference.op1() ..... serverref.opX()
Ok.. Now suppose all 3 client call op1 which is not enabled by server, they must wait() and then someone else must notify()... But i need to handle these notify FIFO. And notify don't run in fifo wait it's just picked up ONE of suspended thread..
Which utility can i use for handle this situation?
Thx in advice.