What is an object?s lock? Give name of object?s that have
locks?

Answer Posted / guest

An object?s lock is a mechanism that is used by multiple
threads to obtain synchronized access to the object. A
thread may execute a synchronized method of an object only
after it has acquired the object?s lock. All objects and
classes have locks. A class?s lock is acquired on the
class?s Class object.

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is role of void keyword in declaring functions?

580


Is array an object in java?

556


What are the main differences between the java platform and other platforms?

533


how to create multithreaded program? Explain different ways of using thread? When a thread is created and started, what is its initial state? Or extending thread class or implementing runnable interface. Which is better? : Java thread

602


What is OOP Language?

632






In which order the iterator iterates over collection?

587


How to obtain a performance profile of java program

547


what is the final keyword denotes in java?

587


Why java is a platform independent? Explain

536


What is static method with example?

623


Write a java program that prints all the values given at command-line.

559


What is a parameter in matrices?

546


Is java 11 paid version?

514


What is the difference between a scrollbar and a scrollpane?

567


Which command from the jdk compiles a java program?

491