I\'ve just been messing around with threads in Java to get my head around them (it seems like the best way to do so) and now understand what\'s going on with synchronize, wait()
No, not with a standaad Java lock. Although I guess you could construct such a lock.
wait should be called within a while loop (wait may spuriously wakeup, and in most situations you would want the loop anyway). So some kind of flag would make more sense.