Can we call the Thread.sleep in Synchyronozed block?
Answer Posted / muthusenthil
yes, you can call wait method inside synchronized block but
synchronized block usually allows one by one to penetrate
in.if you call wait method inside it will create a stagnant
circumstance. synchronized block wont allow other threads
inside till this thread in waiting state get notified
| Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
What is adapter in java?
What are measurable parameters?
What comes to mind when someone mentions a shallow copy in java?
Is there any case when finally will not be executed?
How to check if a list is sorted in java?
Is integer immutable in java?
'A class is a template for an object' explain this statement.
What are the different ways of implementing thread? Which one is more advantageous?
What do you understand by casting in java language?
Can we have multiple classes in single file ?
What is the function of character?
Can we call virtual funciton in a constructor ?
Where are register variables stored?
Name and explain the types of ways which are used to pass arguments in any function in java.
What is a modifier?