Initializes a new instance of the SpinLock
structure with the option to track thread IDs to improve debugging.
Namespace:
System.Threading
Assembly:
System.Threading (in System.Threading.dll)
Syntax
Visual Basic (Declaration) |
---|
Public Sub New ( _ enableThreadOwnerTracking As Boolean _ ) |
C# |
---|
public SpinLock( bool enableThreadOwnerTracking ) |
Parameters
- enableThreadOwnerTracking
- Type: System..::.Boolean
Whether to capture and use thread IDs for debugging purposes.
Remarks
The default constructor for SpinLock tracks thread ownership.