ALso posted at http://www.javaprogrammingforums.com/threads/20314-synchronized-block.html#post85783
Type: Posts; User: Norm
ALso posted at http://www.javaprogrammingforums.com/threads/20314-synchronized-block.html#post85783
Have you read the tutorial?
Synchronization (The Java™ Tutorials > Essential Classes > Concurrency)
String aStr = "";
...
synchronized(aStr) {
// have lock on aStr