what is object lock?
Answer / divikiran
The lock keyword marks a statement block as a critical section by obtaining the mutual-exclusion lock for a given object, executing a statement, and then releasing the lock. This statement takes the following form:
Object thisLock = new Object();
lock (thisLock)
{
// Critical code section
}
| Is This Answer Correct ? | 1 Yes | 0 No |
Give an example program for Getter /read-only methods in JAVA
What is a delegate, How many types of delegates?
How many namespaces are in .net version 1.1?
What is the difference between an abstract class and an interface?
What is serialization in .NET? What are the ways to control serialization?
What is the difference between a Hash Table and a Dictionary?
What is .net and .net framework?
How can you automatically generate interface for the remotable object in .NET with Microsoft tools?
How can you turn-on and turn-off cas?
What is managed code and managed data in .net?
When displaying fonts, what is the difference between pixels, points and ems?
What is RunTime Polymorphism?
5 Answers Deloitte, eClerx, Horizon, Intel, Pragna Technologies,