Difference

Friends, what is the difference between the following synchronized blocks:(consider there exist a class A) synchronized(new A()) & synchronized(A.class) Any Idea? Thanks for your reply.Hari V
[238 byte] By [haricsea] at [2007-10-2 20:35:51]
# 1
The first does nothing :P In general terms th first is synchronizing on an instance of A while the second is synchronizing on the single shared A.class matfud
matfuda at 2007-7-13 23:19:04 > top of Java-index,Core,Core APIs...