https://msdn.microsoft.com/en-us/library/system.threading.mutex(v=vs.110).aspx
- a primitive .NET type
- one thread owns it at a time
-
WaitOne(int)- blocks the calling thread
- returns true when no threads own it
- then gives ownership to the calling thread
- otherwise, returns false when the timeout expires
-
similar to the
Semaphore.NET type-
but only the owner of a
Mutexcan release aMutex, -
and
Mutexscope can pass application domain boundaries
-
but only the owner of a
-
scope
-
a local, unnamed
Mutexhas process scope -
a system, named
Mutexhas operating system scope
-
a local, unnamed
- use case examples: