API
System.Threading.Lock
Modern dedicated lock type for mutual exclusion.
Formal Syntax & Structure
csharp syntaxcsharp
var gate = new Lock();Working Example
Example Snippetcsharp
// Documentary fragment; see linked lesson for context.var gate = new Lock();