I thought I understood this - turns out perhaps i don't!
if I use the synchronized keyword on a
thread's run method..i.e.
And then create multiple instances of the above thread and start them from another class (person is my thread class - it implements runnable)
eg..
The use of the synchronized keyword in the run() has no effect..I thought that whichever thread acquired the lock first would need to complete {some work} before the next thread could begin executing {some work}.
this doesn't seem to be the case..both jeremy and james start up - and both are able to exist in the {some work} critical section at the same time.
i saw another post on this topic in these forum, but I couldn't follow the answer..
Help appreciated,
Jules
[ June 11, 2008: Message edited by: Jules Bach ]