Hi all,
I have a small doubt any one can clearit ...
if a class have multiple Synch. methods or blocks ,then only one lock dfined for that class or multiple locks are defined for each synch. block.
//dummy code
class a{
synchronized m1(){
m2();
}
synchronized m2(){
}
}
Now for the same class if
thread t1 calles m1() ,and t2 calles m2()..Then is it possible to call m2() by t2 untill m1() exits for t1.
practically its working ..... my question is how it is working ,by Scheduling ?